public WorldmapSector(string Filename) { List WorldMapL = Util.Load(Filename, "supertux-worldmap"); LispIterator iter = new LispIterator(WorldMapL); while(iter.MoveNext()) { switch(iter.Key) { case "properties": Properties Props = new Properties(iter.List); Props.Get("name", ref Name); Props.Get("music", ref Music); Console.WriteLine("Name: " + Name); Console.WriteLine("Music: " + Music); Props.PrintUnusedWarnings(); break; case "spawnpoint": WorldmapSpawnPoint SpawnPoint = new WorldmapSpawnPoint(); SpawnPoint.Parse(iter.List); SpawnPoints.Add(SpawnPoint.Name, SpawnPoint); break; default: GameObject Object = ParseObject(iter.Key, iter.List); if(Object != null) AddObject(Object); break; } } Player = new WorldmapTux(this); AddObject(Player); Spawn("default"); }
public virtual void Touch(WorldmapTux Player, bool touch) { if(touch) TouchedPlayers.Add(Player); else TouchedPlayers.Remove(Player); }
public override void Use(WorldmapTux Player) { Console.WriteLine("Play Level " + LevelFile); Solved = true; }
public void HandleCollision(WorldmapTux Player, WorldmapObject Object) { Object.Touch(Player, true); }
public virtual void Use(WorldmapTux Player) { }