[BUG][EDITOR] Error placing object after selecting lemming limited object

Started by Dullstar, August 20, 2019, 06:59:53 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Dullstar

To reproduce:

1) Select an entrance or an exit that has a lemming limit. Alternatively, assign a lemming limit to an entrance or an exit that does not have one.
2) Attempt to place a new/select an existing object for which a lemming limit is not supported.

The editor will then display two error messages one after the other. The display order is first "Set lemming limit, but first selected piece is not able to have this value!", then "Lemming limit set for incompatible object." You can click through the error messages and continue editing as if nothing happened. I didn't notice anything off about the new objects but I also didn't inspect the file output for any garbage data.

Note that this does not happen if you attempt to add terrain. If you attempt to add a new object that supports a limit, the object will still be created with the default value of 0 as expected (i.e. it doesn't appear to be trying to assign the selected object's lemming limit to the new object). Unselecting the entrance/exit first does not prevent the error from appearing, nor does selecting terrain before selecting the object. However, selecting an entrance/exit without a limit before selecting the next object will prevent the error.



What if there are multiple objects in the selection? I noticed some inconsistent behavior. If I have time later, I can try recording a video of this if it would help with investigating the bug. I spoiler tagged it because I'm not as confident in the accuracy of the description.
Spoiler
If you have a multiple object selection, it will not produce an error if you add new objects to an existing selection, or if the new selection contains multiple objects. If the selection contains at least one entrance/exit with no limit, it will not produce an error. If it contains only entrance/exit hatches with lemming limits, sometimes selecting a new object gives an error, and sometimes it doesn't.

namida

My projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)
Non-Lemmings: Commander Keen: Galaxy Reimagined (a Commander Keen fangame)