Ejemplo n.º 1
0
        private void RemoveMapSpawnpoint(int index)
        {
            var spawnpoint = _context.GetEntitiesWithSpawnpoint(index)
                             .FirstOrDefault();

            if (spawnpoint != null)
            {
                Debug.Log("Spawnpoint removed " + index + " : " + spawnpoint.mapPosition);
                spawnpoint.RemoveSpawnpoint();
            }
        }
Ejemplo n.º 2
0
    private Position GetBossPosition()
    {
        var sp = _tileContext.GetEntitiesWithSpawnpoint(-1).FirstOrDefault();

        if (sp == null)
        {
            throw new Exception("Boss spawnpoint is not set in map");
        }

        return(sp.mapPosition.Value);
    }