mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-10 05:25:54 +00:00
Damage actor handler
This commit is contained in:
parent
335f4d5430
commit
4fd31d7988
7 changed files with 100 additions and 4 deletions
|
|
@ -16,6 +16,8 @@ public partial class ActorFreeMovement : MovementHandler
|
|||
get => _parent.MovementDirection;
|
||||
set => _parent.MovementDirection = value;
|
||||
}
|
||||
|
||||
public bool IsDestroyed => _parent.IsDestroyed;
|
||||
|
||||
public override void Init(Actor parent)
|
||||
{
|
||||
|
|
@ -32,6 +34,8 @@ public partial class ActorFreeMovement : MovementHandler
|
|||
|
||||
public override void PhysicsUpdate(double delta)
|
||||
{
|
||||
if (IsDestroyed) return;
|
||||
|
||||
MovementDirection = AggregateInputProviders().Normalized();
|
||||
|
||||
var aimingDirection = GetAimingDirection().Normalized();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue