Fix last menu closing bugging out on new rounds.
parent
21d3019a2d
commit
9b6e651656
|
@ -102,11 +102,11 @@ end
|
||||||
|
|
||||||
hook.Add( "PlayerBindPress", "PlayerBindPressFKeyMenus", function(pl, bind, pressed)
|
hook.Add( "PlayerBindPress", "PlayerBindPressFKeyMenus", function(pl, bind, pressed)
|
||||||
if bind == "gm_showspare2" and pressed then
|
if bind == "gm_showspare2" and pressed then
|
||||||
if lastMenu ~= nil then
|
if IsValid(lastMenu) and lastMenu ~= nil then
|
||||||
lastMenu:Hide()
|
lastMenu:Hide()
|
||||||
end
|
end
|
||||||
lastMenu = CreateMenu()
|
lastMenu = CreateMenu()
|
||||||
if lastMenu ~= nil then
|
if IsValid(lastMenu) and lastMenu ~= nil then
|
||||||
lastMenu:Open()
|
lastMenu:Open()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue