Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @SubscribeEvent
- public void worldTickEnd(TickEvent.WorldTickEvent event) {
- if(event.phase == TickEvent.Phase.END) {
- if(event.world.getWorldTime() % 2 == 0) {
- OreDataHooks.doRescan(event.world);
- }
- }
- }
- public static void doRescan(World world) {
- ChunkCoordTriplet key = toRescan.peek();
- if(key != null && key.dimID == world.provider.dimensionId) {
- key = toRescan.poll();
- OresBase.logger.log(Level.INFO, "Chunk " + key + " is missing ore data, it will be rescanned. Chunks way out on the edge of the world may not save and cause this message to repeat next launch; do not be alarmed.");
- OresBase.logger.log(Level.INFO, toRescan.size() + " chunks remain.");
- OresBase.oreCounter.generate(null, key.posX, key.posZ, world);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement