diff options
| author | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
|---|---|---|
| committer | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
| commit | 6eb915c129fc90c6f4c82ae097dd6ffad5239efc (patch) | |
| tree | 7dd2be50edf41f36b60fac84696e731c13afe617 /Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs | |
+scripts
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs')
| -rw-r--r-- | Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs b/Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs new file mode 100644 index 00000000..3e77f2fb --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/XRemoveItemEventArgs.cs @@ -0,0 +1,40 @@ +using System;
+using System.Collections.Generic;
+
+namespace XMainClient
+{
+ internal class XRemoveItemEventArgs : XEventArgs
+ {
+ public List<ulong> uids = new List<ulong>();
+
+ public List<ItemType> types = new List<ItemType>();
+
+ public List<int> ids = new List<int>();
+
+ public XRemoveItemEventArgs()
+ {
+ this._eDefine = XEventDefine.XEvent_RemoveItem;
+ }
+
+ public override void Recycle()
+ {
+ base.Recycle();
+ this.uids.Clear();
+ this.types.Clear();
+ this.ids.Clear();
+ XEventPool<XRemoveItemEventArgs>.Recycle(this);
+ }
+
+ public override XEventArgs Clone()
+ {
+ XRemoveItemEventArgs @event = XEventPool<XRemoveItemEventArgs>.GetEvent();
+ for (int i = 0; i < this.uids.Count; i++)
+ {
+ @event.uids.Add(this.uids[i]);
+ @event.types.Add(this.types[i]);
+ @event.ids.Add(this.ids[i]);
+ }
+ return @event;
+ }
+ }
+}
|
