using System; using XUtliPoolLib; namespace XMainClient { internal class XSubstance : XEntity { public override bool Initilize(int flag) { this._eEntity_Type |= XEntity.EnitityType.Entity_Substance; this._present = (XSingleton.singleton.CreateComponent(this, XPresentComponent.uuID) as XPresentComponent); this._machine = (XSingleton.singleton.CreateComponent(this, XStateMachine.uuID) as XStateMachine); XIdleComponent defaultState = XSingleton.singleton.CreateComponent(this, XIdleComponent.uuID) as XIdleComponent; this._death = (XSingleton.singleton.CreateComponent(this, XDeathComponent.uuID) as XDeathComponent); this._machine.SetDefaultState(defaultState); bool flag2 = (flag & XFastEnumIntEqualityComparer.ToInt(XEntity.InitFlag.Entity_Transform)) == 0; if (flag2) { this._net = (XSingleton.singleton.CreateComponent(this, XNetComponent.uuID) as XNetComponent); } return true; } protected override void Move() { } public override void Died() { bool flag = this.Attributes.TypeID == 5001u; if (flag) { XSingleton.singleton.DestroyEntity(this); } } } }