Ejemplo n.º 1
0
        /// <summary>
        /// Set the player object
        /// </summary>
        /// <param name="ego"></param>
        /// <param name="inRoom"></param>
        public void SetEgo(Ego ego, Room inRoom = null)
        {
            if (IsSetupFinalised)
            {
                throw new InvalidOperationException("Cannot set Ego after game state setup is finalised");
            }

            Ego = ego;
            if (inRoom != null)
            {
                Ego.MoveTo(inRoom);
            }
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Set the current location of the player
 /// </summary>
 /// <param name="room"></param>
 public void SetCurrentLocation(Room room)
 {
     Ego.MoveTo(room);
 }