public Mobile SpawnGeneral(BarrierCrystal crystal) { try { Mobile m = Activator.CreateInstance(m_SpawnList.GetRandomGeneral()) as Mobile; m.OnBeforeSpawn(crystal.Location, crystal.Map); m.MoveToWorld(crystal.Location, crystal.Map); m.OnAfterSpawn(); return(m); } catch { } return(null); }
public ArrayList SpawnMinions(int amount, BarrierCrystal crystal) { ArrayList list = new ArrayList(); for (int i = 0; i < amount; i++) { try { Mobile m = Activator.CreateInstance(m_SpawnList.GetRandomMinion()) as Mobile; m.OnBeforeSpawn(crystal.Location, crystal.Map); m.MoveToWorld(crystal.Location, crystal.Map); m.OnAfterSpawn(); list.Add(m); } catch { } } return(list); }
public CitySpawner(BarrierCrystal crystal) { m_Crystal = crystal; GetSpawnList(); }