Global Map and World Variables Not Saving

Upvotes: 2
Issue description

I was told to make a support ticket about this after I made a forum topic on this. The first paragraph is everything from the forum post and the second is new stuff.

I have a block that stores it's position in 3 global map variables (x, y, z) and a item that will teleport the player on top of that block. These variables are set as soon as the player places the block. Everything works perfectly until the player leaves the world. For some reason, it resets all the variables back to the initial values. According the the wiki page on variables, global map variables should save with the world so I don't know why they reset. Is this a bug or can someone explain this to me? I'm using the trigger "When block is placed by" in the block's triggers. The procedure the trigger calls is an if statement testing if the block has not been placed (the initial value of the variables, "123456789," have not been replaced) it will set the global map variables x, y, and z, to the block's x, y, and z coordinates. Just to be clear, the actual variable names are not "x," "y," and "z," just in case that might cause a different issue.

You can recreate this bug by-

1. Creating a new world

2. Placing the "Farlands Portal" from the transportation creative tab

3. Right clicking the Farlands Portal

4. Closing the world

Here's a video showcasing the bug: https://www.youtube.com/watch?v=nlGhLN4OGzg&feature=youtu.be

Attachment Size
Workspace for the mod118.06 KB 118.06 KB

Issue comments

Thank you for your bug report. I will verify this and try to fix this bug.

I was able to reproduce this bug in an isolated case, so I will now do my best to fix this.

You are welcome! I am glad I could help :) If you like what we do, consider donating to us to help us keep this project up.



Donate to MCreator

By donating to developers you can speed up development, as with more resources, we can dedicate more time to MCreator. It is a free project made by developers working on it in their free time.