[BUG] [EDITOR] Right-click does nothing when clicking on existing piece

Started by Nepster, March 13, 2016, 07:45:18 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Nepster

Usually one can add another piece to the editor by right-click on the level window. However if there is already some piece at the position one clicks at, the editor does nothing at all.
The expected behavior would be to pop up the Insert Terrain/Object/Steel Area selection, that already appears otherwise. At least the editor should do something and not just keep silent!

namida

It looks like EricLang deliberately coded the editor this way; I have no idea why, but there is an IF branch which checks if any pieces are under the cursor, then the check for left or right click is inside that. In the case that there ARE pieces, there's even explicitly an "if right click, exit the function" code.

I altered this so it checks right click before branching based on the presence / absence of pieces under the cursor (and if found, does nothing further), and it doesn't seem to cause any problems whatsoever. So, fixed for next update. :)
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)