Chunk data procedures plugin request

Started by The Windows Ex… on

Topic category: Plugins and third-party tools

Joined Feb 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Chunk data procedures plugin request

Don't really know if this is possible, but it would be nice to have a plugin that gives us procedures to edit chunk data or even add new chunk data which would be useful for adding things like a radiation system.

Joined Jun 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yes, I NEED this!
Tue, 06/29/2021 - 16:09

Yes, I NEED this!

Joined Jun 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Ok so I need this for a land…
Wed, 06/30/2021 - 04:03

Ok so I need this for a land claiming system and I found a workaround thatll let me atleast save chunk locations and call back to them

 

WARNING: This solution requires the ArrayLists plugin found here: https://mcreator.net/plugin/65659/arraylists

 

Array = [0, 16, 32, 48, 64, …, 37500]

Set xD = x MOD 16

If xD =/= 0

  • xChunk = (x - xD) / 16

Else

  • xChunk = x / 16

Set zD = z MOD 16

If zD =/= 0

  • zChunk = (z - zD) / 16

Else

  • zChunk = z / 16

Say "This is Chunk [" + Array[xChunk] + ", " + Array[zChunk] + "]."

 

Q&A

Q1: Why stop at 375000?

A1: That is the default world border (6,000,000) divided by 16

 

Q2: How does this work?

A2: I was testing and found out that chunks start at the North West corner (where X and Z are divisible from 16) and ran with that. Basically, it gets the location, doing MOD reveals how many blocks they are away from being divisible by 16, they move there, and then reference the array to get a chunk-based X and Z! It sounds complex but its just simple math using MOD.