- Timestamp:
- Feb 23, 2018, 12:20:35 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/cegui0.8_ogre1.9/data/gui/scripts/MultiplayerMenu.lua
r11795 r11799 12 12 --button are arranged in a 3x2 matrix, Join and Host buttons are in the upper left and middle, the back button in the lower right of the table 13 13 P:setButton(1, 1, { 14 ["button"] = winMgr:getWindow("orxonox/MultiplayerJoinButton"),14 ["button"] = P.window:getChild("MultiplayerJoinButton"), 15 15 ["callback"] = P.MultiplayerJoinButton_clicked 16 16 }) 17 17 18 18 P:setButton(1, 2, { 19 ["button"] = winMgr:getWindow("orxonox/MultiplayerHostButton"),19 ["button"] = P.window:getChild("MultiplayerHostButton"), 20 20 ["callback"] = P.MultiplayerHostButton_clicked 21 21 }) 22 22 23 23 P:setButton(2, 3, { 24 ["button"] = winMgr:getWindow("orxonox/MultiplayerBackButton"),24 ["button"] = P.window:getChild("MultiplayerBackButton"), 25 25 ["callback"] = P.MultiplayerBackButton_clicked 26 26 }) … … 31 31 32 32 if P.joinMode == 1 then 33 local window = winMgr:getWindow("orxonox/MultiplayerLanButton")33 local window = P.window:getChild("MultiplayerWindow/MultiplayerLanButton") 34 34 local button = tolua.cast(window,"CEGUI::RadioButton") 35 35 button:setSelected(true) 36 36 end 37 37 if P.joinMode == 2 then 38 local window = winMgr:getWindow("orxonox/MultiplayerInternetButton")38 local window = P.window:getChild("MultiplayerWindow/MultiplayerInternetButton") 39 39 local button = tolua.cast(window,"CEGUI::RadioButton") 40 40 button:setSelected(true) … … 66 66 67 67 function P.MultiplayerJoinButton_clicked(e) 68 local choice = winMgr:getWindow("orxonox/MultiplayerListbox"):getFirstSelectedItem()68 local choice = P.window:getChild("MultiplayerWindow/MultiplayerListbox"):getFirstSelectedItem() 69 69 local destination = nil 70 70 if choice then … … 85 85 -- LAN Discovery 86 86 if P.joinMode == 1 then 87 local listbox = winMgr:getWindow("orxonox/MultiplayerListbox")87 local listbox = P.window:getChild("MultiplayerWindow/MultiplayerListbox") 88 88 CEGUI.toListbox(listbox):resetList() 89 89 local discovery = orxonox.LANDiscovery:getInstance() … … 120 120 -- WAN Discovery 121 121 elseif P.joinMode == 2 then 122 local listbox = winMgr:getWindow("orxonox/MultiplayerListbox")122 local listbox = P.window:getChild("MultiplayerWindow/MultiplayerListbox") 123 123 CEGUI.toListbox(listbox):resetList() 124 124 local discovery = orxonox.WANDiscovery()
Note: See TracChangeset
for help on using the changeset viewer.