Ticket #4031: continue_mp_v2.patch
File continue_mp_v2.patch, 3.1 KB (added by , 8 years ago) |
---|
-
binaries/data/mods/public/gui/gamesetup/gamesetup_mp.js
54 54 Engine.PopGuiPage(); 55 55 } 56 56 57 function confirmSetup() 58 { 59 if (Engine.GetGUIObjectByName("pageHost").hidden) 60 { 61 var joinPlayerName = Engine.GetGUIObjectByName("joinPlayerName").caption; 62 var joinServer = Engine.GetGUIObjectByName("joinServer").caption; 63 if (startJoin(joinPlayerName, joinServer)) 64 switchSetupPage("pageJoin", "pageConnecting"); 65 } 66 else 67 { 68 var hostPlayerName = Engine.GetGUIObjectByName("hostPlayerName").caption; 69 var hostServerName = Engine.GetGUIObjectByName("hostServerName").caption; 70 if (startHost(hostPlayerName, hostServerName)) 71 switchSetupPage("pageHost", "pageConnecting"); 72 } 73 } 74 57 75 function startConnectionStatus(type) 58 76 { 59 77 g_GameType = type; -
binaries/data/mods/public/gui/gamesetup/gamesetup_mp.xml
45 45 this.caption = Engine.ConfigDB_GetValue("user", "multiplayerserver"); 46 46 </action> 47 47 </object> 48 49 <object hotkey="confirm" type="button" size="50%+5 100%-45 100%-18 100%-17" style="ModernButtonRed">50 <translatableAttribute id="caption">Continue</translatableAttribute>51 <action on="Press">52 var joinPlayerName = Engine.GetGUIObjectByName("joinPlayerName").caption;53 var joinServer = Engine.GetGUIObjectByName("joinServer").caption;54 if (startJoin(joinPlayerName, joinServer))55 switchSetupPage("pageJoin", "pageConnecting");56 </action>57 </object>58 48 </object> 59 49 60 50 <object name="pageHost" size="0 32 100% 100%" hidden="true"> … … 87 77 </action> 88 78 </object> 89 79 </object> 90 91 <object type="button" size="50%+5 100%-45 100%-18 100%-17" style="ModernButtonRed">92 <translatableAttribute id="caption">Continue</translatableAttribute>93 <action on="Press">94 var hostPlayerName = Engine.GetGUIObjectByName("hostPlayerName").caption;95 var hostServerName = Engine.GetGUIObjectByName("hostServerName").caption;96 if (startHost(hostPlayerName, hostServerName))97 switchSetupPage("pageHost", "pageConnecting");98 </action>99 </object>100 80 </object> 101 81 102 82 <object name="hostFeedback" type="text" style="ModernLabelText" size="50 100%-90 100%-50 100%-50" textcolor="red" /> 103 83 84 <object hotkey="confirm" type="button" size="50%+5 100%-45 100%-18 100%-17" style="ModernButtonRed"> 85 <translatableAttribute id="caption">Continue</translatableAttribute> 86 <action on="Press"> 87 confirmSetup(); 88 </action> 89 </object> 90 104 91 <object type="button" style="ModernButtonRed" size="18 100%-45 50%-5 100%-17" hotkey="cancel"> 105 92 <translatableAttribute id="caption">Cancel</translatableAttribute> 106 93 <action on="Press">cancelSetup();</action>