Types/AttackParameters

From Official Factorio Wiki
Revision as of 05:12, 15 July 2017 by LazyFridge (talk | contribs) (type)
Jump to: navigation, search

Basics

Definition of combat actions performed by combat robots, units, turrets and weapons.


Mandatory properties

type

Type: Types/string

Specification of the type. Values are:

   "projectile"
   "beam"
   "stream"

cooldown

Type: Types/int

Interval between consecutive attacks.

range

Type: Types/double

Distance of attack. Overrides one defined in ammo.

Semi-mandatory properties

Depending on actual type of entity the following might or might not be needed.

ammo_category

Type: Prototype/AmmoCategory

Mandatory for Prototype/Gun and Prototype/AmmoTurret. Describes which ammo should be used in attack.

ammo_type

Type: Types/AmmoType

Mandatory for Prototype/ElectricTurret, Prototype/CombatRobot and Prototype/Unit. Defines the ammo entities of those types use when attacking.

Optional properties

projectile_center

Type: Types/Position

projectile_creation_distance

Type: Types/double

Distance from the attacking entity, at which effects of ammo are applied (source_effects).

damage_modifier

Type: Types/double

Provides damage multiplier forPrototype/Gun and Prototype/AmmoTurret.

sound

Type: Lua/table

Sound the entity emits when it attacks. Table fields:

Filename Types/FileName
volume Types/double