Time

Version 9 (vl, 04/24/2009 02:48 pm)

1 9 vl
h1. Time
2 1 vl
3 9 vl
This Ryzom API get the time in the game servers (shards).
4 9 vl
5 1 vl
h2. Base URL
6 1 vl
7 9 vl
* http://atys.ryzom.com/api/time.php
8 6 vl
9 9 vl
h2. URL Parameters
10 1 vl
11 9 vl
h3. @shardid@
12 1 vl
13 9 vl
The id of the shard. Can be @ani@, @lea@ or @ari@.
14 1 vl
15 9 vl
h3. @format@ (optional) 
16 1 vl
17 9 vl
Default @format@ is @raw@.
18 1 vl
19 9 vl
* @raw@: Returns the tick. The server tick is a 32 bit integer that increase by one every 100 milliseconds ("example":http://atys.ryzom.com/api/time.php?shardid=ani&format=raw).
20 9 vl
* @txt@: Returns a string that is the time that is homine readable ("example":http://atys.ryzom.com/api/time.php?shardid=ani&format=txt).
21 9 vl
* @xml@: Returns an xml file that contains all shard time information ("example":http://atys.ryzom.com/api/time.php?shardid=ani&format=xml).
22 1 vl
23 9 vl
h2. Cache Duration
24 1 vl
25 9 vl
The data is cached during *1 minute*.
26 1 vl
27 9 vl
h2. PHP Interface
28 1 vl
29 9 vl
h3. @ryzom_time_tick($shardid)@
30 9 vl
31 9 vl
Returns the tick of the shard identified by @$shardid@.
32 9 vl
33 9 vl
h3. @ryzom_time_txt($rytime)@
34 9 vl
35 9 vl
@$rytime@ is the array returned by @ryzom_time_array@.
36 9 vl
Returns the time in homine readable string.
37 9 vl
38 9 vl
h3. @ryzom_time_xml($rytime)@
39 9 vl
40 9 vl
@$rytime@ is the array returned by @ryzom_time_array@.
41 9 vl
Returns the time in an xml format.
42 9 vl
43 9 vl
h3. @ryzom_time_array($tick, $shardid)@
44 9 vl
45 9 vl
Creates and returns an array containing all information about the time.
46 9 vl
47 1 vl
h2. Real Examples
48 1 vl
49 9 vl
If you have a website that use this Ryzom API, tell it in the forum and we'll add it.