diff options
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/PTC/Process/Process_PtcG2C_ClientOnlyBuffNotify.cs')
-rw-r--r-- | Client/Assets/Scripts/XMainClient/PTC/Process/Process_PtcG2C_ClientOnlyBuffNotify.cs | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/PTC/Process/Process_PtcG2C_ClientOnlyBuffNotify.cs b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_PtcG2C_ClientOnlyBuffNotify.cs new file mode 100644 index 00000000..7204ce9f --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_PtcG2C_ClientOnlyBuffNotify.cs @@ -0,0 +1,38 @@ +using System;
+using KKSG;
+using XUtliPoolLib;
+
+namespace XMainClient
+{
+ internal class Process_PtcG2C_ClientOnlyBuffNotify
+ {
+ public static void Process(PtcG2C_ClientOnlyBuffNotify roPtc)
+ {
+ XRole xrole = XSingleton<XEntityMgr>.singleton.GetEntity(roPtc.Data.roleid) as XRole;
+ bool flag = !XEntity.ValideEntity(xrole);
+ if (!flag)
+ {
+ for (int i = 0; i < roPtc.Data.buffs.Count; i++)
+ {
+ XBuffAddEventArgs @event = XEventPool<XBuffAddEventArgs>.GetEvent();
+ Buff buff = roPtc.Data.buffs[i];
+ @event.xBuffDesc.BuffID = buff.buffID;
+ @event.xBuffDesc.BuffLevel = buff.buffLevel;
+ @event.Firer = xrole;
+ @event.xBuffDesc.CasterID = roPtc.Data.casterid;
+ bool skillIDSpecified = buff.skillIDSpecified;
+ if (skillIDSpecified)
+ {
+ @event.xBuffDesc.SkillID = buff.skillID;
+ }
+ bool effecttimeSpecified = buff.effecttimeSpecified;
+ if (effecttimeSpecified)
+ {
+ @event.xBuffDesc.EffectTime = buff.effecttime;
+ }
+ XSingleton<XEventMgr>.singleton.FireEvent(@event);
+ }
+ }
+ }
+ }
+}
|