public void SaveInstances() { LockClient(); List <MapInterface.ObjectInstance> instance = new List <MapInterface.ObjectInstance>(map.mapInterface.objectInstances); List <MapInterface.ObjectWall> walls = new List <MapInterface.ObjectWall>(map.mapInterface.objectWalls); //Load with latest map.LoadMap(this.graphics); //Save map.mapInterface.objectInstances = instance; map.mapInterface.objectWalls = walls; map.mapInterface.Save(); UnlockClient(); //Now client must have latest ipc.SendMessage("reload map"); }
public CollisionDemo(gfx.Graphics graphics) { this.graphics = graphics; initState = new prim.InitStateMachine(); map = new gfx.GameMap(graphics); map.LoadMap(graphics, "res/maps/CollisionDemo.hjm"); map.AddControlEntity(graphics, "test"); }