UGCProjects/ProjectTemp_T/Script/Blueprint/BUFF/BuffAction/BuffAction_SingleRespiratoryRegurgitation.lua
2025-01-04 23:00:19 +08:00

39 lines
1.5 KiB
Lua
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

local BuffAction_SingleRespiratoryRegurgitation = {
-- 以下参数信息可以通过manager的 GetBuffDefaultParam(BuffPath, ParamName)来获取 --
-- 默认颜色信息,非必要参数
BuffColor = {R = 0.97, G = 0.88, B = 0.1, A = 1.};
--BuffIconPath = "默认Icon路径非必要参数";
--BuffParticlePath = "默认粒子路径,非必要参数";
--BuffDesc = "Buff描述信息非必要参数";
--------------------------------------------------------------------------------
PlayerKey = {};
};
--- 必须包含ApplyBuff函数
---@param BuffTag int32 Buff的标签
---@param ValidPawn UGCPlayerPawn_C
---@tparam Any
---@return bool 是否执行成功
function BuffAction_SingleRespiratoryRegurgitation:ApplyBuff(BuffTag, ValidPawn)
-- 添加一下
print(string.format('[BuffAction_SingleRespiratoryRegurgitation:ApplyBuff] 执行'))
UGCEventSystem.SendEvent(EventTypes.PlayerEnableRR, ValidPawn.PlayerKey, true);
self.PlayerKey = {
[1] = ValidPawn.PlayerKey;
}
return true
end
function BuffAction_SingleRespiratoryRegurgitation:RemoveBuff(BuffTag, ValidPawn)
print(string.format('[BuffAction_SingleRespiratoryRegurgitation:RemoveBuff] 结束执行'))
UGCEventSystem.SendEvent(EventTypes.PlayerEnableRR, ValidPawn.PlayerKey, false);
self.PlayerKey = {};
end
function BuffAction_SingleRespiratoryRegurgitation:GetBenefitPlayer()
return self.PlayerKey;
end
return BuffAction_SingleRespiratoryRegurgitation;