Prototype/EnemySpawner: Difference between revisions

From Official Factorio Wiki
Jump to navigation Jump to search
Set prototype parent
Converted to SMW format
Line 1: Line 1:
{{Prototype parent|Prototype/EntityWithHealth}}
{{Prototype parent|Prototype/EntityWithHealth}}
Can spawn entities. Used for biter/spitter nests.


== Basics ==
{{Prototype TOC|unit-spawner}}
Prototype type: '''unit-spawner'''
 
Extends [[Prototype/EntityWithHealth]].


== Mandatory properties ==
== Mandatory properties ==
This prototype inherits all the properties from [[Prototype/EntityWithHealth]].
This prototype inherits all the properties from [[Prototype/EntityWithHealth]].


=== dying_sound ===
{{Prototype property|dying_sound|[[Types/Sound|Sound]]}}
'''Type''': [[Types/Sound]]


=== animations ===
{{Prototype property|animations|[[Types/AnimationVariations|AnimationVariations]]}}
'''Type''': [[Types/AnimationVariations]]
 
=== max_count_of_owned_units ===
'''Type''': [[Types/uint32]]


{{Prototype property|max_count_of_owned_units|[[Types/uint32|uint32]]}}
Count of enemies this spawner can sustain.
Count of enemies this spawner can sustain.


=== max_friends_around_to_spawn ===
{{Prototype property|max_friends_around_to_spawn|[[Types/uint32|uint32]]}}
'''Type''': [[Types/uint32]]
 
How many friendly units are required within the [[#spawning_radius|spawning_radius]] of this spawner for it to stop producing more units.
How many friendly units are required within the [[#spawning_radius|spawning_radius]] of this spawner for it to stop producing more units.


=== spawning_cooldown ===
{{Prototype property|spawning_cooldown|[[Types/Range|Range]]}}
'''Type''': [[Types/Range]]
 
Ticks for cooldown after unit is spawned
Ticks for cooldown after unit is spawned


=== spawning_radius ===
{{Prototype property|spawning_radius|[[Types/double|double]]}}
'''Type''': [[Types/double]]
 
How far from the spawner can the units be spawned.
How far from the spawner can the units be spawned.


=== spawning_spacing ===
{{Prototype property|spawning_spacing|[[Types/double|double]]}}
'''Type''': [[Types/double]]
 
What spaces should be between the spawned units.
What spaces should be between the spawned units.


=== max_richness_for_spawn_shift ===
{{Prototype property|max_richness_for_spawn_shift|[[Types/double|double]]}}
'''Type''': [[Types/double]]
 
Max richness to determine spawn shift. Spawn shift is linear interpolation between 0 and maxSpawnShift.
Max richness to determine spawn shift. Spawn shift is linear interpolation between 0 and maxSpawnShift.


=== max_spawn_shift ===
{{Prototype property|max_spawn_shift|[[Types/double|double]]}}
'''Type''': [[Types/double]]
 
Caps how much richness can be added on top of evolution when spawning units. (See also [https://www.reddit.com/r/factorio/comments/8pjscm/friday_facts_246_the_gui_update_part_3/e0bttnp/])
Caps how much richness can be added on top of evolution when spawning units. (See also [https://www.reddit.com/r/factorio/comments/8pjscm/friday_facts_246_the_gui_update_part_3/e0bttnp/])


=== pollution_absorption_absolute ===
{{Prototype property|pollution_absorption_absolute|[[Types/double|double]]}}
'''Type''': [[Types/double]]
 
=== pollution_absorption_proportional ===
'''Type''': [[Types/double]]


=== call_for_help_radius ===
{{Prototype property|pollution_absorption_proportional|[[Types/double|double]]}}
'''Type''': [[Types/double]]


=== result_units ===
{{Prototype property|call_for_help_radius|[[Types/double|double]]}}
'''Type''': [[Types/table]] of [[Types/UnitSpawnDefinition]]


Array of the [[Prototype/Unit]]s that this spawner can spawn and their spawn probabilities. The sum of probabilities is expected to be 1.0. The array must not be empty.
{{Prototype property|result_units|[[Types/table|table]] of [[Types/UnitSpawnDefinition|UnitSpawnDefinition]]}}
Array of the [[Prototype/Entity|entities]] that this spawner can spawn and their spawn probabilities. The sum of probabilities is expected to be 1.0. The array must not be empty.


== Optional properties ==
== Optional properties ==


=== integration ===
{{Prototype property|integration|[[Types/SpriteVariations|SpriteVariations]]|optional=true}}
'''Type''': [[Types/SpriteVariations]]
 
=== random_animation_offset ===
'''Type''': [[Types/bool]]
 
'''Default''': true
 
=== min_darkness_to_spawn ===
'''Type''': [[Types/float]]


'''Default''': 0.0
{{Prototype property|random_animation_offset|[[Types/bool|bool]]|true|optional=true}}


=== max_darkness_to_spawn ===
{{Prototype property|min_darkness_to_spawn|[[Types/float|float]]|0.0|optional=true}}
'''Type''': [[Types/float]]


'''Default''': 1.0
{{Prototype property|max_darkness_to_spawn|[[Types/float|float]]|1.0|optional=true}}

Revision as of 20:06, 29 July 2019

Template:Prototype parent Can spawn entities. Used for biter/spitter nests.

Template:Prototype TOC

Mandatory properties

This prototype inherits all the properties from Prototype/EntityWithHealth.

Template:Prototype property

Template:Prototype property

Template:Prototype property Count of enemies this spawner can sustain.

Template:Prototype property How many friendly units are required within the spawning_radius of this spawner for it to stop producing more units.

Template:Prototype property Ticks for cooldown after unit is spawned

Template:Prototype property How far from the spawner can the units be spawned.

Template:Prototype property What spaces should be between the spawned units.

Template:Prototype property Max richness to determine spawn shift. Spawn shift is linear interpolation between 0 and maxSpawnShift.

Template:Prototype property Caps how much richness can be added on top of evolution when spawning units. (See also [1])

Template:Prototype property

Template:Prototype property

Template:Prototype property

Template:Prototype property Array of the entities that this spawner can spawn and their spawn probabilities. The sum of probabilities is expected to be 1.0. The array must not be empty.

Optional properties

Template:Prototype property

Template:Prototype property

Template:Prototype property

Template:Prototype property