Lunge State:

The lunge movement state can be triggered three ways:

  1. By the MultiStatePlayerInput script via key input:

    1. Step 1. Select the Camera Rig Gameobject and scroll down to the Lunge Keybind section.

    2. Step 2. To add another Lunge Action, increase the size of the list.

    3. Step 3. Fill out the information required for the new Lunge Action.

    4. Please be aware of the following:

      1. If you are unsure of what a parameter controls, please refer to the documentation included in the package.

      2. You do not need to set the simple direction value if the Lunge Advanced Direction parameter is set to Free Vector or Flat Vector.

      3. You do not need to set an input key if you wish to trigger the action only through your own script.

  2. By the MultiStatePlayerInput script via the following method:

    1. Step 1. Create a new lunge action using the steps listed above. Note: an input key is not required.

    2. Step 2. Call one of the following methods from your script:

      1. MultiStatePlayerInput.PreformLungeAction(int index);

      2. MultiStatePlayerInput.PreformLungeAction(string name);

    3. Please be aware of the following:

      1. Lunge Actions may be enabled or disabled via the following methods:

        1. MultiStatePlayerInput.ToggleLungeAction(int index, bool isEnabled);

        2. MultiStatePlayerInput.ToggleLungeAction(string name, bool isEnabled);

  3. By the MultiStateCharacterController Script via the following method:

    1. Call the method: MultiStateCharacterController.RequestLunge (LungeAction lungeAction)

    2. Example:

  1. Please be aware of the following:

    1. The following functionality does not apply, by default, to lunge actions called by the MultiStateCharacterController Script:

      1. Input triggering,

      2. Enabling and Disabling,

      3. Input based directional control,

      4. Cooldowns

    2. The simple direction parameter of the Lunge Action is only used by the MultiStatePlayerInput Script, and otherwise, does nothing. Use the “direction” parameter of the Lunge Action to actually control it’s direction.

MultistateCharacterController characterController = gameObject.GetComponent<MultistateCharacterController>();

LungeAction myLungeAction = new LungeAction();

myLungeAction.direction = Vector3.forward;

myLungeAction.intensity = 10;

myLungeAction.duration = 0.5f;

characterController.RequestLunge(myLungeAction);

Video Tutorial: Setting Up Lunge Actions

Sign-up for email notifications for a chance to win the Multi-State Character Controller Completely FREE!   

Individuals under the age of 13 may not enter or submit information to this giveaway, in accordance with United States Law.

Click here for Contest Rules and Conditions.