Prototype/SelectionTool: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
(show_in_library is unused as of 0.18.13)
(→‎Mandatory properties: selection_cursor_box_type - add default colors to values list)
Line 85: Line 85:
| not-allowed || The selection box used when specifying colliding entities. Red by default.
| not-allowed || The selection box used when specifying colliding entities. Red by default.
|-
|-
| pair ||  
| pair || Light Blue by default.
|-
|-
| logistics ||
| logistics || Light Blue by default.
|-
|-
| train-visualization ||
| train-visualization || White by default.
|}
|}



Revision as of 21:46, 3 May 2020

Prototype definitions » PrototypeBase » Prototype/Item » Prototype/ItemWithLabel » Prototype/SelectionTool


Used in the base game as a base for the blueprint item and the deconstruction item.


Prototype/SelectionTool — selection-tool
alt_selection_color::Color
alt_selection_cursor_box_type::CursorBoxType
alt_selection_mode::table of string
selection_color::Color
selection_cursor_box_type::CursorBoxType
selection_mode::table of string
alt_entity_filter_mode::string (optional)
alt_entity_filters::table of string (optional)
alt_entity_type_filters::table of string (optional)
alt_reverse_entity_filter_mode::string (optional)
alt_reverse_entity_filters::table of string (optional)
alt_reverse_entity_type_filters::table of string (optional)
alt_reverse_selection_color::Color (optional)
alt_reverse_selection_count_button_color::Color (optional)
alt_reverse_selection_cursor_box_type::CursorBoxType (optional)
alt_reverse_selection_mode::table of string (optional)
alt_reverse_tile_filter_mode::string (optional)
alt_reverse_tile_filters::table of string (optional)
alt_selection_count_button_color::Color (optional)
alt_tile_filter_mode::string (optional)
alt_tile_filters::table of string (optional)
always_include_tiles::bool (optional)
chart_alt_reverse_selection_color::Color (optional)
chart_alt_selection_color::Color (optional)
chart_reverse_selection_color::Color (optional)
chart_selection_color::Color (optional)
entity_filter_mode::string (optional)
entity_filters::table of string (optional)
entity_type_filters::table of string (optional)
mouse_cursor::string (optional)
reverse_entity_filter_mode::string (optional)
reverse_entity_filters::table of string (optional)
reverse_entity_type_filters::table of string (optional)
reverse_selection_color::Color (optional)
reverse_selection_count_button_color::Color (optional)
reverse_selection_cursor_box_type::CursorBoxType (optional)
reverse_selection_mode::table of string (optional)
reverse_tile_filter_mode::string (optional)
reverse_tile_filters::table of string (optional)
selection_count_button_color::Color (optional)
tile_filter_mode::string (optional)
tile_filters::table of string (optional)
Inherited from Prototype/ItemWithLabel
default_label_color::Color (optional)
draw_label_for_cursor_render::bool (optional)
Inherited from Prototype/Item
icons, icon, icon_size (IconSpecification)::IconSpecification
stack_size::ItemCountType
burnt_result::string (optional)
close_sound::Sound (optional)
dark_background_icons, dark_background_icon, icon_size (IconSpecification)::IconSpecification (optional)
default_request_amount::ItemCountType (optional)
flags::ItemPrototypeFlags (optional)
fuel_acceleration_multiplier::double (optional)
fuel_category::string (optional)
fuel_emissions_multiplier::double (optional)
fuel_glow_color::Color (optional)
fuel_top_speed_multiplier::double (optional)
fuel_value::Energy (optional)
open_sound::Sound (optional)
pictures::SpriteVariations (optional)
place_as_tile::PlaceAsTile (optional)
place_result::string (optional)
placed_as_equipment_result::string (optional)
rocket_launch_product::ItemProductPrototype (optional)
rocket_launch_products::table (array) of ItemProductPrototype (optional)
subgroup::string (optional)
wire_count::ItemCountType (optional)
Inherited from PrototypeBase
name::string
type::string
localised_description::LocalisedString (optional)
localised_name::LocalisedString (optional)
order::Order (optional)

Extensions

Mandatory properties

This prototype inherits all the properties from Prototype/ItemWithLabel.

selection_color

Type: Color
The color of the rectangle used when standard selection is done in-game.

alt_selection_color

Type: Color
The color of the rectangle used when alt-selection is done in-game.

selection_mode

Type: table of string
A list of selection mode flags that define how the selection tool selects things in-game.

Possible values are:

Flag meaning
blueprint The normal rules for acceptable entities in blueprints
deconstruct The normal rules for acceptable entities for deconstruction
cancel-deconstruct The normal rules for acceptable entities for cancel deconstruction
items Item entities
trees Trees
buildable-type Buildable entities as defined by the game
nothing Nothing
items-to-place The entity has an item that builds the entity
any-entity Any entity
any-tile Any tile
same-force The entity force matches that of the player doing the selection
not-same-force The entity force does not match that of the player doing the selection
friend The entity force is friend to that of the player doing the selection
enemy The entity force is enemy to that of the player doing the selection
upgrade The normal rules for acceptable entities in upgrade planners
cancel-upgrade The normal rules for acceptable entities for cancel upgrade
entity-with-health
entity-with-force
entity-with-owner

alt_selection_mode

Type: table of string
A list of selection mode flags that define how the selection tool alt-selects things in-game. Possible values are identical to normal selection_mode.

selection_cursor_box_type

Type: string
The type of cursor box used to render selection of entities/tiles when standard selecting.

Possible values are:

Flag meaning
entity The normal entity selection box. Yellow by default.
electricity The selection box used to specify electric poles an entity is connected to. Light blue by default.
copy The selection box used when doing entity copy-paste. Green by default.
not-allowed The selection box used when specifying colliding entities. Red by default.
pair Light Blue by default.
logistics Light Blue by default.
train-visualization White by default.

alt_selection_cursor_box_type

Type: string
The type of cursor box used to render selection of entities/tiles when alt selecting. Possible values are identical to normal selection_cursor_box_type.

Optional properties

always_include_tiles

Type: bool
Default: false
If tiles should be included in the selection regardless of entities also being in the selection. This is a visual only setting.

show_in_library

Type: bool
Default: false
Whether this is shown in the blueprint library. Unused as of 0.18.13 as the ability to show any selection tools in the blueprint library was removed.

mouse_cursor

Type: string
Default: "selection-tool-cursor"
Name of a Prototype/MouseCursor.

entity_filters

Type: table of string
Array of Prototype/Entity names.

alt_entity_filters

Type: table of string
Array of Prototype/Entity names.

entity_type_filters

Type: table of string

alt_entity_type_filters

Type: table of string

tile_filters

Type: table of string
Array of Prototype/Tile names.

alt_tile_filters

Type: table of string
Array of Prototype/Tile names.

entity_filter_mode

Type: string
Default: "whitelist"
One of "whitelist" and "blacklist".

alt_entity_filter_mode

Type: string
Default: "whitelist"
One of "whitelist" and "blacklist".

tile_filter_mode

Type: string
Default: "whitelist"
One of "whitelist" and "blacklist".

alt_tile_filter_mode

Type: string
Default: "whitelist"
One of "whitelist" and "blacklist".