diff --git a/modules/game_interface/gameinterface.lua b/modules/game_interface/gameinterface.lua index 083d5e12..cf5247e0 100644 --- a/modules/game_interface/gameinterface.lua +++ b/modules/game_interface/gameinterface.lua @@ -15,7 +15,8 @@ function init() g_ui.importStyle('styles/countwindow.otui') connect(g_game, { onGameStart = show, - onGameEnd = hide }, true) + onGameEnd = hide, + onLoginAdvice = onLoginAdvice }, true) gameRootPanel = g_ui.displayUI('gameinterface.otui') gameRootPanel:hide() @@ -73,7 +74,8 @@ end function terminate() disconnect(g_game, { onGameStart = show, - onGameEnd = hide }) + onGameEnd = hide, + onLoginAdvice = onLoginAdvice }) disconnect(gameLeftPanel, { onVisibilityChange = onLeftPanelVisibilityChange }) logoutButton:destroy() @@ -108,6 +110,10 @@ function hide() Background.show() end +function onLoginAdvice(message) + displayInfoBox("For Your Information", message) +end + function forceExit() scheduleEvent(exit, 10) return true @@ -538,4 +544,3 @@ function onLeftPanelVisibilityChange(leftPanel, visible) end end end -