示例#1
0
        public void InteractWith(WorldEntity e)
        {
            Type t = e.GetType();

            if (actions.ContainsKey(e.GetType()))
            {
                MethodInfo info = actions[t];
                info.Invoke(this, new object[] { e });
            }
        }
示例#2
0
 public void InteractionWorldEntity(WorldEntity e)
 {
     MessageBox.Show("Interacted with world entity! " + e);
 }
示例#3
0
 public void AddEntity(WorldEntity entity)
 {
     entity.WorldIn = this;
     this.entities.Add(entity);
 }