Difference between revisions of "Plugin API"

From Mineserver Wiki
Jump to navigation Jump to search
==Available functions==
==Available functions==
−
 
−
 
===Mineserver===
===Mineserver===
 
====Map====
====Map====
−
+
{{APIFunct6|createPickupSpawn|x|int|x-coordinate|y|int|y-coordinate|z|int|z-coordinate|conut|int|How many to spawn(1-64)|health|int|item health. 0 is max health, max value depends on the item|user|const char*|Username|void|Spawns an item at (x,y,z) with type,count and health specified. If "user" is set, he will not be able to pick up the item right away to make it possible to throw stuff away.}}
−
{| class="wikitable"
 
−
|- class="row0"
 
−
! class="col0" | Function
 
−
! class="col1" | Parameter name
 
−
! class="col2" | Parameter type
 
−
! class="col3" | Parameter info
 
−
|- class="row1"
 
−
| class="col0" rowspan="6" | '''createPickupSpawn'''
 
−
| class="col1" | x
 
−
| class="col2" | int
 
−
| class="col3" | x-coordinate
 
−
|- class="row2"
 
−
| class="col1" | y
 
−
| class="col2" | int
 
−
| class="col3" | y-coordinate
 
−
|- class="row3"
 
−
| class="col1" | z
 
−
| class="col2" | int
 
−
| class="col3" | z-coordinate
 
−
|- class="row4"
 
−
| class="col1" | count
 
−
| class="col2" | int
 
−
| class="col3" | How many to spawn (1-64)
 
−
|- class="row4"
 
−
| class="col1" | health
 
−
| class="col2" | int
 
−
| class="col3" | item health (0 = full health, max value depends on the item)
 
−
|- class="row5"
 
−
| class="col1" | user
 
−
| class="col2" | const char*
 
−
| class="col3" | Username
 
−
|- class="row6"
 
−
! class="col0" | Return value
 
−
| class="col1 rightalign" colspan="3" | void
 
−
|- class="row7"
 
−
| class="col0" colspan="4" | Spawns an item at (x,y,z) with type,count and health specified. If "user" is set, he will not be able to pick up the item right away to make it possible to throw stuff away.
 
−
|}
 
−
 
−
{| class="wikitable"
+
{{APIFunct1|setTime|timeValue|int|value between 0 and 2400|bool|Sets server time to ''timeValue''}}
−
|- class="row0"
 
−
! class="col0" | Function
 
−
! class="col1" | Parameter name
 
−
! class="col2" | Parameter type
 
−
! class="col3" | Parameter info
 
−
|- class="row1"
 
−
| class="col0" rowspan="1" | '''setTime'''
 
−
| class="col1" | timeValue
 
−
| class="col2" | int
 
−
| class="col3" | value 0-24000
 
−
|- class="row2"
 
−
! class="col0" | Return value
 
−
| class="col1 rightalign" colspan="3" | bool
 
−
|- class="row3"
 
−
| class="col0" colspan="4" | Sets server time to timeValue, which can be in range 0-24000
 
−
|}
 
{| class="wikitable"
{| class="wikitable"