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/XBoss.cs |
+scripts
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/XBoss.cs')
-rw-r--r-- | Client/Assets/Scripts/XMainClient/XBoss.cs | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/XBoss.cs b/Client/Assets/Scripts/XMainClient/XBoss.cs new file mode 100644 index 00000000..bdd3b9a8 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/XBoss.cs @@ -0,0 +1,43 @@ +using System;
+using UnityEngine;
+using XUtliPoolLib;
+
+namespace XMainClient
+{
+ internal sealed class XBoss : XOpposer
+ {
+ public override bool Initilize(int flag)
+ {
+ base.Initilize(flag);
+ this._eEntity_Type |= XEntity.EnitityType.Entity_Boss;
+ this._layer = LayerMask.NameToLayer("BigGuy");
+ bool flag2 = (flag & XFastEnumIntEqualityComparer<XEntity.InitFlag>.ToInt(XEntity.InitFlag.Entity_Transform)) == 0;
+ if (flag2)
+ {
+ this._qte = (XSingleton<XComponentMgr>.singleton.CreateComponent(this, XQuickTimeEventComponent.uuID) as XQuickTimeEventComponent);
+ }
+ return true;
+ }
+
+ public override void Dying()
+ {
+ base.Dying();
+ }
+
+ public override void OnDestroy()
+ {
+ bool flag = XSingleton<XEntityMgr>.singleton.Boss == this;
+ if (flag)
+ {
+ XSingleton<XEntityMgr>.singleton.Boss = null;
+ }
+ base.OnDestroy();
+ }
+
+ public override void OnCreated()
+ {
+ base.OnCreated();
+ XSingleton<XEntityMgr>.singleton.Boss = this;
+ }
+ }
+}
|