SANDBOX — this is a test environment. No servers are actually deployed and no real payments are charged.
Back to NxLabs

NxLabs / Vintage Story

Jaunt: Entity Movement System

SBy Shintharo12

Library providing an extended entity riding system with additional control patterns and stamina

Description

<span style="color: #e74c3c;">This mod does nothing useful on its own. Install if another mod requires it.</span>

Jaunt is a library mod to extend entities with rideable behaviors. It provides an extended gait (movement pacing) system allowing for multiple forward gaits plus idle and backwards movement; as well as a stamina behavior for entities.

&nbsp;

Release List
2.1.0: 1.21 Compatability + Saddle Breaks
2.0.0: Flying Mount Support + Jaunt Flute

&nbsp;

<span style="color: #3598db;">Checkout Draconis for an example of what can be done!</span>

our Mods using Jaunt:

other Mods using Jaunt:

&nbsp;

<span style="color: #e74c3c;">If you are experiencing issues with your mount stopping and running in place and/or your camera snapping forward while riding this is due to the full attribute tree resync in the base game. It is more likely to happen the more mods you have installed but as a workaround you can try <span style="color: #3598db;">MountCameraFix</span> mod which changes the max number of dirty paths before a full resync.</span>

&nbsp;

While Jaunt itself is a code mod it is designed to be fully implemented and configured through entity json files and does not require content mods to be converted to code mods to utilize it. Just add Jaunt to your mod's dependencies and follow the guide below on "Entity Json Implementation"

Gait System

Gaits and rideable are independent behaviors but using jaunt:rideable requires jaunt:gait also be configured or it will fail to initialize.


When an entity uses both behaviors it allows the rider to cycle through available gaits according to the order specified in the rideableGaitOrder array in jaunt:rideable's behaviorConfig.

For more information on configuring available gaits see the Entity Json Implementation section below.

&nbsp;

Below is an example setup utilized by Equus: Wild Horses that implements four forward gaits.

  • Walkback (Backward)
  • Idle (Stationary)
  • Walk (Forward Speed 1 - Slowest)
  • Trot (Forward Speed 2)
  • Canter (Forward Speed 3)
  • Gallop (Forward Speed 4 - Fastest)

&nbsp;

They are progressive in that you must move through each gait to get to the next, cycling gait up is done via the Sprint Key (see controls section for more details). Cycling down can be done with the S key or by releasing the forward key when using the snaffle bit.

&nbsp;

The gaits are indicated on the HUD with icons which can be supplied by the mod (see Entity Json Implementation for more details). Jaunt also provides the default icons used in Equus: Wild Horses which can be referenced by your mod.

&nbsp;

Stamina System

When an entity uses the jaunt:stamina behavior it will be given an additional stat - "stamina" (go figure). This stat behaves much like you'd probably expect with certain actions causing stamina drain (fatigue) and when these actions are not being performed it will naturally regenerate.

  • Drain/Regen rates are fully configurable in entity json behaviorConfigs, as well as values for maximum stamina, penalties for wounded or mounted animals, as well an exhaustion threshold and the option to cancel fleeingEntity behaviors when below the exhaustion threshold (allowing players to run down animals they might not otherwise be able to).

&nbsp;

  • Stamina draining activites include swimming and fleeing, and can be added to any gait in the gait config. Stamina is regenerated when not in any of those situations, regen penalties (if configured) are applied if the horse is mounted or injured (below 70% health).

&nbsp;

  • When a entity's stamina is below 50% there is a gait shift down chance that is quadratically proportional (chance increases more dramatically as the stamina decreases) to the stamina percentage below 50%. (i.e. At 50% stamina, 0% chance; at 0% stamina, 100% chance; moving along a quadratic curve)

&nbsp;

  • If the gait shift down chance is triggered the entity will reduce to a their moderateStamina state if remaining stamina is greater than 10%, or to their lowStaminaState if below 10%. These states are configured in the rideable behaviorConfigs section.

&nbsp;

    Read the full description on Vintage Story ModDB

    Ratings & reviews

    No ratings yet

    Sign in to leave a rating or comment.