Jump to content

null

Members
  • Posts

    5
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by null

  1. i don't understand much of minecrafts chunk generation code, i implemented my own version. If you want to learn about manipulating noise in general you could dive into the subject of computer graphics, try the chapter about generative design from https://thebookofshaders.com/ .
  2. you write your blocks into the chunkprimer after you have copied it to the chunk, you call setBlocksInChunkIsland to late. Put it directly after "this.setBlocksInChunk ..." or after "this.biomesForGeneration = ..." if you want to manipulate the biomes. Edit: I am not shure if the world object has the biome information you need at this point, use biomesForGeneration instead, you have to calculate the coordinates manually since biomesForGeneration is an one dimensional array. Edit 2: Also you should not check for the right biome and instead just update the biome information when a block is set. [...] primer.setBlockState(k2, l2+upperScale, i3, iblockstate); if(iblockstate != Blocks.AIR.getDefaultState()) { this.biomesForGeneration[k2 + i3 * 16] = KCore.instance.FloatingIslands; //i am not shure about the coordinates it could be i3 + k2*16 instead } [...]
  3. Ok, but it would still be possible to find out at which positions the biomes need to be changed.
  4. If there are no floating stones then you probably don't want to change the biome there, i don't see the problem.
  5. I am no expert on this, but i would propose to get rid of the if(biome == KCore.instance.FloatingIslands) line. Floating islands will be created everywhere but there shouldn't be any chunk problems with chunk borders. If you really need to have a floating island biome at these positions then let the setBlocksInChunkIsland method return something telling you if there was at least one non-air block set, so you can fix the biome.
×
×
  • Create New...

Important Information

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