mirror of
https://github.com/ComfyFactory/ComfyFactorio.git
synced 2025-05-13 21:56:29 +02:00
Fix minor gui issue
This commit is contained in:
parent
da10bf40dc
commit
7cf25ff1c0
@ -21,7 +21,7 @@ local Public = {}
|
||||
local screen_elements = {}
|
||||
local this = {
|
||||
settings = {
|
||||
mod_gui_top_frame = false
|
||||
mod_gui_top_frame = true
|
||||
}
|
||||
}
|
||||
|
||||
@ -36,8 +36,8 @@ Global.register(
|
||||
---@param player <userdata>
|
||||
---@param frame <object>
|
||||
---@param name <string>
|
||||
function Public.add_mod_button(player, frame, name)
|
||||
if Gui.get_button_flow(player)[name] then
|
||||
function Public.add_mod_button(player, frame)
|
||||
if Gui.get_button_flow(player)[frame.name] and Gui.get_button_flow(player)[frame.name].valid then
|
||||
return
|
||||
end
|
||||
|
||||
|
@ -774,8 +774,7 @@ local function player_joined(event)
|
||||
name = main_button_name,
|
||||
sprite = 'item/programmable-speaker',
|
||||
tooltip = 'Let your question be heard!'
|
||||
},
|
||||
'main_button_name'
|
||||
}
|
||||
)
|
||||
else
|
||||
if player.gui.top[main_button_name] ~= nil then
|
||||
|
@ -149,8 +149,7 @@ local function create_main_button(event)
|
||||
name = main_button_name,
|
||||
sprite = 'utility/surface_editor_icon',
|
||||
tooltip = 'Connect to another Comfy server!'
|
||||
},
|
||||
main_button_name
|
||||
}
|
||||
)
|
||||
else
|
||||
local main_button = player.gui.top[main_button_name]
|
||||
|
@ -574,8 +574,7 @@ local function create_gui_button(player)
|
||||
name = 'auto_stash',
|
||||
sprite = 'item/wooden-chest',
|
||||
tooltip = tooltip
|
||||
},
|
||||
'auto_stash'
|
||||
}
|
||||
)
|
||||
else
|
||||
local b =
|
||||
|
Loading…
x
Reference in New Issue
Block a user