Skip to content

Commit

Permalink
Merge pull request #629 from FIr3baL/FB_Fix_ModoptionsPanel_UseRemote…
Browse files Browse the repository at this point in the history
…State

store received modoptions-state from lobby host to local modoptions a…
  • Loading branch information
FIr3baL authored Apr 4, 2024
2 parents 6142c0b + 010bf27 commit b9493d4
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions LuaMenu/widgets/gui_modoptions_panel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,7 @@ local function CreateModoptionWindow()
modoptionsSelectionWindow:Dispose()
end

local buttonAccept
local buttonAccept, buttonReset

local function AcceptFunc()
screen0:FocusControl(buttonAccept) -- Defocus the text entry
Expand Down Expand Up @@ -536,9 +536,8 @@ local function InitializeModoptionsDisplay()
local function OnSetModOptions(listener, modopts)
local text = ""
local empty = true
modoptions = modoptions or {}
modopts = modopts or {}
for key, value in pairs(modopts) do
modoptions = modopts or {}
for key, value in pairs(modoptions) do
if modoptionDefaults[key] == nil or modoptionDefaults[key] ~= value or key == "ranked_game" then
local option = getModOptionByKey(key)
local name = option.name and option.name or key
Expand Down

0 comments on commit b9493d4

Please sign in to comment.