public void OnAttackStarted()
 {
     if (MovementModel == null || MovementView == null)
     {
         return;
     }
     MovementModel.OnAttackStarted();
     MovementView.OnAttackStarted();
     ShowWeapon();
 }
Пример #2
0
    public void OnAttackStarted()
    {
        if (MovementModel != null)
        {
            MovementModel.OnAttackStarted();
        }

        if (MovementView != null)
        {
            MovementView.OnAttackStarted();
        }
    }
 public void OnAttackStarted(AnimationEvent animationEvent)
 {
     if (MovementModel != null)
     {
         MovementModel.OnAttackStarted(); //This says to do the OnAttackStarted if the movementmodel returns null
         //This will make the MovementModel know when you are attacking or not, so it can decide whether you can attack or not
     }
     if (MovementView != null)
     {
         MovementView.OnAttackStarted(); //This will turn on and off the visuals of the weapon
     }
 }
    public void AttackStarted(AnimationEvent animationEvent)
    {
        if (movementModel != null)
        {
            movementModel.AttackStarted();
        }

        if (movementView != null)
        {
            movementView.OnAttackStarted();
        }
        SetSortingOrderOfWeapon(animationEvent.intParameter);
    }
    public void OnAttackStarted(AnimationEvent animationEvent)
    {
        if (MovementModel != null)
        {
            MovementModel.OnAttackStarted();
        }

        if (MovementView != null)
        {
            MovementView.OnAttackStarted();
        }

        ShowWeapon();
        SetSortingOrderOfWeapon(animationEvent.intParameter);
        SetShieldDirection(animationEvent.stringParameter);
    }
Пример #6
0
    //When attack starts, do the animation to show weapon etc.
    public void OnAttackStarted(AnimationEvent animationEvent)
    {
        //Make sure the movement system is set up and do attack
        if (MovementModel != null)
        {
            MovementModel.OnAttackStarted();
        }
        if (MovementView != null)
        {
            MovementView.OnAttackStarted();
        }

        ShowWeapon(); //Render our weapon
        SetSortingOrderOfWeapon(animationEvent.intParameter);
        SetShieldDirection(animationEvent.stringParameter);
    }