- Updated
bevy
to 0.14 - Updated
leafwing-input-manager
to 0.16 (see theirRELEASES.md
for a migration guide)
- Updated
bevy
to 0.14 - Updated
leafwing-input-manager
to 0.14 - Renamed
Trigger
toEntityTrigger
to avoid conflict withbevy::prelude::Trigger
seldom_fn_plugin
integration
Out
definitions to trigger combinator functions' return types
- Updated
bevy
to 0.13 - Updated
leafwing-input-manager
to 0.13
on_event
trigger could detect events that occured before the latest transition
IntoSystem
trait, which allows systems which returnbool
,Option
, orResult
, and acceptEntity
or nothing as input, to be used as triggersTriggerIn
trait, which allows systems which accept nothing as input to be used as triggersTriggerOut
trait, which allows triggers to outputbool
orOption
withoutBoolTrigger
andOptionTrigger
SystemTrigger
type, which is also used for system triggers
trans
andtrans_builder
each have a new type parameter, which should simply be elided with_
- Replaced all built-in trigger types with system equivalents
- Renamed
MachineState
toEntityState
Trigger
has anOut
type andinit
andcheck
functions, instead ofParam
,Ok
, andErr
types and atrigger
function
BoolTrigger
andOptionTrigger
Clone
andCopy
impls for triggers and other typesPartialEq
andEq
impl forNever
- Updated
bevy
to 0.12 - Updated
leafwing-input-manager
to 0.11
- The
leafwing_input
feature was a default feature
- Updated
bevy
to 0.11 - Updated
leafwing-input-manager
to 0.10
PressedTrigger
firing only once per pressAxisPairTrigger
andClampedAxisPairTrigger
failing to fire without rotation bounds
trigger
module is public
- Transitions sometimes failing when there are multiple entities with state machines
EventTrigger
re-export, making it accessible
Component
bound toMachineState
StateMachine::on_enter
andStateMachine::on_exit
that acceptFn(&mut EntityCommands)
StateMachine::command_on_enter
andStateMachine::command_on_exit
that accept aCommand
AndTrigger
andOrTrigger
that combine triggers with boolean logicTrigger::not
,Trigger::and
, andTrigger::or
combinators that constructNotTrigger
,AndTrigger
, andOrTrigger
respectivelyEventTrigger<E>
that triggers upon reading the eventStateMachine::set_trans_logging
for logging transitionsStateMachine::with_state
to register states that are not used in any transitions
StateMachine::new
has been replaced withStateMachine::default
, and you must insert the initial state manuallyStateMachine::trans_builder
's callback accepts a reference to the current stateStateMachine
no longer tracks the current state, so you may add and remove states manually- Transitions have priority in the order they are added to the
StateMachine
Trigger::Param
is aReadOnlySystemParam
instead ofSystemParam
, andTrigger::trigger
accepts it as an owned value, allowing them to useEventReader
,Local
, etc
TriggerPlugin
,trigger_plugin
,TriggerInputPlugin
andtrigger_input_plugin
;Triggers
no longer need to be registeredStateMachine::insert_on_enter
andStateMachine::remove_on_exit
Reflect
bound fromMachineState
andTrigger
- Updated
bevy
to 0.10 - Updated
leafwing-input-manager
to 0.9 AnyState
is uninhabited, so it cannot be constructed
insert_on_enter
inserting on exit instead of enter
StateMachine::trans_builder
builds a state based on data provided by the triggerAnyState
state that can be used in type parameters to represent any stateleafwing_input
feature for input-related triggers:ValueTrigger
,ClampedValueTrigger
,AxisPairTrigger
,ClampedAxisPairTrigger
,JustPressedTrigger
,PressedTrigger
,JustReleasedTrigger
,ReleasedTrigger
, andActionDataTrigger
InputTriggerPlugin<Actionlike>
for easily registering input-related triggersOptionTrigger
andBoolTrigger
offer simpler APIs thanTrigger
Never
type forTrigger::Err
when the trigger always occurs
- A panic will occur when using a trigger that hasn't been registered
Trigger
has associated typesOk
andErr
, andTrigger::trigger
returns aResult<Self::Ok, Self::Err>
, which are used in transition builders
Clone
andFromReflect
requirements forTrigger
Clone
fromStateMachine
FromReflect
re-export fromprelude
- Updated
bevy
to 0.9 Trigger::Param<'w, 's>
has lifetime parametersTrigger::trigger
accepts&Self::Param::Fetch::Item
instead of&StaticSystemParam<Self::Param>
Done
andDoneTrigger
are enums withSuccess
andFailure
variants
StaticSystemParam
re-export fromprelude
Done::success()
andDone::failure()
constructorsDoneTrigger::success()
andDoneTrigger::failure()
constructors
- Creating multiple transitions from the same
MachineState
andTrigger
type doesn't panic
StateMachine::insert_on_enter
configures theStateMachine
to insert a bundle when entering a stateStateMachine::remove_on_exit
configures theStateMachine
to remove a bundle when exiting a stateStaticSystemParam
andFromReflect
are re-exported inprelude
Done::success()
andDone::failure()
constructorsDoneTrigger::success()
andDoneTrigger::failure()
constructors
MachineState
s must implementBundle
and don't need to implementComponent
DoneTrigger
andDone
each have asuccess
field. So,DoneTrigger
will only trigger when aDone
component with a matchingsuccess
field is added.