Esempio n. 1
0
        public void AddCharacterToArena(ICharacter c, Alliance alliance, int? xLoc = null, int? yLoc = null)
        {
            if (ArenaFloor == null)
            {
                throw new Exception("Arena not been constructed!");
            }
            c.ChangeAlliance(alliance);
            Characters.Add(c);

            if (xLoc == null || yLoc == null)
            {
                SetDefaultCharacterLocation(c);
            }
            else
            {
                ArenaFloor[(int)xLoc, (int)yLoc].AddEntityToTile((Character)c);
            }
        }