Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Villfuk02

Members
  • Joined

  • Last visited

Everything posted by Villfuk02

  1. Ok, i have this: if (chunkGenerator instanceof ChunkProviderOverworld) { ChunkProviderOverworld cpOverworld = (ChunkProviderOverworld) chunkProvider; } if am i doing this right so far, how do i get the MapGenVillage out of it? else tell me, what am i doing wrong
  2. THX So if i understood correctly i can cast IchunkGenerator into ChunkProviderOverworld, but i can't figure out what next
  3. Oh, i see and how do i get the ChunkProviderOverworld from the IChunkGenerator?
  4. you mean IChunkProvider? i tried this and i dont see any ChunkProviderOverworld passed into the generator
  5. Just tell me how do i get the structureMap field please
  6. i tried this world.getVillageCollection() but it's allways empty
  7. something like this? if (MapGenVillage.Start.this.getBoundingBox().minX <= x && MapGenVillage.Start.this.getBoundingBox().maxX >= x)
  8. ok, i'm novice to programming in java, so can you please explain me how does this work? i'm sorry, don't be mad at me please
  9. how do i get from this if is village in the chunk, or where is the nearest village or something like that
  10. How exactly do i do this?
  11. Ok, i made 4 variants - each with different metadata (0-3) and i want them to be randomly mixed in the veins. package vms.archeology.worldgen; import java.util.Random; import net.minecraft.block.Block; import net.minecraft.init.Biomes; import net.minecraft.init.Blocks; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; import net.minecraft.world.chunk.IChunkGenerator; import net.minecraft.world.chunk.IChunkProvider; import net.minecraft.world.gen.feature.WorldGenMinable; import net.minecraft.world.gen.feature.WorldGenerator; import net.minecraftforge.fml.common.IWorldGenerator; import vms.archeology.blocks.FertilizedDirt; import vms.archeology.init.ModBlocks; public class DepositeGeneration implements IWorldGenerator{ private WorldGenerator villagers; public DepositeGeneration() { fertilizedDirt = new WorldGenMinable(ModBlocks.fertilized_dirt.getDefaultState().withProperty(FertilizedDirt.DROP_ID, 0), 36, new DirtPredicate()); } private void runGenerator(WorldGenerator generator, World world, Random rand, int chunk_X, int chunk_Z, int chancesToSpawn, int minHeight, int maxHeight) { if (minHeight < 0 || maxHeight > 256 || minHeight > maxHeight) throw new IllegalArgumentException("Illegal Height Arguments for WorldGenerator"); int heightDiff = maxHeight - minHeight + 1; for (int i = 0; i < chancesToSpawn; i ++) { int x = chunk_X * 16 + rand.nextInt(16); int y = minHeight + rand.nextInt(heightDiff); int z = chunk_Z * 16 + rand.nextInt(16); generator.generate(world, rand, new BlockPos(x, y, z)); } } @Override public void generate(Random random, int chunkX, int chunkZ, World world, IChunkGenerator chunkGenerator, IChunkProvider chunkProvider) { switch(world.provider.getDimension()) { case 0: if(world.provider.getBiomeForCoords(new BlockPos(chunkX*16+random.nextInt(16),64,chunkZ*16+random.nextInt(16))) == Biomes.PLAINS){ this.runGenerator(fertilizedDirt, world, random, chunkX, chunkZ, 50, 60, 90); } case 1: break; case -1: break; } } }
  12. thx do you have any idea for the Village detection?
  13. so i made this new 'Ore' called Fertilized Dirt. It generates in the dirt on the surface of a world, but i want it to generate more near Villages. Is there a way to detect nerby Village when generating the world? BTW The block makes stone sound, even though i've set the material to GROUND, but i think it's problem with Forge, or has anything changed since 1.10? Thanx for any response
  14. thx, i'll look it up tomorrow i dont have any more time today, but thanks
  15. It look just lik the server is not syncing with the server, BUT WHY?????
  16. I have debugged this so many times and nothing seems suspicious. Everything does what it is supposed to and then it just resets like wtf
  17. Yes btw you can look here: https://github.com/Villfuk02/Essence/blob/master/java/com/villfuk02/essence/tileentities/TileEntityManualMill.java
  18. Hey, is anyone here? I just don thave any idea what to do with this, i tried everything ií could think of. PLZ HALP
  19. Just updated the TileEntityManualMill on GitHub. Now doesn't overwrite the outputs[] when processed.
  20. That was simple, but what about the saving?
  21. 1st recipe: leaves tallgrass melon wheat 2nd recipe: feather string glowstone_dust paper 3rd recipe: 4x essence dust of the same kind the items can be in any order
  22. try pressing the Mill button until it's done and then try to take it the item out of the inventory.
  23. How do you mean it saves for you?

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.