Fix market reload and a crash when exiting

This commit is contained in:
Eduardo Bart
2012-07-31 11:42:26 -03:00
parent bca1af8f11
commit 614d1544c0
13 changed files with 15 additions and 23 deletions

View File

@@ -128,6 +128,7 @@ function initProtocol()
-- reloading module
if g_game.isOnline() then
MarketProtocol.registerProtocol()
MarketProtocol.updateProtocol(g_game.getProtocolGame())
end
end
@@ -139,6 +140,7 @@ function terminateProtocol()
-- reloading module
if not g_game.isOnline() then
MarketProtocol.updateProtocol(nil)
MarketProtocol.unregisterProtocol()
end
MarketProtocol = nil
end