UGCProjects/GZJ/Script/SimpleSkill/Condition/SimpleSkillCastCondition_IsNeedHeal.lua

14 lines
592 B
Lua
Raw Permalink Normal View History

2025-01-08 22:46:12 +08:00
local SimpleSkillCastCondition = LuaClass("SimpleSkillCastCondition");
local SimpleSkillCastCondition_IsNeedHeal = LuaClass("SimpleSkillCastCondition_IsNeedHeal", SimpleSkillCastCondition);
function SimpleSkillCastCondition_IsNeedHeal:Check(CasterPlayerPawn)
local IsFullHealth = CasterPlayerPawn:IsFullHealth()
local IsFullEnergy = CasterPlayerPawn:IsFullEnergy()
local Result = not (IsFullHealth == true and IsFullEnergy == true)
UE.Log("[SimpleSkillCastCondition_IsNeedHeal] Check = "..tostring(Result))
return Result
end
return SimpleSkillCastCondition_IsNeedHeal;