Skip to content

Commit

Permalink
APIDoc: Removed non-existent functions and added missing return types
Browse files Browse the repository at this point in the history
  • Loading branch information
Seadragon91 committed May 2, 2017
1 parent 74e6f41 commit f709f74
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 114 deletions.
72 changes: 12 additions & 60 deletions Server/Plugins/APIDump/APIDesc.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2128,6 +2128,12 @@ return
Type = "number",
},
},
Returns =
{
{
Type = "string",
},
},
Notes = "Returns the name of the sound that is played when placing the block of this type.",
},
GetSpreadLightFalloff =
Expand Down Expand Up @@ -2256,24 +2262,6 @@ return
},
Notes = "Returns whether a spectator can interact with the specified block.",
},
RequiresSpecialTool =
{
IsStatic = true,
Params =
{
{
Name = "BlockType",
Type = "number",
},
},
Returns =
{
{
Type = "boolean",
},
},
Notes = "Returns whether the specified block requires a special tool to drop resources.",
},
},
Variables =
{
Expand Down Expand Up @@ -5141,16 +5129,6 @@ local Hash = cCryptoHash.sha1HexString("DataToHash")
},
Notes = "Returns the roll (sideways rotation) of the entity. Currently unused.",
},
GetRot =
{
Returns =
{
{
Type = "Vector3f",
},
},
Notes = "(OBSOLETE) Returns the entire rotation vector (Yaw, Pitch, Roll)",
},
GetSpeed =
{
Returns =
Expand Down Expand Up @@ -5819,17 +5797,6 @@ local Hash = cCryptoHash.sha1HexString("DataToHash")
},
Notes = "Sets the roll (sideways rotation) of the entity. Currently unused.",
},
SetRot =
{
Params =
{
{
Name = "Rotation",
Type = "Vector3f",
},
},
Notes = "Sets the entire rotation vector (Yaw, Pitch, Roll)",
},
SetSpeed =
{
{
Expand Down Expand Up @@ -8559,6 +8526,12 @@ These ItemGrids are available in the API and can be manipulated by the plugins,
IsLoreEmpty =
{
Notes = "Returns if the lore of the cItem is empty.",
Returns =
{
{
Type = "boolean",
},
},
},
IsSameType =
{
Expand Down Expand Up @@ -12641,16 +12614,6 @@ a_Player:OpenWindow(Window);
},
Notes = "Returns the cPluginManager object.",
},
GetPrimaryServerVersion =
{
Returns =
{
{
Type = "number",
},
},
Notes = "Returns the servers primary server version.",
},
GetProtocolVersionTextFromInt =
{
IsStatic = true,
Expand Down Expand Up @@ -12752,17 +12715,6 @@ a_Player:OpenWindow(Window);
{
Notes = "Saves all the chunks in all the worlds. Note that the saving is queued on each world's tick thread and this functions returns before the chunks are actually saved.",
},
SetPrimaryServerVersion =
{
Params =
{
{
Name = "Protocol Version",
Type = "number",
},
},
Notes = "Sets the servers PrimaryServerVersion to the given protocol number.",
},
},
AdditionalInfo =
{
Expand Down
17 changes: 0 additions & 17 deletions Server/Plugins/APIDump/Classes/BlockEntities.lua
Original file line number Diff line number Diff line change
Expand Up @@ -622,12 +622,6 @@ World:ForEachChestInChunk(Player:GetChunkX(), Player:GetChunkZ(),
Type = "string",
},
},
Returns =
{
{
Type = "string",
},
},
Notes = "Sets the command",
},
},
Expand Down Expand Up @@ -760,17 +754,6 @@ World:ForEachChestInChunk(Player:GetChunkX(), Player:GetChunkZ(),
},
Notes = "Adjusts the block coords to where the dropspenser items materialize",
},
SetRedstonePower =
{
Params =
{
{
Name = "IsPowered",
Type = "boolean",
},
},
Notes = "Sets the redstone status of the dropspenser. If the redstone power goes from off to on, the dropspenser will be activated",
},
},
Constants =
{
Expand Down
70 changes: 33 additions & 37 deletions Server/Plugins/APIDump/Classes/World.lua
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,13 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
Type = "number",
},
},
Notes = "Replaces the specified block with air, without dropping the usual pickups for the block. Wakes up the simulators for the block and its neighbors.",
Returns =
{
{
Type = "boolean",
},
},
Notes = "Replaces the specified block with air, without dropping the usual pickups for the block. Wakes up the simulators for the block and its neighbors. Returns true on success, or false if the chunk is not loaded or invalid coords.",
},
DoExplosionAt =
{
Expand Down Expand Up @@ -1424,6 +1430,12 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
Type = "eWeather",
},
},
Returns =
{
{
Type = "number",
},
},
Notes = "Returns the default weather interval for the specific weather type. Returns -1 for any unknown weather.",
},
GetDimension =
Expand Down Expand Up @@ -2272,41 +2284,6 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
{
Notes = "Queues all chunks to be saved in the world storage thread",
},
QueueSetBlock =
{
Params =
{
{
Name = "BlockX",
Type = "number",
},
{
Name = "BlockY",
Type = "number",
},
{
Name = "BlockZ",
Type = "number",
},
{
Name = "BlockType",
Type = "number",
},
{
Name = "BlockMeta",
Type = "number",
},
{
Name = "TickDelay",
Type = "number",
},
},
Notes = [[
Queues the block to be set to the specified blocktype and meta after the specified amount of game
ticks. Uses SetBlock() for the actual setting, so simulators are woken up and block entities are
handled correctly.
]],
},
QueueTask =
{
Params =
Expand Down Expand Up @@ -2850,7 +2827,13 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
Type = "boolean",
},
},
Notes = "Opens or closes a trapdoor at the specific coordinates.",
Returns =
{
{
Type = "boolean",
},
},
Notes = "Opens or closes a trapdoor at the specific coordinates. Returns true on success, false if there is no trapdoor or it's already in the requested state.",
},
SetWeather =
{
Expand Down Expand Up @@ -3167,6 +3150,13 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
Type = "number",
},
},
Returns =
{
{
Name = "EntityID",
Type = "number",
},
},
Notes = "Spawns a {{cTNTEntity|primed TNT entity}} at the specified coords, with the given fuse ticks. The entity gets a random speed multiplied by the InitialVelocityCoeff, 1 being the default value.",
},
TryGetHeight =
Expand Down Expand Up @@ -3261,6 +3251,12 @@ function OnAllChunksAvailable()</pre> All return values from the callbacks are i
VillagersShouldHarvestCrops =
{
Notes = "Returns true if villagers can harvest crops.",
Returns =
{
{
Type = "boolean",
},
},
},
WakeUpSimulators =
{
Expand Down

0 comments on commit f709f74

Please sign in to comment.