Minecraft 1.11.2
Skript v2.2-dev26f
Umbaska v3.3
SkQuery-Lime 1.11
SkStuff v1.6.4.1
Skellett v1.9.0e
I'm tinkering with the chunk generate event to remove leaves from trees. It's slow, but I'm just playing around right now.
When the chunk generates, I'm looping through all the blocks and setting any "leaf" blocks to "air":
I'm sure this is a terrible idea performance-wise, I'm sure there's much better ways to do this, but I'll get to that eventually. What I'm struggling with is that trees frequently generate in a specific chunk, but leaves overlap in nearby already generated chunks, and I'm unable to capture that event and remove those trees.
Any suggestions? Is there a syntax that works for event-chunk's neighboring chunks? I've tried variations on "loop blocks within chunk north of event-chunk" and whatnot, to no avail:
*edit*
Never mind, this works:
It's really, REALLY slow though, even with just one cardinal direction. It'll be about 4x slower once I factor in all four directions AND diagonals...
Skript v2.2-dev26f
Umbaska v3.3
SkQuery-Lime 1.11
SkStuff v1.6.4.1
Skellett v1.9.0e
I'm tinkering with the chunk generate event to remove leaves from trees. It's slow, but I'm just playing around right now.
When the chunk generates, I'm looping through all the blocks and setting any "leaf" blocks to "air":
code_language.skript:
on chunk generate:
loop blocks within event-chunk:
if loop-block-1 is leaves:
set loop-block-1 to air
I'm sure this is a terrible idea performance-wise, I'm sure there's much better ways to do this, but I'll get to that eventually. What I'm struggling with is that trees frequently generate in a specific chunk, but leaves overlap in nearby already generated chunks, and I'm unable to capture that event and remove those trees.
Any suggestions? Is there a syntax that works for event-chunk's neighboring chunks? I've tried variations on "loop blocks within chunk north of event-chunk" and whatnot, to no avail:
Code:
loop blocks within chunk north of event-chunk:
if loop-block-1 is leaves:
set loop-block-1 to air
*edit*
Never mind, this works:
Code:
on chunk generate:
loop blocks within event-chunk:
if loop-block-1 is leaves:
set loop-block-1 to air
set {_loc} to block at 8, 1, 8 in event-chunk
loop blocks within chunk north of {_loc}:
if loop-block-1 is leaves:
set loop-block-1 to air
It's really, REALLY slow though, even with just one cardinal direction. It'll be about 4x slower once I factor in all four directions AND diagonals...