summaryrefslogtreecommitdiffstats
path: root/Server
diff options
context:
space:
mode:
authorLane Kolbly <lane@rscheme.org>2017-07-12 12:13:27 +0200
committerLukas Pioch <lukas@zgow.de>2017-07-12 12:13:27 +0200
commit793acd267f4a5801e2aa9e9dca7cf51c5a595a02 (patch)
tree0e2740c09bfbbff7fb297f990ecca1b0090ddcc3 /Server
parentIf entity is a player, send relmove packets. (diff)
downloadcuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar.gz
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar.bz2
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar.lz
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar.xz
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.tar.zst
cuberite-793acd267f4a5801e2aa9e9dca7cf51c5a595a02.zip
Diffstat (limited to 'Server')
-rw-r--r--Server/Plugins/APIDump/APIDesc.lua42
-rw-r--r--Server/Plugins/APIDump/Classes/World.lua60
2 files changed, 102 insertions, 0 deletions
diff --git a/Server/Plugins/APIDump/APIDesc.lua b/Server/Plugins/APIDump/APIDesc.lua
index ce0390947..65ae69144 100644
--- a/Server/Plugins/APIDump/APIDesc.lua
+++ b/Server/Plugins/APIDump/APIDesc.lua
@@ -9260,6 +9260,16 @@ a_Player:OpenWindow(Window);
]],
Functions =
{
+ CanCombine =
+ {
+ Returns =
+ {
+ {
+ Type = "boolean"
+ }
+ },
+ Notes = "Returns whether this pickup is allowed to combine with other similar pickups.",
+ },
CollectedBy =
{
Params =
@@ -9298,6 +9308,16 @@ a_Player:OpenWindow(Window);
},
Notes = "Returns the item represented by this pickup",
},
+ GetLifetime =
+ {
+ Returns =
+ {
+ {
+ Type = "number",
+ },
+ },
+ Notes = "Returns the total length of this pickup's lifespan, in ticks.",
+ },
IsCollected =
{
Returns =
@@ -9329,6 +9349,28 @@ a_Player:OpenWindow(Window);
},
Notes = "Sets the pickup's age, in ticks.",
},
+ SetCanCombine =
+ {
+ Params =
+ {
+ {
+ Name = "CanCombine",
+ Type = "boolean",
+ },
+ },
+ Notes = "Sets whether this pickup is allowed to combine with other similar pickups.",
+ },
+ SetLifetime =
+ {
+ Params =
+ {
+ {
+ Name = "LifeTimeInTicks",
+ Type = "number",
+ },
+ },
+ Notes = "Sets the total lifespan of this pickup before it despawns, in ticks. Does not reset the age of the pickup, use SetAge(0). If new lifetime is less than the current age, pickup will despawn.",
+ },
},
Inherits = "cEntity",
},
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()</pre> 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 =
{
{