[SPIGOT-4216] ChunkData.setRegion() does not seem to do anything Created: 02/Aug/18  Updated: 03/Aug/18  Resolved: 02/Aug/18

Status: Resolved
Project: Spigot
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: lemon Assignee: Unassigned
Resolution: Invalid Votes: 0
Labels: 1.13, bug, world

Attachments: File world-test-plugin.jar    
Version: git-Spigot-69774b3-80c43fc (MC: 1.13)
Guidelines Read: Yes

 Description   

https://pastebin.com/Vn9JSr1S (ChunkData.setRegion() located at line 147)
this generates an empty void world, when it's supposed to generate a flat world.

if result.setRegion is replaced with 

for (int X = 0; X < 16; X++)
{
    for (int Z = 0; Z < 16; Z++)
    {
        result.setBlock(X, y, Z, materials[y]);
    }
}

it generates the flat world properly.

plugin attached generates an empty void world while it should be generating a normal flat world.

ChunkData.setRegion() worked properly in 1.12.



 Comments   
Comment by md_5 [ 03/Aug/18 ]

That aspect of the method hasn’t changed since 1.12.2

Yes, you will not get the materials you entered without api-version 1.13 (though there was a bug here that was fixed today also)

Comment by lemon [ 03/Aug/18 ]

oh then the method has changed from 1.12, sorry
but yeah GRASS_BLOCK doesn't resolve right without api-verson 1.13, and GRASS resolves to dead bush

Comment by md_5 [ 02/Aug/18 ]

Read the docs

  • @param yMin minimum y location (inclusive) in the chunk to set
  • @param yMax maximum y location (exclusive) in the chunk to set

yMax needs to be y+1

I did see a material conversion bug that needs to be fixed however

Generated at Tue Apr 22 07:16:04 UTC 2025 using Jira 10.3.5#10030005-sha1:190c783f2bd6c69cd5accdb70f97e48812a78d14.