void FixedUpdate() { HashSet <KeyCommand> activeCommands = _inputCommandController.GetActiveCommands(); if (activeCommands.Count > 0) { _movementSystem.UpdateMoveCommand(activeCommands); } for (int i = 0; i < _tailBehaviours.Count; i++) { if (i > 0) { _tailBehaviours[i].PushCommand(_tailBehaviours[i - 1].GetCurrentCommand()); } else { _tailBehaviours[i].PushCommand(_movementSystem.CurrentCommand); } } }
public void PushCommand(KeyCommand keyCommand) { _movementSystem.UpdateMoveCommand(keyCommand); }