2 ------------------------------------------------------------------------------------------------------------
3 -- create the game namespace without reseting if already created in an other file.
8 ------------------------------------------------------------------------------------------------------------
10 function game
:getMilkoTooltipWithKey(prop
, tooltip
, tooltip_pushed
, name
, param
)
13 -- Check if button is toggled and choose the good tooltip
14 if (prop
~= '' and tooltip_pushed
~= '') then
15 local db
= getDbProp(prop
)
26 local text
= i18n
.get(tt
)
27 local key
= runExpr('getKey(\'' .. name
.. '\',\'' .. param
.. '\',1)')
29 if (key
~= nil and key
~= '') then
30 key
= ' @{2F2F}(' .. key
.. ')'
31 text
= concatUCString(text
, key
)
34 setContextHelpText(text
)
37 function game
:taskbarDisableTooltip(ui
)
38 local uiGroup
= getUI(ui
)
39 disableContextHelpForControl(uiGroup
)
42 function game
:activeMilkoKey(key
, status
)
43 local ui
= getUI("ui:interface:milko_pad:content:mode5:window"..tostring(key
))
49 function game
:resizeMilkoPad()
50 if getDbProp("UI:SAVE:SKIP_TUTORIAL") == 1 then
51 removeOnDbChange(getUI("ui:interface"), "@UI:SAVE:MK_MODE")
52 game
:activeMilkoKey(1, true)
53 game
:activeMilkoKey(2, true)
54 game
:activeMilkoKey(3, true)
55 game
:activeMilkoKey(4, true)
56 game
:activeMilkoKey(5, true)
57 game
:activeMilkoKey(6, true)
58 game
:activeMilkoKey(7, true)
59 game
:activeMilkoKey(8, true)
60 game
:activeMilkoKey(9, true)
61 getUI("ui:interface:milko_pad:content:mode_button").active
= true
62 setDbProp("UI:SAVE:MK_MODE", 1)
63 setDbProp("UI:SAVE:MK_MODE", 5)
64 getUI("ui:interface:milko_pad:content:mode5").x
= 16
68 local mk_mode
= getDbProp("UI:SAVE:MK_MODE")
70 local ui
= getUI("ui:interface:milko_pad:content:mode_button")
72 if ui
and ui
.active
then
74 getUI("ui:interface:milko_pad:content:mode5").x
= 16
76 getUI("ui:interface:milko_pad:content:mode5").x
= 0
80 ui
= getUI("ui:interface:milko_pad:content:mode5:window"..tostring(i
))
81 if ui
and ui
.active
then
85 ui
= getUI("ui:interface:milko_pad")
87 ui
.w
= offset
+ (24*total
)
88 ui
.x
= ui
.x
+ last_w
- ui
.w
92 function game
:updateMilkoKey(key
, status
)
93 game
:activeMilkoKey(key
, status
)
99 RYZOM_TASKBAR_VERSION
= 324