Mojira Archive
MCM-229

Ticking areas start ticking on world load before any player has entered the world

Verification builds: Release 853103
Summary: After a world is loaded, ticking areas are processed for approximately 25 ticks before a player joins.

Impact: Any ticking command that checks for a player will fail after relog, which can and will trigger all sorts of faulty states.

Repro Steps:
A) Existence of Problem
Simple reproduction that proves only that the problem exists:

1. Construct the displayed contraption.
2. In the blue block, set the command to /testfor @a
3. In the orange block, set the command to /summon minecart ~ ~1 ~
4. Logically, the orange block should never run.
5. Relog and notice that nothing happened (correct!)
6. Create a ticking area that encompasses the contraption.
7. Relog and notice the minecart (bad!)

B) Extent of Problem
Involved reproduction that demonstrates the duration of the problem:

1. Construct the displayed contraption, with the chain pointing in the -X direction (keep in mind the F3 screen is incorrect in the 1.4.0 build (MCM-227)).
2. First block: /setblock ~ ~1 ~ stone
3. Second block: /testfor @a
4. Third block: /setblock ~2 ~1 ~ dirt
5. Fourth block: /testforblock ~3 ~1 ~ stone
6. Fifth block: /summon minecart ~ ~1 ~
7. Create a ticking area that encompasses the contraption.
8. Relog
9. Destroy the minecarts that appeared one by one. There should be approximately 25, with more or fewer depending on how long it took your client to "join" while the commands were running.

Observed Results: Minecarts summoned when contraption is in a ticking area and user relogs.

Expected Results: No minecarts summoned ever. While ticking areas should obviously tick independently of players existing, there should not be a "connection delay" in singleplayer during which the world is simulated.

Screenshots/Videos attached: To illustrate contraptions.

Notes:
Obviously summoning minecarts isn't the extent of the problem but I tried to keep the reproduction state simple for a bug with much more disastrous consequences.

Works As Intended

[Mod] tryashtar

2018-04-21, 09:13 PM

2018-05-31, 02:25 AM

2018-05-31, 02:25 AM

3

1

Future Release

-