fix: update logic pet.
This commit is contained in:
@@ -22,6 +22,7 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using UnityEditor.Experimental.GraphView;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
using static BrewMonster.Scripts.Managers.EC_Inventory;
|
||||
@@ -681,15 +682,15 @@ namespace BrewMonster
|
||||
// other goblin skills should be set public cool down, 1 second
|
||||
/* for (i = 0; i < m_aGoblinSkills.GetSize(); i++)
|
||||
{
|
||||
if (m_aGoblinSkills[i] && m_aGoblinSkills[i]->GetCoolingCnt() == 0)
|
||||
m_aGoblinSkills[i]->StartCooling(GetCoolTime(GP_CT_CAST_ELF_SKILL), GetCoolTime(GP_CT_CAST_ELF_SKILL));
|
||||
if (m_aGoblinSkills[i] && m_aGoblinSkills[i].GetCoolingCnt() == 0)
|
||||
m_aGoblinSkills[i].StartCooling(GetCoolTime(GP_CT_CAST_ELF_SKILL), GetCoolTime(GP_CT_CAST_ELF_SKILL));
|
||||
}*/
|
||||
|
||||
/* for (i = 0; i < m_aPsSkills.Count; i++)
|
||||
{
|
||||
CECSkill pSkill = GetPassiveSkillByIndex(i);
|
||||
if (pSkill && (pSkill->GetCommonCoolDown() & (1 << (pCmd->cooldown_index - GP_CT_SKILLCOMMONCOOLDOWN0))))
|
||||
pSkill->StartCooling(GetCoolTime(pCmd->cooldown_index), GetCoolTime(pCmd->cooldown_index));
|
||||
if (pSkill && (pSkill.GetCommonCoolDown() & (1 << (pCmd.cooldown_index - GP_CT_SKILLCOMMONCOOLDOWN0))))
|
||||
pSkill.StartCooling(GetCoolTime(pCmd.cooldown_index), GetCoolTime(pCmd.cooldown_index));
|
||||
}*/
|
||||
}
|
||||
|
||||
@@ -734,7 +735,7 @@ namespace BrewMonster
|
||||
}
|
||||
/* else if (pSkill = CECComboSkillState::Instance().GetInherentSkillByID(idSkill))
|
||||
{
|
||||
pSkill->StartCooling(pCmd->cooldown_time, pCmd->cooldown_time);
|
||||
pSkill.StartCooling(pCmd.cooldown_time, pCmd.cooldown_time);
|
||||
}*/
|
||||
else if (GetEquipSkillByID(idSkill) == null)
|
||||
{
|
||||
@@ -6885,5 +6886,30 @@ namespace BrewMonster
|
||||
|
||||
// Get pet corral object
|
||||
public CECPetCorral GetPetCorral() { return m_pPetCorral; }
|
||||
|
||||
/* Is host operating pet ?
|
||||
return value:
|
||||
|
||||
0: host doesn't operating pet.
|
||||
1: host is summoning pet.
|
||||
2: host is recalling pet.
|
||||
3: host is banishing pet.
|
||||
*/
|
||||
public int IsOperatingPet()
|
||||
{
|
||||
CECHPWorkConcentrate pWork = (m_pWorkMan.GetRunningWork(CECHPWork.Host_work_ID.WORK_CONCENTRATE)) as CECHPWorkConcentrate;
|
||||
if (pWork != null)
|
||||
{
|
||||
if (pWork.GetDoWhat() == (int)CECHPWorkConcentrate.eDO_PET.DO_SUMMONPET)
|
||||
return 1;
|
||||
else if (pWork.GetDoWhat() == (int)CECHPWorkConcentrate.eDO_PET.DO_RECALLPET)
|
||||
return 2;
|
||||
else if (pWork.GetDoWhat() == (int)CECHPWorkConcentrate.eDO_PET.DO_BANISHPET)
|
||||
return 3;
|
||||
else if (pWork.GetDoWhat() == (int)CECHPWorkConcentrate.eDO_PET.DO_RESTOREPET)
|
||||
return 4;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user