/[projects]/miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/creative/GeneralContractorCommands.java
ViewVC logotype

Diff of /miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/creative/GeneralContractorCommands.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3196 by torben, Mon May 29 13:03:52 2017 UTC revision 3239 by torben, Wed Jul 18 07:59:05 2018 UTC
# Line 31  public class GeneralContractorCommands i Line 31  public class GeneralContractorCommands i
31                          Material.GRASS,                          Material.GRASS,
32                          Material.DIRT,                          Material.DIRT,
33                          Material.COBBLESTONE,                          Material.COBBLESTONE,
34                          Material.WOOD,                          
35                            //Material.WOOD,
36                            Material.ACACIA_WOOD,
37                            Material.BIRCH_WOOD,
38                            Material.DARK_OAK_WOOD,
39                            Material.JUNGLE_WOOD,
40                            Material.OAK_WOOD,
41                            Material.SPRUCE_WOOD,
42    
43                          Material.BEDROCK,                          Material.BEDROCK,
44                          Material.WATER,                          Material.WATER,
45                          Material.SAND,                          Material.SAND,
# Line 39  public class GeneralContractorCommands i Line 47  public class GeneralContractorCommands i
47                          Material.GOLD_ORE,                          Material.GOLD_ORE,
48                          Material.IRON_ORE,                          Material.IRON_ORE,
49                          Material.COAL_ORE,                          Material.COAL_ORE,
50                          Material.LOG,                          
51                          Material.LEAVES,                          //Material.LOG,
52                            Material.ACACIA_LOG,
53                            Material.BIRCH_LOG,
54                            Material.DARK_OAK_LOG,
55                            Material.JUNGLE_LOG,
56                            Material.OAK_LOG,
57                            Material.SPRUCE_LOG,
58                            //Material.LEAVES,
59                            Material.ACACIA_LEAVES,
60                            Material.BIRCH_LEAVES,
61                            Material.DARK_OAK_LEAVES,
62                            Material.JUNGLE_LEAVES,
63                            Material.OAK_LEAVES,
64                            Material.SPRUCE_LEAVES,
65                            
66                          Material.GLASS,                          Material.GLASS,
67                          Material.LAPIS_ORE,                          Material.LAPIS_ORE,
68                          Material.LAPIS_BLOCK,                          Material.LAPIS_BLOCK,
69                          Material.SANDSTONE,                          Material.SANDSTONE,
70                          Material.WOOL,                          //Material.WOOL,
71                            Material.BLACK_WOOL,
72                            Material.WHITE_WOOL,
73                            Material.GRAY_WOOL,
74                            
75                          Material.GOLD_BLOCK,                          Material.GOLD_BLOCK,
76                          Material.IRON_BLOCK,                          Material.IRON_BLOCK,
77                          Material.BRICK,                          Material.BRICK,
# Line 395  public class GeneralContractorCommands i Line 421  public class GeneralContractorCommands i
421    
422                  World world = loc.getWorld();                  World world = loc.getWorld();
423    
424                  int count = 0;                  
425                  for (int x=(playerX-radius); x<=(playerX+radius); x++) {                  for (int x=(playerX-radius); x<=(playerX+radius); x++) {
426                          for (int z=(playerZ-radius); z<=(playerZ+radius); z++) {                          for (int z=(playerZ-radius); z<=(playerZ+radius); z++) {
427    
428                                  int y_max = playerY+radius;                                  int y_max = playerY+radius;
429                                  //for (int y=playerY; y<=playerY+radius; y++) {                                  //for (int y=playerY; y<=playerY+radius; y++) {
430                                  for (int y=playerY; y<=y_max; y++) {                                  for (int y=playerY; y<=y_max; y++) {
431                                          count++;  
432                                          world.getBlockAt(x, y, z).setType(Material.AIR);                                          world.getBlockAt(x, y, z).setType(Material.AIR);
433                                                                                    
434                                  }                                  }
# Line 426  public class GeneralContractorCommands i Line 452  public class GeneralContractorCommands i
452    
453                  World world = loc.getWorld();                  World world = loc.getWorld();
454    
                 int count = 0;  
455                  for (int x=(playerX-radius); x<=(playerX+radius); x++) {                  for (int x=(playerX-radius); x<=(playerX+radius); x++) {
456                          for (int z=(playerZ-radius); z<=(playerZ+radius); z++) {                          for (int z=(playerZ-radius); z<=(playerZ+radius); z++) {
457    
458                                  //for (int y=playerY; y<=playerY+radius; y++) {                                  //for (int y=playerY; y<=playerY+radius; y++) {
459                                  for (int y=playerY; y<=Y_MAX; y++) {                                  for (int y=playerY; y<=Y_MAX; y++) {
                                         count++;  
460                                          world.getBlockAt(x, y, z).setType(Material.AIR);                                          world.getBlockAt(x, y, z).setType(Material.AIR);
461                                                                                    
462                                  }                                  }

Legend:
Removed from v.3196  
changed lines
  Added in v.3239

  ViewVC Help
Powered by ViewVC 1.1.20