public World() { //Mobs = new ConcurrentDictionary<int, Mob>(); //GameItems = new ConcurrentDictionary<int, GameItemDynamic>(); RawSeed = 123456; //settingsNode.Attributes["RawSeed"].Value; GeneratorVersion = "1.0"; // settingsNode.Attributes["GeneratorVersion"].Value; GameObjectIdSeq = 1; //int.Parse(settingsNode.Attributes["GameObjectIdSeq"].Value); WorldType = WorldType.Grass; // (WorldType)Convert.ToInt32(settingsNode.Attributes["WorldType"].Value); generator = new Generator(this, RawSeed); worldMap = new WorldMap(this, generator); localMap = new LocalMap(this, generator); water = new Water(this); }
public int GetHeightMapLevel(int x, int z) { return(LocalMap.Chunk(x / Global.CHUNK_SIZE, z / Global.CHUNK_SIZE).HeightMap[x % Global.CHUNK_SIZE, z % Global.CHUNK_SIZE]); }