destroy(ticks?) | Schedules this space platform for deletion. | |
Schedules this space platform for deletion. | ||
cancel_deletion() | Cancels deletion of this space platform if it was scheduled for deletion. | |
Cancels deletion of this space platform if it was scheduled for deletion. | ||
apply_starter_pack() | → LuaEntity? | Applies the starter pack for this platform if it hasn't already been applied. |
Applies the starter pack for this platform if it hasn't already been applied. | ||
damage_tile{position=…, damage=…, cause?=…} | Damages the given tile if it exists, the chunk is generated, and it is a platform foundation tile. | |
Damages the given tile if it exists, the chunk is generated, and it is a platform foundation tile. | ||
repair_tile(position, amount?) | Repairs the given tile if it's damaged. | |
Repairs the given tile if it's damaged. | ||
destroy_asteroid_chunks{area?=…, position?=…, name?=…, limit?=…, invert?=…} | Destroys all asteroid chunks from the given area. [...] | |
Destroys all asteroid chunks from the given area. [...] | ||
create_asteroid_chunks(asteroid_chunks) | Creates the given asteroid chunks on this platform. | |
Creates the given asteroid chunks on this platform. | ||
find_asteroid_chunks_filtered{area?=…, position?=…, name?=…, limit?=…, invert?=…} | → array[AsteroidChunk] | Find asteroid chunks of a given name in a given area. [...] |
Find asteroid chunks of a given name in a given area. [...] | ||
force | :: R LuaForce | The force of this space platform. |
The force of this space platform. | ||
name | :: RW string | The name of this space platform. |
The name of this space platform. | ||
index | :: R uint | The unique index of this space platform. |
The unique index of this space platform. | ||
space_location | :: R LuaSpaceLocationPrototype? | The space location this space platform is stopped at or |
The space location this space platform is stopped at or | ||
last_visited_space_location | :: R LuaSpaceLocationPrototype? | The space location this space platform previously went through or stopped at. |
The space location this space platform previously went through or stopped at. | ||
state | :: R defines.space_platform_state | The current state of this space platform. |
The current state of this space platform. | ||
paused | :: RW boolean | When |
When | ||
starter_pack | :: R ItemIDAndQualityIDPair? | The starter pack used to create this space platform. |
The starter pack used to create this space platform. | ||
surface | :: R LuaSurface | The surface that belongs to this platform (if it has been created yet). |
The surface that belongs to this platform (if it has been created yet). | ||
hub | :: R LuaEntity? | The hub on this platform. [...] |
The hub on this platform. [...] | ||
schedule | :: RW PlatformSchedule? | This platform's current schedule, if any. [...] |
This platform's current schedule, if any. [...] | ||
speed | :: RW double | |
scheduled_for_deletion | :: R uint | If this platform is scheduled for deletion. [...] |
If this platform is scheduled for deletion. [...] | ||
weight | :: R uint | The total weight of the platform. |
The total weight of the platform. | ||
damaged_tiles | :: R array[table] | The damaged tiles on this platform. |
The damaged tiles on this platform. | ||
valid | :: R boolean | Is this object valid? [...] |
Is this object valid? [...] | ||
object_name | :: R string | The class name of this object. [...] |
The class name of this object. [...] |
ticks | :: uint? | The number of ticks from now when this platform will be deleted. |
The number of ticks from now when this platform will be deleted. |
position | :: TilePosition | |
damage | :: float | |
cause | :: LuaEntity? |
area | :: BoundingBox? | |
position | :: MapPosition? | |
name | :: AsteroidChunkID or array[AsteroidChunkID]? | |
limit | :: uint? | |
invert | :: boolean? | If the filters should be inverted. |
If the filters should be inverted. |
area | :: BoundingBox? | |
position | :: MapPosition? | |
name | :: AsteroidChunkID or array[AsteroidChunkID]? | |
limit | :: uint? | |
invert | :: boolean? | If the filters should be inverted. |
If the filters should be inverted. |
game.surfaces[1].find_asteroid_chunks_filtered{area = {{-10, -10}, {10, 10}}, name = "carbonic-asteroid"} -- gets all asteroids with the given name in the rectangle
game.surfaces[1].find_asteroid_chunks_filtered{area = {{-10, -10}, {10, 10}}, limit = 5} -- gets the first 5 asteroid chunks in the rectangle