示例#1
0
 protected virtual void HideWeaponsHandle(vThirdPersonInput tpInput, vIEquipment equipment, UnityEngine.Events.UnityAction onStart, UnityEngine.Events.UnityAction onFinish, bool immediate = false)
 {
     if (holderManager.inUnequip)
     {
         return;
     }
     if (!immediate)
     {
         tpInput.animator.SetInteger("EquipItemID", equipment.equipPoint.equipPointName.Contains("Right") ? equipment.referenceItem.EquipID : -equipment.referenceItem.EquipID);
         tpInput.animator.SetTrigger("EquipItem");
     }
     StartCoroutine(holderManager.UnequipRoutine(equipment.referenceItem.unequipDelayTime, immediate, onStart, onFinish));
 }
 protected virtual void HideWeaponsHandle(vThirdPersonInput tpInput, vIEquipment equipment, UnityEngine.Events.UnityAction onStart, UnityEngine.Events.UnityAction onFinish, bool immediate = false)
 {
     if (holderManager.inUnequip)
     {
         return;
     }
     if (!immediate)
     {
         if (!string.IsNullOrEmpty(equipment.referenceItem.DisableAnim) && equipment != null && equipment.equipPoint != null)
         {
             tpInput.animator.SetBool("FlipEquip", equipment.equipPoint.equipPointName.Contains("Left"));
             tpInput.animator.CrossFade(equipment.referenceItem.DisableAnim, 0.25f);
         }
         else
         {
             immediate = true;
         }
     }
     StartCoroutine(holderManager.UnequipRoutine(equipment.referenceItem.disableDelayTime, immediate, onStart, onFinish));
 }