-
Notifications
You must be signed in to change notification settings - Fork 20
Script driven GUI System
Cook Green edited this page May 4, 2020
·
8 revisions
<UILayout ID="ui_custom_game">
<Background Type="NoChange"></Background>
<Script>ui_custom_game.script</Script>
<Widgets>
<Widget Type="Label" TrayLocation="TL_TOP">
<WidgetParameters>
<WidgetParameter Name="name" Type="String">lbTitle</WidgetParameter>
<WidgetParameter Name="caption" Type="String">str_custom_game_title</WidgetParameter>
<WidgetParameter Name="width" Type="Float">200</WidgetParameter>
</WidgetParameters>
</Widget>
</Widgets>
</UILayout>
Entry function for UI is uiInit function, you can add some init code in this function
You can capture the UI event change in uiEventChanged function, this function needs two paramters:
Param 1: widgetID
Param 2: value
function uiEventChanged
store_input_param %widgetID 1
store_input_param %value 2
...other code...
end