diff --git a/README.md b/README.md index f524668..7e2d05c 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,28 @@ # Movement (Work In Progress) -## Dependencies -1. [State Module](https://git.syntriax.com/Syntriax/State) -2. [Trigger Module](https://git.syntriax.com/Syntriax/Trigger) -3. [Factory Module](https://git.syntriax.com/Syntriax/Factory) +## Installation +### UPM +1. Add the UPM registry. Click on the `Edit` menu, then select `Project settings...`, select `Package Manager`, and add a scoped registry: + - Name: `Syntriax` + - Url: `https://upm.syntriax.com` + - Scopes: + - `com.syntriax` -Make sure to separately clone these modules along with this one too. +The UPM registry also has proxies to OpenUPM, so you can add scopes from there too. + +### Manual +1. Navigate into `Package Manager` and press on the `+` button, choose `Add package from git URL...` and add: + - `https://git.syntriax.com/Syntriax/State` + - `https://git.syntriax.com/Syntriax/Trigger` + - `https://git.syntriax.com/Syntriax/Factory` + - `https://git.syntriax.com/Syntriax/Movement` + +--- + +### Dependencies +1. [State Module (https://git.syntriax.com/Syntriax/State)](https://git.syntriax.com/Syntriax/State) +2. [Trigger Module (https://git.syntriax.com/Syntriax/Trigger)](https://git.syntriax.com/Syntriax/Trigger) +3. [Factory Module (https://git.syntriax.com/Syntriax/Factory)](https://git.syntriax.com/Syntriax/Factory) --- @@ -36,7 +53,7 @@ Make sure to separately clone these modules along with this one too. 3. Add `MovementController` component to your Player `GameObject` 4. Add `AirMovement1D` component to your Player `GameObject` 5. Add `GroundMovement1D` component to your Player `GameObject` (make sure it's bellow `AirMovement1D`) -6. Add a new empty child `GameObject` and add `Box2DColliderTrigger` component to it and place and resize it under the player for ground detection, optionally you can set the `CollisionMask` field on it to make sure it only detects specific layers +6. Add a new empty child `GameObject` and add `Box2DGroundTrigger` & `GroundTrigger` component to it and place and resize it under the player for ground detection, optionally you can set the `CollisionMask` field on it to make sure it only detects specific layers 7. Connect your inputs to the `MovementController` ([Example with Input System](#input-system-example)) 8. (Optional) Add a jumping script to see the effects better