Difference between revisions of "StructureSpawn"
Line 6: | Line 6: | ||
When a creep is finished spawning, it will emerge from the spawn one position above the spawn. If this location is blocked somehow it will spawn in the next adjacent location in clock-wise order, following the game's direction constants. |
When a creep is finished spawning, it will emerge from the spawn one position above the spawn. If this location is blocked somehow it will spawn in the next adjacent location in clock-wise order, following the game's direction constants. |
||
− | TOP: 1, TOP_RIGHT: 2, RIGHT: 3, BOTTOM_RIGHT: 4, BOTTOM: 5, BOTTOM_LEFT: 6, LEFT: 7, TOP_LEFT: 8 |
+ | TOP: 1, TOP_RIGHT: 2, RIGHT: 3, BOTTOM_RIGHT: 4, BOTTOM: 5, BOTTOM_LEFT: 6, LEFT: 7, TOP_LEFT: 8<br/> |
[[File:spawnDirection.gif]] |
[[File:spawnDirection.gif]] |
||
Revision as of 14:30, 17 February 2017
Please view the API documentation for StructureSpawn.
This page is meant to provide some extra information that is not included in the documentation.
Creep Spawn Direction
When a creep is finished spawning, it will emerge from the spawn one position above the spawn. If this location is blocked somehow it will spawn in the next adjacent location in clock-wise order, following the game's direction constants.
TOP: 1, TOP_RIGHT: 2, RIGHT: 3, BOTTOM_RIGHT: 4, BOTTOM: 5, BOTTOM_LEFT: 6, LEFT: 7, TOP_LEFT: 8
Spawn Stomping
If all locations around the spawn are blocked by structures or your own creeps, the spawning creep will not emerge, and will instead wait until a location becomes available and then spawn in that direction. If all locations around the spawn are blocked and there is a hostile creep blocking any of the locations the spawn will treat those locations as available and spawn the creep on top of the first location available, KILLING the hostile creep that is in that location.