#3805 closed enhancement (fixed)
[PATCH] Gamesetup - reset-civilizations button
Reported by: | elexis | Owned by: | elexis |
---|---|---|---|
Priority: | Nice to Have | Milestone: | Alpha 21 |
Component: | UI & Simulation | Keywords: | patch |
Cc: | Patch: |
Description
With persist-matchsettings (which are enabled by default), the chosen civilizations of the previous game are restored on init.
When players join, they immediately pick cvilizations. This leads to a situation where the host can't be sure which cvilizations were restored from the matchsettings, while some were chosen specifically by players.
Hence a good host should reset the civs when not rehosting a match. (Disabling the persist-matchsettings is not preferable, since the options independent from the player-assignments typcially stay the same.)
Therefore, it would be nice to have a button "Reset civilizations" to the default (currently "random").
The button could be placed left besides the "More Options" button. (If more buttons are added later, they can be placed into a separate row).
Attachments (7)
Change History (27)
by , 8 years ago
Attachment: | resetcivsbutton.patch added |
---|
comment:1 by , 8 years ago
Keywords: | review patch added |
---|---|
Milestone: | Backlog → Alpha 21 |
Summary: | Gamesetup - reset-civilizations button → [PATCH] Gamesetup - reset-civilizations button |
comment:2 by , 8 years ago
Keywords: | art added; review removed |
---|
comment:3 by , 8 years ago
Where you can use/place this icon? I can use the same modificated by the screen where you want reset/revert...
comment:5 by , 8 years ago
The icon will be over a button right? Similar to gear for Ai setup?
My idea is do an white or kind of golden version . Need be same size as info icon right?
comment:6 by , 8 years ago
Yes, the icon would be used as a button, like the civinfo thing and would be displayed with the same size. However having icons of bigger sizes would be better for high resolution displays and also means that someone can reuse the icon somewhere else. Just make sure that it will look ok when scaled to the size of the civ-info icon.
comment:7 by , 8 years ago
ok i take the example in the page http://www.endlessicons.com/free-icons/reset-icon/ I try to give the same feeling like info.png ,I do two version 16x16 and 256x256 I preserved the svg file for me and here is.
by , 8 years ago
by , 8 years ago
Attachment: | reset256x256.png added |
---|
by , 8 years ago
Attachment: | resetcivsbutton_v2.patch added |
---|
comment:8 by , 8 years ago
If I may add a comment: I think it would be more logical to mirror the icon horizontally since it now associates with the 'redo' function in MS Office. (While an association with the undo function might be more fitting). Nice icon nonetheless!
comment:10 by , 8 years ago
Keywords: | simple art removed |
---|
Thanks for the patch Sandarac!
Notice there were two missing semicolons in JS and XML, some trailing whitespace in the XML and JS and using the variable notScenario
few lines below made the code a bit shorter and more consistent.
Thanks to Lionkanzen for providing an icon quickly which was essential to finish the ticket! I will ask our artists if they can commit the 256px version to art_source
.
by , 8 years ago
Attachment: | reset256x256.2.png added |
---|
Horizontally mirrored version (as used in the commit, besides the higher res)
comment:11 by , 8 years ago
Keywords: | review added |
---|---|
Resolution: | fixed |
Status: | closed → reopened |
by , 8 years ago
Attachment: | resetcivsbutton_v3.patch added |
---|
Right side of button is not selectable. This fixes that.
comment:13 by , 8 years ago
Keywords: | review removed |
---|---|
Resolution: | → fixed |
Status: | reopened → closed |
by , 8 years ago
Attachment: | reset256x256 - 3.png added |
---|
Code:
updateGUIObjects
=> I'm pretty sure that this won't be enough for multiplayer, you will most certainly have to callupdateGameAttributes
instead (if you're not on windows you can test by starting 0AD twice, hosting with one instance and joining with the other)Thanks writing patches for 0 A.D.!