Exemple #1
0
 public void RemoveActor(BaseActor actor)
 {
     if (null != actor && actorList.Contains(actor))
     {
         actorList.Remove(actor);
         actor.PropertyChanged -= OnActorPropertyChanged;
         //actor.Release();
         actor = null;
     }
 }
Exemple #2
0
 public void AddActor(BaseActor actor)
 {
     if (null != actor && !actorList.Contains(actor))
     {
         actorList.Add(actor);
         actor.CurrentScene     = this;
         actor.PropertyChanged += OnActorPropertyChanged;
         //actor.Load();
     }
 }
Exemple #3
0
 /// <summary>
 /// 角色属性变更
 /// </summary>
 /// <param name="actor"></param>
 /// <param name="id"></param>
 /// <param name="oldValue"></param>
 /// <param name="newValue"></param>
 protected void OnActorPropertyChanged(BaseActor actor, int id, object oldValue, object newValue)
 {
 }