Opened 20 months ago
Last modified 20 months ago
#6692 new defect
Open the correct structure tree when you click on the emblem — at Version 3
Reported by: | Langbart | Owned by: | |
---|---|---|---|
Priority: | Should Have | Milestone: | Alpha 27 |
Component: | UI – In-game | Keywords: | simple |
Cc: | Patch: |
Description (last modified by )
reported by RangerK
in the forum:
Alpha26 feedback and suggested changes (5/Jan/23)
When watching a multiplayer replay, when you click on a player's civilization emblem, it opens the structure tree of the previously opened civilization.
to reproduce
- watch a multiplayer replay
- switch to observation mode of a player playing, say the the Mauryas
- In the top-center, you'll see their civilization emblem and you can click it to open their structure tree
- Close the structure tree and switch to observation mode of a player playing the Roman
- Click their civilization emblem. It'll open the Mauryas structure tree instead of the Roman one.
expected behavior
- if you click on the emblem, the correct structure tree should be displayed
answered by s0600204
bisect
Intentional (by design of the session UI, not the Structure Tree), and dates back to this Revision - Phab:D846 (29/Aug/17)
Easily changed by altering this line of code.
gui/session/top_panel/CivIcon.js$40
Line | |
---|---|
35 | Engine.PushGuiPage( |
36 | page, |
37 | { |
38 | // If an Observer triggers `openPage()` via hotkey, g_ViewedPlayer could be -1 or 0 |
39 | // (depending on whether they're "viewing" no-one or gaia respectively) |
40 | "civ": this.dialogSelection.civ || g_Players[Math.max(g_ViewedPlayer, 1)].civ, |
41 | |
42 | // TODO add info about researched techs and unlocked entities |
43 | }, |
44 | this.storePageSelection.bind(this)); |
45 | } |
possible solution (not from s0600204)
-
binaries/data/mods/public/gui/session/top_panel/CivIcon.js
a b class CivIcon 37 37 { 38 38 // If an Observer triggers `openPage()` via hotkey, g_ViewedPlayer could be -1 or 0 39 39 // (depending on whether they're "viewing" no-one or gaia respectively) 40 "civ": this.dialogSelection.civ || g_Players[Math.max(g_ViewedPlayer, 1)].civ,40 "civ": g_ViewedPlayer > 0 ? g_Players[g_ViewedPlayer].civ : this.dialogSelection.civ || g_Players[Math.max(g_ViewedPlayer, 1)].civ, 41 41 42 42 // TODO add info about researched techs and unlocked entities 43 43 },
Change History (4)
by , 20 months ago
Attachment: | struct.png added |
---|
comment:1 by , 20 months ago
Description: | modified (diff) |
---|
comment:2 by , 20 months ago
Description: | modified (diff) |
---|
Mind that the tooltip should not show "Last opened will be reopened on click." then.
Set date and title of the link to the forum