ItemIcon

Version 4 (nimetu, 02/01/2014 08:59 pm)

1 1 vl
h1. ItemIcon
2 1 vl
3 1 vl
h2. Base URL
4 1 vl
5 3 nimetu
* http://api.ryzom.com/item_icon.php
6 1 vl
7 1 vl
h2. URL Parameters
8 1 vl
9 1 vl
h3. @sheetid@
10 1 vl
11 3 nimetu
It's the id of an item that you can find in the [[Character]] xml file. For example, @iczahp_3.sitem@ is a valid @sheetid@ (
12 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem!
13 1 vl
14 1 vl
h3. @c@ (optional)
15 1 vl
16 3 nimetu
The color of the item. It's a value between 0 and 7
17 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=0! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=1! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=2! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=3! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=4! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=5! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=6! !http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&c=7!
18 1 vl
19 1 vl
h3. @q@ (optional)
20 1 vl
21 3 nimetu
The quality of the item.
22 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&q=120!
23 1 vl
24 1 vl
h3. @s@ (optional)
25 1 vl
26 1 vl
Default is 1.
27 1 vl
28 3 nimetu
The size of the stack.
29 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&s=10!
30 1 vl
31 2 vl
h3. @sap@ (optional)
32 1 vl
33 1 vl
Default is -1.
34 1 vl
The number of sap of the item.
35 1 vl
36 3 nimetu
| -1 | No sap icon, no number | !http://api.ryzom.com/item_icon.php?sheetid=icfm2ms_3.sitem&c=-1&q=100&s=1&sap=-1! |
37 3 nimetu
| 0 | sap icon, no number | !http://api.ryzom.com/item_icon.php?sheetid=icfm2ms_3.sitem&c=-1&q=100&s=1&sap=0! |
38 3 nimetu
| 1 | sap icon number 0 | !http://api.ryzom.com/item_icon.php?sheetid=icfm2ms_3.sitem&c=-1&q=100&s=1&sap=1! |
39 3 nimetu
| 2 | sap icon number 1 | !http://api.ryzom.com/item_icon.php?sheetid=icfm2ms_3.sitem&c=-1&q=100&s=1&sap=2! |
40 3 nimetu
| 3 | sap icon number 2 | !http://api.ryzom.com/item_icon.php?sheetid=icfm2ms_3.sitem&c=-1&q=100&s=1&sap=3! |
41 1 vl
42 1 vl
h3. @destroyed@ (optional)
43 1 vl
44 1 vl
Default is @0@.
45 3 nimetu
* @0@: nothing special
46 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&destroyed=0!
47 3 nimetu
* @1@: display the item as if it was destroyed (with a red cross)
48 3 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&destroyed=1!
49 1 vl
50 4 nimetu
h2. @label@ (optional)
51 4 nimetu
52 4 nimetu
Default is @1@
53 4 nimetu
* @0@: hide icon text
54 4 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=m0021dxapd01.sitem&label=0!
55 4 nimetu
* @1@: draw text if sheet has one
56 4 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=m0021dxapd01.sitem&label=1!
57 4 nimetu
58 4 nimetu
h3. @locked@ (optional)
59 4 nimetu
60 4 nimetu
Default is @0@.
61 4 nimetu
* @0@: nothing special
62 4 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&locked=0!
63 4 nimetu
* @1@: display the item as if it was locked by the owner
64 4 nimetu
!http://api.ryzom.com/item_icon.php?sheetid=iczahp_3.sitem&locked=1!
65 4 nimetu
66 1 vl
h2. Cache Duration
67 1 vl
68 1 vl
It's cached for ever. Since the icon is unique and never change. For a specific icon, it'll always return the same image.
69 1 vl
70 1 vl
h2. PHP Interface
71 1 vl
72 4 nimetu
h3. @ryzom_item_icon_url($sheetid, $c=-1, $q=-1, $s=-1, $sap=-1, $destroyed=false, $label=true, $locked=false)@
73 1 vl
74 1 vl
Returns a string that contains the url to display a item icon.