Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/Presentation_HS17_merge/data/gui/scripts/TestDialogButttons.lua @ 11781

Last change on this file since 11781 was 11781, checked in by landauf, 6 years ago

eol-style native (no changes in code)

  • Property svn:eol-style set to native
File size: 668 bytes
Line 
1local P = createMenuSheet("dialogue")
2
3function P.onLoad()
4    --buttons are arranged in a 2x1 Matrix (list)
5    P:setButton(1, 1, {
6            ["button"] = winMgr:getWindow("orxonox/QuickGameTestButton"),
7            ["callback"]  = P.QuickGameTestButton_clicked
8    })
9
10    P:setButton(2, 1, {
11            ["button"] = winMgr:getWindow("orxonox/SingleplayerButton"),
12            ["callback"]  = P.SingleplayerButton_clicked
13    })
14
15end
16
17-- events for options
18function P.QuickGameTestButton_clicked(e)
19    hideAllMenuSheets()
20    orxonox.execute("startGame")
21end
22
23function P.SingleplayerButton_clicked(e)
24    showMenuSheet("SingleplayerMenu", true)
25end
26
27
28
29return P
30
Note: See TracBrowser for help on using the repository browser.