1
0
forked from 0ad/0ad

For reasons I cannot fathom at this late hour, a section of objects in 2_mainmenu.xml causes the coordinates of the session GUI to be screwed up. After a couple of hours of lack of success, commented it out so it'll work until tomorrow. Gotta get some sleep before work.

This was SVN commit r1498.
This commit is contained in:
Acumen 2004-12-13 23:15:11 +00:00
parent 94ee723981
commit b04b3447c8
5 changed files with 19 additions and 28 deletions

View File

@ -101,11 +101,12 @@
<object type="image" name="pregame_subwindow_bkg" sprite="tooltip-background" size="0 0 100% 100%" z="105" hidden="true"/>
<object type="button" name="pregame_ip_host" sprite="0ad_window" z="106" hidden="true">Mary had a little lamb; her fleece was white as snow (the lamb's fleece; that is. Not Mary's. It'd be pretty silly if Mary had a fleece. Though I guess it's possible. I mean in this modern avant-garde world of ours, who am I to say that Mary doesn't come with a fleece at no additional cost? Ah, forget it.)
<object type="button" name="pregame_ip_host" sprite="0ad_window" z="106" hidden="true">
<!-- NOT WORKING
<action on="Load"><![CDATA[
getGUIObjectByName("pregame_ip_host").caption = "Mary had a little lamb; her fleece was white as snow (the lamb's fleece; that is. Not Mary's. It'd be pretty silly if Mary had a fleece. Though I guess it's possible. I mean in this modern avant-garde world of ours, who am I to say that Mary doesn't come with a fleece at no additional cost? Ah, forget it.)";
setSizeCoord("pregame_ip_host", crd_pregame_iphost_bkg_x, crd_pregame_iphost_bkg_y, crd_pregame_iphost_bkg_x+crd_pregame_iphost_bkg_width, crd_pregame_iphost_bkg_y+crd_pregame_iphost_bkg_height, mid_screen, mid_screen, mid_screen, mid_screen);
]]></action>
<object type="button" name="pregame_ip_host_exit_button" sprite="exit_sprite" sprite-over="exit_sprite-over">
<action on="Load"><![CDATA[
setSizeCoord("pregame_ip_host_exit_button", crd_pregame_iphost_exit_button_x, crd_pregame_iphost_exit_button_y, crd_pregame_iphost_exit_button_x+crd_pregame_iphost_exit_button_width, crd_pregame_iphost_exit_button_y+crd_pregame_iphost_exit_button_height, mid_screen, mid_screen, mid_screen, mid_screen);
@ -116,11 +117,12 @@
]]></action>
</object>
<object type="button" name="pregame_ip_host_titlebar" sprite="0ad_window_title" size="15%+54 4 85%-54 32" font="prospero18" z="165" text-align="center" text-valign="center">Direct IP Connect
<object type="button" name="pregame_ip_host_titlebar" sprite="0ad_window_title" font="prospero18" z="165" text-align="center" text-valign="center">Direct IP Connect
<action on="Load"><![CDATA[
setSizeCoord("pregame_ip_host_titlebar", crd_pregame_iphost_titlebar_x, crd_pregame_iphost_titlebar_y, crd_pregame_iphost_titlebar_x+crd_pregame_iphost_titlebar_width, crd_pregame_iphost_titlebar_y+crd_pregame_iphost_titlebar_height, mid_screen, mid_screen, mid_screen, mid_screen);
]]></action>
</object>
NOT WORKING -->
</object>
</object>

View File

@ -33,35 +33,16 @@
<object type="image" name="loading_screen_titlebar-left" size="15% 0 15%+64 32" sprite="message_box-titlebar-left" absolute="false" z="164" hidden="false"/>
<object type="image" name="loading_screen_titlebar-middle" size="15%+64 0 85%-64 32" sprite="message_box-titlebar-middle" absolute="false" z="164" hidden="false"/>
<object type="image" name="loading_screen_titlebar-right" size="85%-64 0 85% 32" sprite="message_box-titlebar-right" absolute="false" z="164" hidden="false"/>
<object type="button" name="loading_screen_titlebar-text" size="15%+54 4 85%-54 32" absolute="false" font="prospero18" z="165" text-align="center" text-valign="center" hidden="false">
<action on="Load"><![CDATA[
this.caption = "Loading Scenario ..."
]]></action>
</object>
<object type="button" name="loading_screen_titlebar-text" size="15%+54 4 85%-54 32" absolute="false" font="prospero18" z="165" text-align="center" text-valign="center" hidden="false"/>
<!-- progress bar -->
<object type="button" name="loading_screen_progress_bar_text" size="0%+32 100%-205 100%-32 100%-185" font="tahoma14" textcolor="0 0 0" text-align="center" text-valign="center" z="165" hidden="false">
<action on="Load"><![CDATA[
this.caption = "... Reticulating splines ...";
]]></action>
</object>
<object type="progressbar" name="loading_screen_progress_bar" style="blue_bar_outlined" size="0%+32 100%-185 100%-32 100%-160" z="165" hidden="false">
<action on="Load"><![CDATA[
this.caption = 80;
]]></action>
</object>
<object type="button" name="loading_screen_progress_bar_text" size="0%+32 100%-205 100%-32 100%-185" font="tahoma14" textcolor="0 0 0" text-align="center" text-valign="center" z="165" hidden="false"/>
<object type="progressbar" name="loading_screen_progress_bar" style="blue_bar_outlined" size="0%+32 100%-185 100%-32 100%-160" z="165" hidden="false"/>
<!-- text -->
<object type="text" name="loading_screen_text" size="32 40 100%-32 100%-100" absolute="false" font="prospero18" z="165" hidden="false">
<action on="Load"><![CDATA[
this.caption = "LOADING ...\nPlease wait ...\n(Yes, we know the progress bar doesn't do diddly squat right now)\nJust keep waiting ...\nIt'll get there ...\nAlmost done ...\nTrust me!"
]]></action>
</object>
<object type="button" name="loading_screen_tip" sprite="only-white-border" size="32 100%-150 100%-32 100%-32" font="tahoma18" text-valign="center" textcolor="0 0 0" z="165" hidden="false">
<action on="Load"><![CDATA[
this.caption = "Wise man once say ...\nHe who thinks slow, he act in haste, be rash and quick and foolish. But he that thinks too much, acts too slowly. The stupid always win, Commandersan. Remember that. You are tiny grasshopper."
]]></action>
</object>
<object type="text" name="loading_screen_text" size="32 40 100%-32 100%-100" absolute="false" font="prospero18" z="165" hidden="false"/>
<object type="button" name="loading_screen_tip" sprite="only-white-border" size="32 100%-150 100%-32 100%-32" font="tahoma18" text-valign="center" textcolor="0 0 0" z="165" hidden="false"/>
</object>
</objects>

View File

@ -9,6 +9,7 @@
-->
<objects>
<object type="empty" name="session_gui" hotkey="flipgui.toggle" size="0 0 100% 100%" z="1" hidden="true">
<action on="Load"><![CDATA[
setInterval( getObjectInfo, 1, 1000 );

View File

@ -20,6 +20,12 @@ function startLoadingScreen()
GUIObjectUnhide("loading_screen");
console.write("Loading " + g_GameAttributes.mapFile + " (" + g_GameAttributes.numPlayers + " players) ...");
getGUIObjectByName("loading_screen_titlebar-text").caption = "Loading Scenario ...";
getGUIObjectByName("loading_screen_progress_bar_text").caption = "... Reticulating splines ...";
getGUIObjectByName("loading_screen_progress_bar").caption = 80;
getGUIObjectByName("loading_screen_text").caption = "LOADING " + g_GameAttributes.mapFile + " ...\nPlease wait ...\n(Yes, we know the progress bar doesn't do diddly squat right now)\nJust keep waiting ...\nIt'll get there ...\nAlmost done ...\nTrust me!";
getGUIObjectByName("loading_screen_tip").caption = "Wise man once say ...\nHe who thinks slow, he act in haste, be rash and quick and foolish. But he that thinks too much, acts too slowly. The stupid always win, Commandersan. Remember that. You are tiny grasshopper.";
// Begin game session.
setTimeout( loadSession(), 0 );
}

View File

@ -181,4 +181,5 @@ function FlipGUI(NewGUIType)
}
writeConsole("GUI flipped to " + GUIType + ".");
}