[1.1.5] Cameras show entity placement preview on other surfaces

This subforum contains all the issues which we already resolved.
MagmaMcFry
Inserter
Inserter
Posts: 37
Joined: Sun Jul 17, 2016 9:05 pm
Contact:

[1.1.5] Cameras show entity placement preview on other surfaces

Post by MagmaMcFry »

Bug:
If you hold a buildable entity or blueprint, and a camera GUI element displays an area containing the XY coordinates of your cursor, the placement preview, including obstruction hitboxes, will show up in the camera window even if the surface is not the one you're trying to build on.

I would expect the placement preview to only show up on cameras for the correct surface, or not on camera at all.

Steps to reproduce:
1. Create a new freeplay world.
2. Run the following console command:

Code: Select all

/c
game.player.teleport(game.player.surface.find_non_colliding_position(game.player.character.name, {0,0}, 5, 0.5, false) or {0,0})
game.create_surface("other", { seed = 1337 })
game.player.force.chart("other", {{x = -31, y = -31}, {x = 31, y = 31}})
local camera = game.player.gui.top.add{type = "camera", name = "test_camera", position = {0, 0}, surface_index = game.surfaces.other.index, zoom = 0.5}
camera.style.minimal_width = 300
camera.style.minimal_height = 300
This creates a new surface and a camera rendering it, and teleports your character to the corresponding coordinates on the current surface.
3. Take your furnace, or a blueprint, and move it around as if to place it.
Result: The camera in the top left corner will now show the furnace or blueprint, and the hitboxes of all objects preventing its placement, as if they were at the same coordinates on the other surface.
I don't visit the forum very often. If you want to contact me, message me on the mod portal for Factorissimo-related things, or on Discord.
posila
Factorio Staff
Factorio Staff
Posts: 5353
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [1.1.5] Cameras show entity placement preview on other surfaces

Post by posila »

Thanks for the report.
Fixed for 1.1.5.

I made camera widget not render entity placement preview (which is how it used to work before 1.1, I believe).
But I also fixed building preview from different surface being rendered on different surface, in case camera widget gets option to enable this :)
Post Reply

Return to “Resolved Problems and Bugs”