protected virtual void EquipWeapon() { if (mLastEquipTime + AttackDelay < Time.time) { mBasicInventory.EquipWeaponSet(); mLastEquipTime = Time.time; } }
internal override string Tick() { if (m_InventorySource.IsWeaponSetEquipped(m_WeaponSetID)) { m_IsMotionActive = false; return("Weapon set already equipped"); } if (!m_IsMotionActive) { m_InventorySource.EquipWeaponSet(m_WeaponSetID); m_IsMotionActive = true; return(""); } return("Equip motion is already active."); }
void Equip() { GameObject go = Fsm.GetOwnerDefaultTarget(gameObject); if (go == null) { return; } mBasicInventory = go.GetComponent <BasicInventory>(); int lWeaponSetIndex = (UseCurrentSet ? -1 : weaponSet.Value); if (mBasicInventory != null) { if (mBasicInventory.IsWeaponSetEquipped(lWeaponSetIndex)) { Finish(); return; } mBasicInventory.EquipWeaponSet(lWeaponSetIndex); } }