Started by
Ellse
on
Topic category: Troubleshooting, bugs, and solutions
I have a dimension in which I want to remove certain blocks placed by the player.
But when checked in the "see the sky" block it always returns false.
How to fix it?
Everything works without it, and I think it's mcreator's error.
I'm pretty sure the 'block is placed' trigger returns the position of the block you right clicked on to place, not the position of the new block. (It's the only reason why this wouldn't be working.) It would be checking if the block you placed it against is copper, and then it wouldn't be able to see the sky because the block at y+1 would be the block you just placed?
Otherwise, I'm not totally sure. It's possible the sky function is broken for custom dimensions, but if so you could either do this based on the y value of the block, or by making your own sky function. (You would need a while loop with a local number variable that returns true if the variable plus the y position equals the build limit, false if the block at the variable plus the y position is solid, and adds one to the variable and does nothing if the block at the current position is air.)
Thank you for fast answer. I was already convinced that “see the sky” DOES NOT work in this version of MCreator, so I implemented its functionality myself:
For this work, you need to create 2 variables:
i, check.
I have made a much simpler version because the block was broken for me as well, and adding to the y didnt do anything either. just in case the image isnt working ill just say what the code is:
if "get world surface height at (x, z)" = "y"
Image:
https://ibb.co/xJYcY4q
the original block is flawed, if you check the code for the original block the function's name is "CanBlockSeeSkyFromBelowWater" so i dont think its meant to be used like this
ah wait i put the wrong link for the image mb
theere we go