-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
44 lines (34 loc) · 1.5 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
InfoApi V 0.1
Info Api provides a simple API for youre Bukkit Server. There may already plugins out there doing that. But this is mine, and because it works great i share it
Possible Api Querys:
http://server:25577/onlineplayer
http://server:25577/onlineplayer/WORLDNAME
http://server:25577/playerlist
http://server:25577/playerlist/WORLDNAME
http://server:25577/maxplayer
http://server:25577/temp/WORLDNAME (Temperature at Spawn )
http://server:25577/time/WORLDNAME
http://server:25577/onlinemode
http://server:25577/version
http://server:25577/say/text_to_say
http://server:25577/cmd/cmd_attribute_another
each request needs its secret key at the end like:
http://server:25577/version?secret
Config File
secret=secret # Youre Secret Key
port=25577 # The Port to use
opplayer=kingseta # Not used atm
name=&a[&bServer&a]&f # The Chat Name
enablechatlog=true # Not used atm
loglength=25 # Not used atm
Example Usage PHP:
$apiurl = "http://server:25577/onlineplayer"
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $apiurl);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_TIMEOUT, 1000);
$onlineplayer = curl_exec($ch);
echo $onlineplayer;
Please note: this Plugin will give an Error if you do /reload, because the API Server CAN'T get reloaded at the moment. Thats not really an problem, but you should know. Also there can be an Error on Shutdown... im sorry about that
If somebody knows how i could convert Minecraft Time to real time, please say