Documentation associating EntityPrototype::build_grid_size and LuaEntityPrototype.building_grid_bit_shift

sparr
Smart Inserter
Smart Inserter
Posts: 1521
Joined: Fri Feb 14, 2014 5:52 pm
Contact:

Documentation associating EntityPrototype::build_grid_size and LuaEntityPrototype.building_grid_bit_shift

Post by sparr »

I need to know if an entity should be treated like rails for placement purposes due to having a build_grid_size of 2 instead of 1.

I found LuaEntityPrototype.building_grid_bit_shift and it sounds and looks like it's the log2 (plus one) of build_grid_size, but the docs aren't quite clear on that, and the naming mismatch is weird. If this is the right thing, maybe mention them in each others' docs?
Bilka
Factorio Staff
Factorio Staff
Posts: 3636
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: Documentation associating EntityPrototype::build_grid_size and LuaEntityPrototype.building_grid_bit_shift

Post by Bilka »

Thanks for the note, updated the docs for 2.0.64.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.
Post Reply

Return to “Resolved Requests”