When using selection_box to produce an asymmetric selection area, the actual selection box is different than the entered values specifically when the boundaries are not on tile edges. In these cases, the highlight box accuratly reflects the mouse-selectable area, so this is a different bug than viewtopic.php?f=7&t=119778
Example:
With selection_box = {{-1.5, -0.5}, {-0.5, 0.5}} (and selection_box_shift = 0,0), the selection rectangle is shifted by 1.0 tiles as expected. (East orientation shown)
I then tried to make the box a little smaller than a full tile. I set selection_box = {{-1.35, -0.65}, {-0.35, 0.35}} (selection_box_shift is still 0,0). The total width of the box should be 0.7x0.7 tiles and the center should still be offset by 1.0. But the result I get is the following:
The box is still 1.0x1.0 tiles wide, and the center has been shifted by (0.15, 0.15). This happens in all four cardinal directions (the diagonals have other issues as I reported).
[2.0.14] Rail signal selection_box shifts incorrectly when not on tile edges
Re: [2.0.14] Rail signal selection_box shifts incorrectly when not on tile edges
Thanks for the report however I'm not seeing any bug here. Your bounding box definition of matches perfectly what you're showing: a 1x1 box moved left 1 tile and up 15% of a tile (and then rotated 90 degrees).
Code: Select all
{{-1.35, -0.65}, {-0.35, 0.35}}
If you want to get ahold of me I'm almost always on Discord.
Re: [2.0.14] Rail signal selection_box shifts incorrectly when not on tile edges
Thank you for pointing out my mistake. Somehow I had convinced myself that the box definition was {{x1, x2}, {y1, y2}} when it is actually {{x1, y1}, {x2, y2}}. I will fix this and try again. Cheers!
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk