This PR was initially just for adding support for ladders, but doing this required implementing an extensible status effect system that other pieces of the engine (collision detection, etc.) can check easily.
StatusComponent is a component that is designed solely to be a child of PhysicalEntity. Statuses can be checked without walking the entire component tree with the entity.hasStatus<T>() and entity.getStatus<T>() functions.
IgnoresGravity and IgnoresGroundCollisions mixin can be added to any status, they are implemented as mixins so that multiple status can have this effect simultaneously.
Ladders require custom rendering by the implementer similar to moving platforms, an entity can start "climbing" the ladder by adding an OnLadderStatus component as a child, and properly handling enter/exit/movement state.
SimpleCombinedInput renamed to TwoButtonInput (left, right)
This PR was initially just for adding support for ladders, but doing this required implementing an extensible status effect system that other pieces of the engine (collision detection, etc.) can check easily.
StatusComponent
is a component that is designed solely to be a child ofPhysicalEntity
. Statuses can be checked without walking the entire component tree with theentity.hasStatus<T>()
andentity.getStatus<T>()
functions.IgnoresGravity
andIgnoresGroundCollisions
mixin can be added to any status, they are implemented as mixins so that multiple status can have this effect simultaneously.OnLadderStatus
component as a child, and properly handling enter/exit/movement state.SimpleCombinedInput
renamed toTwoButtonInput
(left, right)ThreeButtonInput
(left, right, center)FourButtonInput
(left, right, up, down)