All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
NOTE: Subcrates have their own changelogs: bevy-tnua-physics-integration-layer, bevy-tnua-rapier, bevy-tnua-avian.
- Upgrade to Bevy 0.15.
TnuaControllerBundle
. It is no longer needed sinceTnuaController
uses Bevy 0.15's required components feature.
- A
TnuaBuiltinKnockback
action for applying knockback that will not be nullified even with very high walk acceleration settings (see #30)
- Instead of fixating it to positive Y, Tnua now calculates the up direction to be the reverse of the gravity direction (see see #40)
- [BREAKING] API changes:
- (only relevant for custom basis/actions) The
up_direction
ofTnuaBasisContext
andTnuaActionContext
is now a field instead of a method. TnuaController
method for feeding basis and actions no longer return&mut Self
(this was always redundant, since they get called from queries anyway rather than on freshly created objects, so they don't benefit from a fluent API)desired_forward
fields ofTnuaBuiltinWalk
andTnuaBuiltinDash
were changed fromVector3
toOption<Dir3>
.- The
direction
fields of some ofTnuaBuiltinDashState
's variants were changed fromVector3
toDir3
.
- (only relevant for custom basis/actions) The
- Upgrade to Bevy 0.14.
max_slope
field forTnuaBuiltinWalk
to make the character treat too steep slopes as walls.
- [BREAKING]
TnuaBuiltinWalk
no longer has anup
field. The up direction is fixed toDirection3d::Y
(up until now, it problably wouln't work well with other up directions anyway). This has some other implications, which are mostly internal:DynamicBasis::up_direction()
has been removed. Actions should take their up direction from the newTnuaActionContext::up_direction()
.TnuaBasisContext
also got anup_direction()
method, for the same purpose. For now, they always point up.TnuaBuiltinWalk::standing_offset
is now a vector instead of a number (it was easier to make it that way)
- Make the
bevy_tnua::util
module public. It contains two helper utilities:SegmentedJumpInitialVelocityCalculator
for calculating the initial velocity required for a jump with varying gravity.rotation_arc_around_axis
for calculating a character's rotation.
- Re-export
bevy_tnua_physics_integration_layer::math
asbevy_tnua::math
.
f64
flag to run in double precision mod (used by the XPBD backend)- Allow plugins to register their systems in different schedules. See the migration guide.
- Upgrade to Bevy 0.13.
- Use boost for stopping in
TnuaBuiltinWalk
(fixes #39)
- Use a proper
OR
syntax for the dual license.
is_airborne
method forTnuaController
.get_count_mut
andreset_count
methods forTnuaSimpleAirActionsCounter
.
- Use external forces instead of boosting the velocity for movement (fixes #34)
- Expose
DynamicBasis
andDynamicAction
. This is mostly so that they'd appear in the docs.
- [BREAKING] Split the physics integration to separate crates. See the migration guide.
- XPBD support (with separate crates)
- Upgrade Bevy to 0.12
- [BREAKING] Fix typo
dynaimc_basis
->dynamic_basis
.
- Ability to start a jump while the air.
- A simple dash action -
TnuaBuiltinDash
. Also air-able. - Utilities for tracking the air actions, so that games can limit how many (and
which) air actions a character can perform. See
TnuaAirActionsTracker
andTnuaSimpleAirActionsCounter
.
- [BREAKING] Big refactor which completely breaks the API. See the
migration guide. The main
changes are:
- Instead of having a
TnuaPlatformerControls
, Tnua now hasTnuaController
which can be fed a basis and (optionally) an action. The basis controls the basic floating and walking abound, while the action can be a jump - but also all other kinds of movement actions. - Instead of
TnuaPlatformerConfig
, the configuration is fed to the basis and the action on every frame.
- Instead of having a
- Turn direction no longer defaults to the walk direction. If it is not passed
to the
TnuaBuiltinWalk
basis, the character will not turn. - Crouching is done via an action -
TnuaBuiltinCrouch
. - Replace
TnuaKeepCrouchingBelowObstacles
withTnuaCrouchEnforcer
. This is not just a name change - their semantics are also different.
- There is no longer
forward
. It was only needed before because Tnua needed to turn the character's "forward" in the movement direction. Instead, the forward direction is always assumed to be negative Z - even if this is not the real forward direction of the sprite/model. - Manual turning. Now that Tnua does not make the character turn in the walk direction by default, there is no longer need to redirect that output in games with 2D physics.
TnuaKeepCrouchingBelowObstacles
now also prevent jumping while crouched below an obstacle (fixes #27)
- Upgrade Bevy to 0.11.
- Physics backend plugins are now in charge of preventing
TnuaSystemSet
from running while the physics backend is paused. Users no longer need to do it.
TnuaToggle
for temporarily disabling Tnua for specific entities.
- Fix jump shortening not working with takeoff gravity
- Jump/fall through platforms.
- [BREAKING] Tnua now requires additional Rapier components -
ExternalForce
andReadMassProperties
. For convenience,TnuaRapier2dIOBundle
/TnuaRapier3dIOBundle
were added. It contains these new components, plusVelocity
(which was already required) TnuaMotor
now hasboost
andacceleration
for both linear and angular components of the motor.- Rename
jump_start_extra_gravity
toupslope_jump_extra_gravity
.
- Settings to add extra gravity during jump takeoff.
float_height_offset
control for crouching. Also add:height_change_impulse_for_duration
andheight_change_impulse_limit
settings for controling a boost that would be added for crouching and getting back up.standing_offset
field toTnuaPlatformerAnimatingOutput
to assist in applying crouching/crawling animation.TnuaKeepCrouchingBelowObstacles
component for preventing the character from standing up under a too-low ceiling.
- Update proximity sensors in parallel.
- [BREAKING] Removed
TnuaPlatformerBundle::new_with_config
. Users should use this instead:cmd.insert(TnuaPlatformerBundle { config: TnuaPlatformerConfig { // ... }, ..Default::default() });
- The character no longer automatically jumps repeatedly when the jump button
is held. This behavior, though, can be replicated by setting
held_jump_cooldown
toSome(0.0)
.
- Apply additional impulse when moving platform changes velocity to prevent #13.
- Fix ray(/shape)cast hitting a wall when the character squeezes into it.
jump_peak_prevention_at_upward_velocity
andjump_peak_prevention_extra_gravity
settings for shortening the time a character floats at the peak of the jump.jump_input_buffer_time
setting for jump input buffering - pressing the jump button before the character can actually jump.held_jump_cooldown
setting for automatically jumping when the jump button is held.
- Bevy
Reflect
ion forTnuaPlatformerConfig
(andTnuaFreeFallBehavior
)
- Make ray/shape-casts ignore
Sensor
s.
- [BREAKING]
spring_dampening
now gets divided by the frame duration, to avoid weird effects from unstable framerate. This means that the proper numbers for it should be greatly reduced - for example in the 3D example it was reduced from 60.0 to 1.2. - Better document how to shapecast and why it is needed. Also make it the default for the examples.
- Running
- Jumping
- Variable height jumping
- Coyote time
- Running up/down slopes/stairs
- Tilt correction
- Moving platforms
- Rotating platforms
- Animation helpers (not the animation itself, but Tnua has facilities that help deciding which animation to play)