(TextureMap textureMap)
| 74 | } |
| 75 | |
| 76 | private static void loadProperties(TextureMap textureMap) |
| 77 | { |
| 78 | betterGrass = true; |
| 79 | betterMycelium = true; |
| 80 | betterPodzol = true; |
| 81 | betterGrassSnow = true; |
| 82 | betterMyceliumSnow = true; |
| 83 | betterPodzolSnow = true; |
| 84 | spriteGrass = textureMap.registerSprite(new ResourceLocation("blocks/grass_top")); |
| 85 | spriteGrassSide = textureMap.registerSprite(new ResourceLocation("blocks/grass_side")); |
| 86 | spriteMycelium = textureMap.registerSprite(new ResourceLocation("blocks/mycelium_top")); |
| 87 | spritePodzol = textureMap.registerSprite(new ResourceLocation("blocks/dirt_podzol_top")); |
| 88 | spriteSnow = textureMap.registerSprite(new ResourceLocation("blocks/snow")); |
| 89 | spritesLoaded = true; |
| 90 | String s = "optifine/bettergrass.properties"; |
| 91 | |
| 92 | try |
| 93 | { |
| 94 | ResourceLocation resourcelocation = new ResourceLocation(s); |
| 95 | |
| 96 | if (!Config.hasResource(resourcelocation)) |
| 97 | { |
| 98 | return; |
| 99 | } |
| 100 | |
| 101 | InputStream inputstream = Config.getResourceStream(resourcelocation); |
| 102 | |
| 103 | if (inputstream == null) |
| 104 | { |
| 105 | return; |
| 106 | } |
| 107 | |
| 108 | boolean flag = Config.isFromDefaultResourcePack(resourcelocation); |
| 109 | |
| 110 | if (flag) |
| 111 | { |
| 112 | Config.dbg("BetterGrass: Parsing default configuration " + s); |
| 113 | } |
| 114 | else |
| 115 | { |
| 116 | Config.dbg("BetterGrass: Parsing configuration " + s); |
| 117 | } |
| 118 | |
| 119 | Properties properties = new PropertiesOrdered(); |
| 120 | properties.load(inputstream); |
| 121 | inputstream.close(); |
| 122 | betterGrass = getBoolean(properties, "grass", true); |
| 123 | betterMycelium = getBoolean(properties, "mycelium", true); |
| 124 | betterPodzol = getBoolean(properties, "podzol", true); |
| 125 | betterGrassSnow = getBoolean(properties, "grass.snow", true); |
| 126 | betterMyceliumSnow = getBoolean(properties, "mycelium.snow", true); |
| 127 | betterPodzolSnow = getBoolean(properties, "podzol.snow", true); |
| 128 | grassMultilayer = getBoolean(properties, "grass.multilayer", false); |
| 129 | spriteGrass = registerSprite(properties, "texture.grass", "blocks/grass_top", textureMap); |
| 130 | spriteGrassSide = registerSprite(properties, "texture.grass_side", "blocks/grass_side", textureMap); |
| 131 | spriteMycelium = registerSprite(properties, "texture.mycelium", "blocks/mycelium_top", textureMap); |
| 132 | spritePodzol = registerSprite(properties, "texture.podzol", "blocks/dirt_podzol_top", textureMap); |
| 133 | spriteSnow = registerSprite(properties, "texture.snow", "blocks/snow", textureMap); |
no test coverage detected