[2.0.21] Existence of LuaGuiElement with type "camera" can cause rails to be placed incorrectly

This subforum contains all the issues which we already resolved.
grandseiken
Burner Inserter
Burner Inserter
Posts: 15
Joined: Wed Aug 02, 2023 11:18 pm
Contact:

[2.0.21] Existence of LuaGuiElement with type "camera" can cause rails to be placed incorrectly

Post by grandseiken »

Commiserations for the bizarre bug report, but as far as I can tell it is true.

If a mod has created a LuaGuiElement of type "camera" which is currently active/visible, the rail planner behaves erratically. Roughly, it seems as though the rail creation logic believes the mouse cursor is somewhere other than where it actually is, although the preview behaves correctly. So you get nonsensical errors about placement collisions even though the rail preview is green, and when you do manage to place some rails they appear in a completely different configuration than you expected.

The behaviour seems to depend to some extent on the position and scale of the custom camera, perhaps relative to the player's actual position? I am not sure, but sometimes things work OK even when the camera is open, it seems to depend on if I'm physically close to the area the camera is showing or not. If you close the custom mod camera the rail planner starts working as usual again.

I have attached two files:
* A save file you can load up and you'll be standing next to some rails with a camera open, trying to place some rails will show the bug
* A video of me doing exactly that
ultracube age of the cube.zip
(6.6 MiB) Downloaded 16 times
Last edited by grandseiken on Sat Nov 23, 2024 11:17 pm, edited 1 time in total.
grandseiken
Burner Inserter
Burner Inserter
Posts: 15
Joined: Wed Aug 02, 2023 11:18 pm
Contact:

Re: [2.0.21] The existence of a LuaGuiElement with type "camera" can cause rails to be placed incorrectly

Post by grandseiken »

Sorry, here is the video, it didn't attach correctly to the first post.
2024-11-23 23-10-49.mp4
(37.54 MiB) Downloaded 32 times
Rseding91
Factorio Staff
Factorio Staff
Posts: 15082
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [2.0.21] Existence of LuaGuiElement with type "camera" can cause rails to be placed incorrectly

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”