Editor Player Menu doesn't update tool overlay when player is removed
Bug #1426276 reported by
GunChleoc
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
widelands |
Fix Released
|
Low
|
Unassigned |
Bug Description
When defining the players' starting positions in the editor, when the last player was selected and then removed, the tool still shows the color of the now removed player.
Related branches
lp:~majcherlk/widelands/bug-1426276
- GunChleoc: Approve
-
Diff: 29 lines (+6/-2)1 file modifiedsrc/editor/ui_menus/editor_player_menu.cc (+6/-2)
Changed in widelands: | |
status: | Confirmed → Fix Committed |
milestone: | none → build19-rc1 |
Changed in widelands: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Confirmed in r7438.
When decreasing the number of players available, the color of the tool doesn't change. However clicking on the ground will place the start position for player #1 regardless of how many were available or which one was selected. I guess this is a fallback because a game would need to include at least one player.
Note though, if you reduce the amount of players but don't click on the map to place (the first) player location, re-increasing the number of players will activate the color again and you will be able to place that color as if it had always existed. Some of the suggestions below would break this behaviour.
What would be the expected/least surprising behaviour:
1. Explicitly switch color and player which will be placed to the first one. As happens today, but the selected player is always reverted to the first one, even if the number of players is increased again in the future.
2. Explicitly switch to the closest/highest available player (however to properly describe it). For instance, if you have four players and player4 selected, if you then reduce the amount of players to three, you now have player3 selected. Player3 remains selected if you increase the amount of players again.
3. Something completely different?