summaryrefslogtreecommitdiff
path: root/mcmap/examples/replace
diff options
context:
space:
mode:
authorKevin Chabowski <kevin@kch42.de>2013-08-12 15:20:47 +0200
committerKevin Chabowski <kevin@kch42.de>2013-08-12 15:20:47 +0200
commitbb8ddfbc5574a7682594fd15178083f5308766e7 (patch)
tree58557589315265f55b9979950629f75f80dcdd08 /mcmap/examples/replace
parent230c827d579d868327f7b0ef31284e1154c80f06 (diff)
downloadgomcmap-bb8ddfbc5574a7682594fd15178083f5308766e7.tar.gz
gomcmap-bb8ddfbc5574a7682594fd15178083f5308766e7.tar.bz2
gomcmap-bb8ddfbc5574a7682594fd15178083f5308766e7.zip
Getting rid of some magic numbers.
Diffstat (limited to 'mcmap/examples/replace')
-rw-r--r--mcmap/examples/replace/main.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/mcmap/examples/replace/main.go b/mcmap/examples/replace/main.go
index e5fff78..87dd677 100644
--- a/mcmap/examples/replace/main.go
+++ b/mcmap/examples/replace/main.go
@@ -37,9 +37,9 @@ chunkLoop:
}
modified := false
- for y := 0; y < 256; y++ {
- for x := 0; x < 16; x++ {
- for z := 0; z < 16; z++ {
+ for y := 0; y < mcmap.ChunkSizeY; y++ {
+ for x := 0; x < mcmap.ChunkSizeXZ; x++ {
+ for z := 0; z < mcmap.ChunkSizeXZ; z++ {
blk := chunk.Block(x, y, z)
if blk.ID == mcmap.BlkBlockOfIron {
blk.ID = mcmap.BlkBlockOfDiamond