Prototype/MiningTool: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
mNo edit summary
(0.16)
Line 1: Line 1:
==basics==
==basics==
A tool to mine ore out of the ground, break rocks, and damage enemies.
A tool to mine ore out of the ground, break rocks, and damage enemies.Extends [[Prototype/Tool]].
==properites==
 
===type===
== Mandatory properties ==
'''type''': [[Types/string]]
This prototype inherits all the properties from [[Prototype/Tool]].
Must be "mining-tool"
 
===action===
=== speed ===
'''Type''': [[Types/float]]
 
Mining speed.
 
== Optional properties ==
 
=== action ===
'''Type''': [[Types/Trigger]]
 
Tells the mining tool what to do when the player uses it.
Tells the mining tool what to do when the player uses it.


==example==
=== action_range ===
    {
'''Type''': [[Types/float]]
      type="direct",
 
      action_delivery =
'''Default''': 1.5
      {
 
        type = "instant",
=== build_distance_bonus ===
        target_effects =
'''Type''': [[Types/double]]
        {
 
          type = "damage",
'''Default''': 0.0
          damage =
 
          {
Must be positive.
            amount = 8,
 
            type = "physical"
=== item_drop_distance_bonus ===
          }
'''Type''': [[Types/double]]
        }
 
      }
'''Default''': 0.0
    },
 
Must be positive.
 
=== reach_distance_bonus ===
'''Type''': [[Types/double]]
 
'''Default''': 0.0
 
Must be positive.
 
=== item_pickup_distance_bonus ===
'''Type''': [[Types/double]]
 
'''Default''': 0.0
 
Must be positive.
 
=== loot_pickup_distance_bonus ===
'''Type''': [[Types/double]]
 
'''Default''': 0.0
 
Must be positive.
 
=== resource_reach_distance_bonus ===
'''Type''': [[Types/double]]
 
'''Default''': 0.0
 
Must be positive.

Revision as of 10:00, 22 May 2018

basics

A tool to mine ore out of the ground, break rocks, and damage enemies.Extends Prototype/Tool.

Mandatory properties

This prototype inherits all the properties from Prototype/Tool.

speed

Type: Types/float

Mining speed.

Optional properties

action

Type: Types/Trigger

Tells the mining tool what to do when the player uses it.

action_range

Type: Types/float

Default: 1.5

build_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.

item_drop_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.

reach_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.

item_pickup_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.

loot_pickup_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.

resource_reach_distance_bonus

Type: Types/double

Default: 0.0

Must be positive.