News:

SimuTranslator
Make Simutrans speak your language.

Remove Way - No preview when dragging

Started by captain crunch, January 15, 2018, 12:48:01 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

captain crunch

When dragging the tool to remove ways it used to show you which way would get removed by displaying the remove icon (X) along the way. Now it is not shown, turning this action into a game of chance. This behaviour probably changed around svn commit r8336.

Leartin

That "Remove Icon" is just a copy of the cursor. I don't see the cursor on your second screen - could it be that there simply is no cursor defined in the pakset, hence no graphic for the game to show?

EDIT: It's not pakset specific, the cursor is gone for other paksets as well.

Dwachs

Which version works? Which does not? Cannot think of any change that caused this.
Parsley, sage, rosemary, and maggikraut.

Leartin

Since it affects the cursors of multiple tools (place label, plant tree etc.) perhaps it's an oversight in userfriendlys patch which operates in that area of the code?

userfriendly

Leartin is correct. The version after https://github.com/aburch/simutrans/commit/85deb996b3170453c511d1a834e1379c711a471d has the bug and the version right before my changes does not have the bug :(

I'll look into this, sometime this week, since it doesn't seem to be a game breaking bug.
Just be good to each other.

ROCAMBOLER529

Maybe the road cannot be connnected in totally... In the irregulars terrains its very difficult to see if the road is connected or its has an end point!!
The Argentian (Argentina Empire)

Dwachs

@userfriendly: Solution should be simple: first copy data the old way (before your patch), then call the method of your patch

*addtool = *(general_tool[toolnr]); // this line was removed by the commit, bringing it back could help?
set_defaults_general_tool(addtool, param_str);

Found no time to test whether this would work.
Parsley, sage, rosemary, and maggikraut.

userfriendly

@Dwachs Thanks - I can confirm that fixes the issue! Reverted the line on master and the bug is gone.
I do want to know why that broke the remove ways icons. Any ideas?
Just be good to each other.

Dwachs

This missing line copies the data that is now missing: set_defaults_general_tools does only copy data for tools are related to some object, which is not the case for remove ways.
Parsley, sage, rosemary, and maggikraut.

Dwachs

This is now in r8371. Thanks for testing!
Parsley, sage, rosemary, and maggikraut.