[Rseding91] [2.0.18] GUI not visible when opened by script in non-hosting clients

This subforum contains all the issues which we already resolved.
m44v
Fast Inserter
Fast Inserter
Posts: 136
Joined: Sun May 15, 2016 8:55 pm
Contact:

[Rseding91] [2.0.18] GUI not visible when opened by script in non-hosting clients

Post by m44v »

This is technically a modded game but I think that maybe is exposing a bug.

I have a mod that basically uses a keyboard shortcut for opening entities, the control.lua is like this:

Code: Select all

local function onKey(event)
    local player = game.get_player(event.player_index)
    local entity = player.selected
    if entity and entity.valid then
        player.opened = entity
    end
end

script.on_event("test-keybind", onKey)
The shortcut is the "F" key. In normal gameplay and as a host it works as expected, however it doesn't for non-hosting clients, it seems like the GUI opens but is invisible:
Screenshot_20241115_235004.png
Screenshot_20241115_235004.png (3.55 MiB) Viewed 718 times
Because it only happens with non-hosting clients maybe is an issue with the latency hiding system? I know that in Factorio 1.1 this worked. A minimal mod is attached.
Attachments
test-mod_0.1.0.zip
(1.1 KiB) Downloaded 18 times
Rseding91
Factorio Staff
Factorio Staff
Posts: 14770
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [Rseding91] [2.0.18] GUI not visible when opened by script in non-hosting clients

Post by Rseding91 »

Thanks for the report. This is now fixed for the next release.
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Resolved Problems and Bugs”