From 793acd267f4a5801e2aa9e9dca7cf51c5a595a02 Mon Sep 17 00:00:00 2001 From: Lane Kolbly Date: Wed, 12 Jul 2017 05:13:27 -0500 Subject: Changing pickup lifetime and combining semantics, making these adjustable in the lua api. (#3843) --- Server/Plugins/APIDump/Classes/World.lua | 60 ++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) (limited to 'Server/Plugins/APIDump/Classes') diff --git a/Server/Plugins/APIDump/Classes/World.lua b/Server/Plugins/APIDump/Classes/World.lua index 429d32ed6..e452db2ff 100644 --- a/Server/Plugins/APIDump/Classes/World.lua +++ b/Server/Plugins/APIDump/Classes/World.lua @@ -3009,6 +3009,66 @@ function OnAllChunksAvailable() All return values from the callbacks are i }, Notes = "Spawns a {{cFallingBlock|Falling Block}} entity at the specified coords with the given block type/meta. Returns the EntityID of the new falling block, or {{cEntity#INVALID_ID|cEntity#INVALID_ID}} if no falling block was created.", }, + SpawnItemPickup = + { + Params = + { + { + Name = "PosX", + Type = "number", + }, + { + Name = "PosY", + Type = "number", + }, + { + Name = "PosZ", + Type = "number", + }, + { + Name = "Item", + Type = "cItem", + }, + { + Name = "SpeedX", + Type = "number", + IsOptional = true, + Notes = "Speed along X coordinate to spawn with. Default is 0.", + }, + { + Name = "SpeedY", + Type = "number", + IsOptional = true, + Notes = "Speed along Y coordinate to spawn with. Default is 0.", + }, + { + Name = "SpeedZ", + Type = "number", + IsOptional = true, + Notes = "Speed along Z coordinate to spawn with. Default is 0.", + }, + { + Name = "LifetimeTicks", + Type = "number", + IsOptional = true, + Notes = "Length of the pickups lifetime, in ticks. Default 5 minutes (6000 ticks)", + }, + { + Name = "CanCombine", + Type = "boolean", + IsOptional = true, + Notes = "Whether this pickup is allowed to combine with other similar pickups.", + }, + }, + Returns = + { + { + Name = "EntityID", + Type = "number", + } + }, + Notes = "Creates a single pickup entity of the given item at the given position with the given speed, and returns the entities unique ID." + }, SpawnItemPickups = { { -- cgit v1.2.3