Page 1 of 1

Allow custom tools to get selected tiles and entities

Posted: Mon Jul 24, 2017 7:16 am
by d3x0r
Reported originally as a bug because blueprint appears to do the same thing, until you get into the edit screen and can check 'tiles' selection...

viewtopic.php?f=23&t=51197


with a custom select tool even with selection_mode = {"buildable-type","items-to-place","tiles","blueprint"},

I'm not getting tiles and entities; unless the tiles happen to be ghost tiles.

Re: Allow custom tools to get selected tiles and entities

Posted: Mon Jul 24, 2017 10:16 am
by Rseding91
You can use the "always_include_tiles" prototype flag to as the name suggests: always include tiles.

Re: Allow custom tools to get selected tiles and entities

Posted: Mon Jul 24, 2017 11:17 am
by d3x0r
Rseding91 wrote:You can use the "always_include_tiles" prototype flag to as the name suggests: always include tiles.
no such flag...
Mods to disable:Failed to load mods: Error while loading item prototype "upgrade-builder2" (selection-tool): Unknown selection tool flag: always_include_tiles

https://wiki.factorio.com/Prototype/SelectionTool

any-tile includes ground tiles which I don't really want... would be harmless other than it looks bad on selection

Re: Allow custom tools to get selected tiles and entities

Posted: Mon Jul 24, 2017 1:03 pm
by Rseding91
d3x0r wrote:
Rseding91 wrote:You can use the "always_include_tiles" prototype flag to as the name suggests: always include tiles.
no such flag...
Mods to disable:Failed to load mods: Error while loading item prototype "upgrade-builder2" (selection-tool): Unknown selection tool flag: always_include_tiles

https://wiki.factorio.com/Prototype/SelectionTool

any-tile includes ground tiles which I don't really want... would be harmless other than it looks bad on selection
It's not a selection tool flag. It's a property:

Code: Select all

{
type="...",
name="...",
always_include_tiles = true
}

Re: Allow custom tools to get selected tiles and entities

Posted: Mon Jul 24, 2017 6:10 pm
by d3x0r
Thank you :) Works beautifully.