mirror of
https://github.com/JezuzLizard/BO2-Reimagined.git
synced 2025-06-07 21:59:49 -05:00
Fix ui_gametype and ui_mapname dvars being reset
This commit is contained in:
parent
6cbee1ac1c
commit
6be111a628
@ -166,7 +166,11 @@ local function mapListSelectionClickedEventHandler( self, event )
|
|||||||
end
|
end
|
||||||
|
|
||||||
if UIExpression.DvarBool(nil, "ui_game_lobby_open") == 0 then
|
if UIExpression.DvarBool(nil, "ui_game_lobby_open") == 0 then
|
||||||
CoD.SwitchToPrivateLobby(self.controller)
|
local gameType = UIExpression.DvarString(nil, "ui_gametype")
|
||||||
|
local mapName = UIExpression.DvarString(nil, "ui_mapname")
|
||||||
|
CoD.SwitchToPrivateLobby(self.controller) -- this changes "ui_gametype" and "ui_mapname"
|
||||||
|
Engine.SetDvar("ui_gametype", gameType)
|
||||||
|
Engine.SetDvar("ui_mapname", mapName)
|
||||||
end
|
end
|
||||||
|
|
||||||
self:openMenu("PrivateOnlineGameLobby", self.controller)
|
self:openMenu("PrivateOnlineGameLobby", self.controller)
|
||||||
@ -280,7 +284,11 @@ local function locationListSelectionClickedEventHandler( self, event )
|
|||||||
end
|
end
|
||||||
|
|
||||||
if UIExpression.DvarBool(nil, "ui_game_lobby_open") == 0 then
|
if UIExpression.DvarBool(nil, "ui_game_lobby_open") == 0 then
|
||||||
CoD.SwitchToPrivateLobby(self.controller)
|
local gameType = UIExpression.DvarString(nil, "ui_gametype")
|
||||||
|
local mapName = UIExpression.DvarString(nil, "ui_mapname")
|
||||||
|
CoD.SwitchToPrivateLobby(self.controller) -- this changes "ui_gametype" and "ui_mapname"
|
||||||
|
Engine.SetDvar("ui_gametype", gameType)
|
||||||
|
Engine.SetDvar("ui_mapname", mapName)
|
||||||
end
|
end
|
||||||
|
|
||||||
self:openMenu("PrivateOnlineGameLobby", self.controller)
|
self:openMenu("PrivateOnlineGameLobby", self.controller)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user