示例#1
0
        public override void OnDeregister()
        {
            if (LifespanAI.IsSubscribed(this))
            {
                LifespanAI.Unsubscribe(this);
            }

            base.OnDeregister();
        }
示例#2
0
 /// <summary>
 /// Subscribes the monsters moving ai if an
 /// character appears.
 /// </summary>
 /// <param name="character"></param>
 public override void Appears(Character character)
 {
     //ENABLE THE AI
     if (!LifespanAI.IsSubscribed(this))
     {
         Lifespan.lasttick = Environment.TickCount;
         LifespanAI.Subscribe(this);
     }
 }