Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Iterator itwhile = HarvestLevel.iterator();
- Iterator ittool = ToolHash.iterator();
- while (itwhile.hasNext())
- {
- String raw1 = itwhile.next().toString();
- String[] partaa = raw1.split("=");
- String blocka = partaa[0];
- String strlevel = partaa[1];
- int level = Integer.parseInt(strlevel);
- String replaced = blocka.replaceFirst(":", "\u00A9");
- String[] partsH = replaced.split("\u00A9");
- String modidH = partsH[0];
- String blockH = partsH[1];
- if (!SpawnerList.contains(blocka))
- {
- MainJava.SpawnerChecker.put(blocka, "no_value");
- }
- //preventitive code that if defined in harvestlevel.txt then it will set the spawner level through all via tools to 0 so it won't drop if it's not the right configed harvest level
- //because, if a harvest level is set to 10 and theirs is 3 it will still not drop so this code makes it drop if their harvest level in the config is right...
- while (ittool.hasNext())
- {
- String tool = ittool.next().toString();
- Block blockh = GameRegistry.findBlock(modidH, blockH);
- if (blockh != null)
- {
- blockh.setHarvestLevel(tool, level);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement