mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-10 06:15:55 +00:00
Ability for enemies to shoot when controlled
This commit is contained in:
parent
dfd9abe91b
commit
2d6bcc5f00
10 changed files with 93 additions and 34 deletions
|
|
@ -36,9 +36,14 @@ public abstract partial class MovementHandler : ActorModule
|
|||
return _inputProviders.Aggregate(Vector2.Zero, (current, inputProvider) => current + inputProvider.GetAimInput());
|
||||
}
|
||||
|
||||
public virtual bool GetStrafing()
|
||||
public virtual bool GetActionJustPressed(string action)
|
||||
{
|
||||
return _inputProviders.Aggregate(false, (current, inputProvider) => current && inputProvider.GetStrafing());
|
||||
return _inputProviders.Aggregate(false, (current, inputProvider) => current || inputProvider.GetActionJustPressed(action));
|
||||
}
|
||||
|
||||
public virtual bool GetActionPressed(string action)
|
||||
{
|
||||
return _inputProviders.Aggregate(false, (current, inputProvider) => current || inputProvider.GetActionPressed(action));
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue