mirror of
https://github.com/edubart/otclient.git
synced 2025-10-16 04:24:54 +02:00
Refactoring and flexibility changes
* Split game module into game and game_interface * Move core_lib to corelib * Move miniwindow to corelib * Introduce init.lua script for initializing the client, giving much more flexibility * OTClient is no longer Application derived and is much simpler
This commit is contained in:
66
modules/game_interface/gameinterface.otui
Normal file
66
modules/game_interface/gameinterface.otui
Normal file
@@ -0,0 +1,66 @@
|
||||
GameSidePanel < UIMiniWindowContainer
|
||||
image-source: /images/sidepanel.png
|
||||
image-border: 4
|
||||
padding: 4
|
||||
|
||||
GameBottomPanel < Panel
|
||||
image-source: /images/bottompanel.png
|
||||
image-border: 4
|
||||
|
||||
GameMapPanel < UIGameMap
|
||||
padding: 4
|
||||
image-source: /images/mappanel.png
|
||||
image-border: 4
|
||||
|
||||
UIWidget
|
||||
id: gameRootPanel
|
||||
anchors.fill: parent
|
||||
anchors.top: topMenu.bottom
|
||||
|
||||
GameMapPanel
|
||||
id: gameMapPanel
|
||||
anchors.left: gameLeftPanel.right
|
||||
anchors.right: gameRightPanel.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: gameBottomPanel.top
|
||||
focusable: false
|
||||
|
||||
GameBottomPanel
|
||||
id: gameBottomPanel
|
||||
anchors.left: gameLeftPanel.right
|
||||
anchors.right: gameRightPanel.left
|
||||
anchors.top: bottomSplitter.top
|
||||
anchors.bottom: parent.bottom
|
||||
|
||||
GameSidePanel
|
||||
id: gameLeftPanel
|
||||
width: 190
|
||||
layout: verticalBox
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
focusable: false
|
||||
|
||||
GameSidePanel
|
||||
id: gameRightPanel
|
||||
layout: verticalBox
|
||||
width: 190
|
||||
anchors.right: parent.right
|
||||
anchors.top: parent.top
|
||||
anchors.bottom: parent.bottom
|
||||
focusable: false
|
||||
|
||||
Splitter
|
||||
id: bottomSplitter
|
||||
anchors.left: gameLeftPanel.right
|
||||
anchors.right: gameRightPanel.left
|
||||
anchors.bottom: parent.bottom
|
||||
relative-margin: bottom
|
||||
margin-bottom: 172
|
||||
@canUpdateMargin: function(self, newMargin) return math.max(math.min(newMargin, self:getParent():getHeight() - 300), 100) end
|
||||
@onGeometryChange: function(self) self:setMarginBottom(math.min(math.max(self:getParent():getHeight() - 300, 100), self:getMarginBottom())) end
|
||||
|
||||
UIWidget
|
||||
id: mouseGrabber
|
||||
focusable: false
|
||||
visible: false
|
Reference in New Issue
Block a user