LuaControl.can_place_tile

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
User avatar
protocol_1903
Filter Inserter
Filter Inserter
Posts: 388
Joined: Fri Sep 09, 2022 4:33 pm
Contact:

LuaControl.can_place_tile

Post by protocol_1903 »

Same as LuaControl.can_place_entity but for tiles, to run easier checks on normal tile buildability rules
Py and PyBlock developer, wielder of LUA in arbitrary ways. I make mods. Check them out, maybe.
https://mods.factorio.com/user/protocol_1903
curiosity
Filter Inserter
Filter Inserter
Posts: 709
Joined: Wed Sep 11, 2019 4:13 pm
Contact:

Re: LuaControl.can_place_tile

Post by curiosity »

Surely you'd want can_place_tiles more. I don't imagine it's often the case that you want to check only a single tile.

(also, can_place_entity is found in LuaPlayer and LuaSurface, not in LuaControl; I'd expect you want the tile function for both)
Rseding91
Factorio Staff
Factorio Staff
Posts: 16284
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: LuaControl.can_place_tile

Post by Rseding91 »

By placing a given tile it may make placing another invalid (tile placement rules can require you do not build within x distance of another tile). So can place tiles is not likely to be super useful.
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Modding interface requests”