Beispiel #1
0
        public void SetInputModifier(int modifierIntValue)
        {
            _inputHolder.PlayerInputModifier = (PlayerInputModifier)modifierIntValue;

            if (_inputHolder.PlayerInputModifier == PlayerInputModifier.Push ||
                _inputHolder.PlayerInputModifier == PlayerInputModifier.Move)
            {
                var color = _modifiersToColors[_inputHolder.PlayerInputModifier];
                _arrowsVisibilityManager.Show(color);
            }
            else if (_inputHolder.PlayerInputModifier == PlayerInputModifier.DaringBlow)
            {
                _weaponColorizer.Colorize(_gameContext.PlayerActor.WeaponAnimator, Color.red);
            }
        }
Beispiel #2
0
 public void Process()
 {
     _actorAligner.AlignActorToDirection(_actorBehaviour.ActorData.Entity, _attackedActorLogicalPosition.x -
                                         _actorBehaviour.ActorData.LogicalPosition.x);
     if (_isDaringBlow)
     {
         _weaponColorizer.Colorize(_actorBehaviour.WeaponAnimator, Color.red);
     }
     _actorBehaviour.WeaponAnimator.SwingTo(_attackedActorLogicalPosition, _isDaringBlow);
     if (_parried)
     {
         _attackedActorBehaviour.WeaponAnimator.DefendSwing(_actorBehaviour.WeaponAnimator.transform, _attackedActorLogicalPosition);
     }
 }