aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-30 19:13:18 +0000
committerBobTheBob <32057864+BobTheBob9@users.noreply.github.com>2021-12-30 19:13:18 +0000
commit3044198c4078b7bd72ecc84e833e490941d23d10 (patch)
treee90ecc53022ed69b24d21cc52bf93f1f3865e30e
parent042ce0e735a67db0f956c1b7e9951ce56d44ec5f (diff)
downloadNorthstarMods-3044198c4078b7bd72ecc84e833e490941d23d10.tar.gz
NorthstarMods-3044198c4078b7bd72ecc84e833e490941d23d10.zip
prevent script error in server browser
-rw-r--r--Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut10
1 files changed, 7 insertions, 3 deletions
diff --git a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
index a989da12..7252d3d5 100644
--- a/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
+++ b/Northstar.Client/mod/scripts/vscripts/ui/menu_ns_serverbrowser.nut
@@ -364,9 +364,13 @@ void function UpdateServerInfoBasedOnRes()
////////////////////////////
void function OnCloseServerBrowserMenu()
{
- DeregisterButtonPressedCallback(MOUSE_WHEEL_UP , OnScrollUp)
- DeregisterButtonPressedCallback(MOUSE_WHEEL_DOWN , OnScrollDown)
- DeregisterButtonPressedCallback(KEY_TAB , OnKeyTabPressed)
+ try
+ {
+ DeregisterButtonPressedCallback(MOUSE_WHEEL_UP , OnScrollUp)
+ DeregisterButtonPressedCallback(MOUSE_WHEEL_DOWN , OnScrollDown)
+ DeregisterButtonPressedCallback(KEY_TAB , OnKeyTabPressed)
+ }
+ catch ( ex ) {}
}
void function OnServerBrowserMenuOpened()