示例#1
0
 public void RemoveActor(BaseActor actor)
 {
     if (actorList != null && actorList.Contains(actor))
     {
         actor.CurrentScene     = null;
         actor.PropertyChanged -= actorPropertyChanged;
         actor.Release();
         actorList.Remove(actor);
     }
 }
示例#2
0
 public void AddActor(BaseActor actor)
 {
     if (actorList == null)
     {
         actorList = new List <BaseActor>();
     }
     if (!actorList.Contains(actor))
     {
         actor.CurrentScene     = this;
         actor.PropertyChanged += actorPropertyChanged;
         actor.Load();
         actorList.Add(actor);
     }
 }
示例#3
0
 protected virtual void actorPropertyChanged(BaseActor actor, int id, object oldValue, object newValue)
 {
 }