Ticket #4187: WinLosePatch_swords.diff

File WinLosePatch_swords.diff, 5.5 KB (added by elexis, 2 years ago)

Fixed so much broken whitespace.... Use tabs instead of spaces and don't have space after the last character please! Patch uses swords icons as suggested by niektb.

  • binaries/data/mods/public/gui/credits/texts/programming.json

     
    9494            {"nick": "infyquest", "name": "Vijay Kiran Kamuju"},
    9595            {"nick": "IronNerd", "name": "Matthew McMullan"},
    9696            {"nick": "Itms", "name": "Nicolas Auvray"},
    9797            {"nick": "Jaison", "name": "Marco tom Suden"},
    9898            {"nick": "jammus", "name": "James Scott"},
     99            {"nick": "javiergodas", "name": "Javier Godas Vieitez"},
    99100            {"nick": "Jgwman"},
    100101            {"nick": "JonBaer", "name": "Jon Baer"},
    101102            {"nick": "Josh", "name": "Joshua J. Bakita"},
    102103            {"nick": "jP_wanN", "name": "Jonas Platte"},
    103104            {"nick": "Jubalbarca", "name": "James Baillie"},
  • binaries/data/mods/public/gui/summary/summary.js

    const g_MaxHeadingTitle= 8; 
    33// const for filtering long collective headings
    44const g_LongHeadingWidth = 250;
    55
    66const g_PlayerBoxYSize = 40;
    77const g_PlayerBoxGap = 2;
    8 const g_PlayerBoxAlpha = " 32";
     8const g_PlayerBoxAlpha = " 50";
    99const g_PlayerColorBoxAlpha = " 255";
    1010const g_TeamsBoxYStart = 40;
    1111
    1212// Colors used for units and buildings
    1313const g_TrainedColor = '[color="201 255 200"]';
    function updatePanelData(panelInfo) 
    8989        else
    9090            playerBoxesCounts[playerState.team+1] += 1;
    9191
    9292        let positionObject = playerBoxesCounts[playerState.team+1] - 1;
    9393        let rowPlayer = "playerBox[" + positionObject + "]";
     94        let playerOutcome = "playerOutcome[" + positionObject + "]";
    9495        let playerNameColumn = "playerName[" + positionObject + "]";
    95         let playerColorBoxColumn = "playerColorBox[" + positionObject + "]";
    9696        let playerCivicBoxColumn = "civIcon[" + positionObject + "]";
    9797        let playerCounterValue = "valueData[" + positionObject + "]";
    9898
    9999        if (playerState.team != -1)
    100100        {
    101101            rowPlayer = "playerBoxt[" + playerState.team + "][" + positionObject + "]";
     102            playerOutcome = "playerOutcomet[" + playerState.team + "][" + positionObject + "]";
    102103            playerNameColumn = "playerNamet[" + playerState.team + "][" + positionObject + "]";
    103             playerColorBoxColumn = "playerColorBoxt[" + playerState.team + "][" + positionObject + "]";
    104104            playerCivicBoxColumn = "civIcont[" + playerState.team + "][" + positionObject + "]";
    105105            playerCounterValue = "valueDataTeam[" + playerState.team + "][" + positionObject + "]";
    106106        }
    107107
    108108        let colorString = "color: " +
    function updatePanelData(panelInfo) 
    116116
    117117        let boxSize = rowPlayerObject.size;
    118118        boxSize.right = rowPlayerObjectWidth;
    119119        rowPlayerObject.size = boxSize;
    120120
    121         let playerColorBox = Engine.GetGUIObjectByName(playerColorBoxColumn);
    122         playerColorBox.sprite = colorString + g_PlayerColorBoxAlpha;
     121        let outcome = Engine.GetGUIObjectByName(playerOutcome);
     122        if (playerState.state == "won")
     123        {
     124            outcome.sprite = "stretched:session/icons/stances/violent.png";
     125            outcome.tooltip = translate("Victory");
     126        }
     127        else if (playerState.state == "defeated")
     128        {
     129            outcome.sprite = "stretched:session/icons/stances/passive.png";
     130            outcome.tooltip = translate("Defeated");
     131        }
    123132
    124133        Engine.GetGUIObjectByName(playerNameColumn).caption = g_GameData.sim.playerStates[i+1].name;
    125134
    126135        let civIcon = Engine.GetGUIObjectByName(playerCivicBoxColumn);
    127136        civIcon.sprite = "stretched:" + g_CivData[playerState.civ].Emblem;
  • binaries/data/mods/public/gui/summary/summary.xml

     
    117117                <object type="image" name="teamBoxt[i]" size="0 65 100% 100%-50" hidden="true">
    118118                    <object type="text" name="teamNameHeadingt[i]" size="15 5 100% 100%" style="ModernLeftTabLabelText"/>
    119119                    <object size="0 30 100% 100%">
    120120                        <repeat count="8" var="n">
    121121                            <object type="image" name="playerBoxt[i][n]" size="10 0 10 30" hidden="true">
    122                                 <object type="image" sprite="ForegroundBox" size="10 9 34 33">
    123                                     <object name="playerColorBoxt[i][n]" type="image" size="2 2 22 22"/>
    124                                 </object>
     122                                <object name="playerOutcomet[i][n]" type="image" size="4 8 30 35"/>
    125123                                <object name="playerNamet[i][n]" type="text" size="40 2 208 100%" style="ModernLeftLabelText"/>
    126124                                <object name="civIcont[i][n]" type="image" size="208 5 240 37" />
    127125                                <repeat var="x" count="8">
    128126                                    <object name="valueDataTeam[i][n][x]" type="text" style="ModernTabLabelText">
    129127                                    </object>
     
    140138            </repeat>
    141139
    142140            <object type="image" name="noTeamsBox" size="0 65 100% 100%-50" hidden="true">
    143141                <repeat count="8">
    144142                    <object type="image" name="playerBox[n]" size="10 0 10 30" hidden="true">
    145                         <object type="image" sprite="ForegroundBox" size="10 9 34 33">
    146                             <object name="playerColorBox[n]" type="image" size="2 2 22 22"/>
    147                         </object>
     143                        <object name="playerOutcome[n]" type="image" size="4 8 30 35"/>
    148144                        <object name="playerName[n]" type="text" size="40 2 208 100%" style="ModernLeftLabelText"/>
    149145                        <object name="civIcon[n]" type="image" size="208 5 240 37"/>
    150146                        <repeat var="x" count="8">
    151147                            <object name="valueData[n][x]" type="text" style="ModernTabLabelText">
    152148                            </object>