Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 1, 2015, 1:05:54 PM (9 years ago)
Author:
fvultier
Message:

HUD improved. Corrected text rescaling. Renamed reload to shieldRecharge in Pawn.cc, … to avoid confusion with the weapon system.

Location:
code/branches/fabienHS15/data/gui
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/fabienHS15/data/gui/layouts/InGameMenu.layout

    r7801 r10739  
    99            <Property Name="Text" Value="Return to Game" />
    1010            <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
    11             <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.3625,0},{0.6,0},{0.4125,0}}" />
     11            <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.2875,0},{0.6,0},{0.3375,0}}" />
    1212            <Property Name="Alpha" Value="0.9" />
    1313            <Event Name="Clicked" Function="InGameMenu.button_return_clicked"/>
    1414        </Window>
     15        <Window Type="MenuWidgets/Button" Name="orxonox/InGameMenu_ReloadLevelButton" >
     16            <Property Name="Text" Value="Reload level" />
     17            <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
     18            <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.3625,0},{0.6,0},{0.4125,0}}" />
     19            <Property Name="Alpha" Value="0.9" />
     20            <Event Name="Clicked" Function="InGameMenu.button_reloadLevel_clicked"/>
     21        </Window>       
    1522        <Window Type="MenuWidgets/Button" Name="orxonox/InGameMenu_MainMenuButton" >
    1623            <Property Name="Text" Value="Main Menu" />
    1724            <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
    18             <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.4625,0},{0.6,0},{0.5125,0}}" />
     25            <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.4375,0},{0.6,0},{0.4875,0}}" />
    1926            <Property Name="Alpha" Value="0.9" />
    2027            <Event Name="Clicked" Function="InGameMenu.button_mainmenu_clicked"/>
     
    2330            <Property Name="Text" Value="Settings" />
    2431            <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
    25             <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.5625,0},{0.6,0},{0.6125,0}}" />
     32            <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.5125,0},{0.6,0},{0.5625,0}}" />
    2633            <Property Name="Alpha" Value="0.9" />
    2734            <Event Name="Clicked" Function="InGameMenu.button_settings_clicked"/>
     
    3037            <Property Name="Text" Value="Quit" />
    3138            <Property Name="UnifiedMaxSize" Value="{{1,0},{1,0}}" />
    32             <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.6625,0},{0.6,0},{0.7125,0}}" />
     39            <Property Name="UnifiedAreaRect" Value="{{0.4,0},{0.5875,0},{0.6,0},{0.6375,0}}" />
    3340            <Property Name="Alpha" Value="0.9" />
    3441            <Event Name="Clicked" Function="InGameMenu.button_quit_clicked"/>
  • code/branches/fabienHS15/data/gui/scripts/InGameMenu.lua

    r9016 r10739  
    77    P.multiplayerMode = "startClient"
    88
    9     --button are arranged in a 4x1 matrix, the left lower item is nil
     9    --button are arranged in a 5x1 matrix, the left lower item is nil
    1010    P:setButton(1, 1, {
    1111            ["button"] = winMgr:getWindow("orxonox/InGameMenu_ReturnButton"),
     
    1414
    1515    P:setButton(2, 1, {
     16            ["button"] = winMgr:getWindow("orxonox/InGameMenu_ReloadLevelButton"),
     17            ["callback"]  = P.button_reloadLevel_clicked
     18    })
     19
     20    P:setButton(3, 1, {
    1621            ["button"] = winMgr:getWindow("orxonox/InGameMenu_MainMenuButton"),
    1722            ["callback"]  = P.button_mainmenu_clicked
    1823    })
    1924
    20     P:setButton(3, 1, {
     25    P:setButton(4, 1, {
    2126            ["button"] = winMgr:getWindow("orxonox/InGameMenu_SettingsButton"),
    2227            ["callback"]  = P.button_settings_clicked
    2328    })
    2429
    25     P:setButton(4, 1, {
     30    P:setButton(5, 1, {
    2631            ["button"] = winMgr:getWindow("orxonox/InGameMenu_QuitButton"),
    2732            ["callback"]  = P.button_quit_clicked
     
    5459end
    5560
     61function P.button_reloadLevel_clicked(e)
     62    hideMenuSheet("InGameMenu")
     63    orxonox.execute("reloadLevel")
     64end
     65
    5666function P.button_return_clicked(e)
    5767    hideMenuSheet("InGameMenu")
Note: See TracChangeset for help on using the changeset viewer.