--- miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/TemplateCommand.java 2012/03/19 10:01:12 1755 +++ miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/TemplateCommand.java 2012/03/19 20:21:14 1759 @@ -120,7 +120,7 @@ if (line.length() == 0) continue; - if (line.charAt(0) == '-') + if (line.charAt(0) == '#') continue; if ( y >= ysize) { @@ -145,7 +145,7 @@ throw new Exception( "Template: invalid value on line " + lines + ": " + element[0] ); } - if (val < 0 || val>255) { + if (val < -1 || val>255) { throw new Exception( "Template: invalid value on line " + lines + ": " + val ); } @@ -218,6 +218,10 @@ int type = template[i][j][k].id; byte data = (byte) template[i][j][k].subId; + + if (type == -1) { + continue; + } //plugin.getLogger().info( String.format( "Setting typeid at %d,%d,%d to %d", x,y,z, type) ); @@ -228,6 +232,10 @@ continue; if (type == 68) // sign continue; + if (type == 65) // ladder + continue; + if (type == 67) // steps + continue; } world.getBlockAt(x, y, z).setTypeIdAndData(type, data, true);