mirror of
https://github.com/edubart/otclient.git
synced 2025-05-01 18:19:20 +02:00

* Added new left and right game button panels. * Relocated main game toggle buttons to the right side of the screen to make it easier to toggle miniwindows. * Added table.empty(t) function to table lib. * Renamed module game_healthbar to game_healthinfo. * Combat controls now save per character (e.g. Fight mode, chase mode, safe fight mode) * Last channels open now save per character. * Fixed typo in containers.lua. * Added logout prompting window message when you logout via the logout button. * Added exit promting window message when you attempt to exit the client. * Repositioned some minimap buttons. * Fixed so when creatures health percent is < 1 it will not draw the creature information. Known Issues: * If you move a container widget into the map rect if you move an item onto itself it will allow this to execute still dropping the item on the ground. * The server is calling to open channels after onGameStart is executed causing it to focus the last tab opened. Fix: Don't save channels to the settings that are opened by the server.
98 lines
2.0 KiB
Plaintext
98 lines
2.0 KiB
Plaintext
TopButton < UIButton
|
|
size: 26 26
|
|
image-source: images/top_button.png
|
|
image-clip: 0 0 26 26
|
|
image-border: 3
|
|
image-color: #ffffffff
|
|
icon-color: #ffffffff
|
|
|
|
$hover !disabled:
|
|
image-color: #ffffff99
|
|
image-clip: 26 0 26 26
|
|
|
|
$pressed:
|
|
image-clip: 52 0 26 26
|
|
|
|
$disabled:
|
|
image-color: #ffffff44
|
|
icon-color: #ffffff44
|
|
|
|
TopToggleButton < UIButton
|
|
size: 26 26
|
|
image-source: images/top_game_button.png
|
|
image-clip: 26 0 26 26
|
|
image-color: #ffffff22
|
|
image-border: 3
|
|
icon-color: #ffffffff
|
|
|
|
$on:
|
|
image-clip: 0 0 26 26
|
|
image-color: #ffffffff
|
|
icon-color: #ffffffff
|
|
|
|
TopMenuButtonsPanel < Panel
|
|
layout:
|
|
type: horizontalBox
|
|
spacing: 4
|
|
fit-children: true
|
|
padding: 6 4
|
|
|
|
TopPanel < Panel
|
|
height: 36
|
|
image-source: images/top_panel.png
|
|
image-repeated: true
|
|
focusable: false
|
|
|
|
|
|
TopPanel
|
|
id: topMenu
|
|
anchors.top: parent.top
|
|
anchors.left: parent.left
|
|
anchors.right: parent.right
|
|
|
|
TopMenuButtonsPanel
|
|
id: leftButtonsPanel
|
|
anchors.top: parent.top
|
|
anchors.bottom: parent.bottom
|
|
anchors.left: parent.left
|
|
|
|
TopMenuButtonsPanel
|
|
id: leftGameButtonsPanel
|
|
anchors.top: parent.top
|
|
anchors.bottom: parent.bottom
|
|
anchors.left: prev.right
|
|
visible: false
|
|
|
|
UILabel
|
|
id: frameCounter
|
|
text-align: right
|
|
text-auto-resize: true
|
|
color: white
|
|
id: frameCounter
|
|
anchors.top: parent.top
|
|
anchors.left: prev.right
|
|
margin-top: 8
|
|
margin-right: 5
|
|
@onSetup: |
|
|
cycleEvent(function()
|
|
local frameCounter = rootWidget:recursiveGetChildById('frameCounter')
|
|
if frameCounter then
|
|
local text = 'FPS: ' .. g_app.getBackgroundPaneFps()
|
|
frameCounter:setText(text)
|
|
--print(text)
|
|
end
|
|
end, 250)
|
|
|
|
TopMenuButtonsPanel
|
|
id: rightButtonsPanel
|
|
anchors.top: parent.top
|
|
anchors.bottom: parent.bottom
|
|
anchors.right: parent.right
|
|
|
|
TopMenuButtonsPanel
|
|
id: rightGameButtonsPanel
|
|
anchors.top: parent.top
|
|
anchors.bottom: parent.bottom
|
|
anchors.right: prev.left
|
|
visible: false
|