Template:ItemBox: Difference between revisions

m Added some more examples
m removed active and componentOf params from docs, as they are no longer used
Line 39: Line 39:


A port of the initial box in [[Template:Infobox item]] with links, for use on pages that could use it without the whole infobox.
A port of the initial box in [[Template:Infobox item]] with links, for use on pages that could use it without the whole infobox.
All data for each item is populated using data from [[Data:ItemData.json]]


{{ItemBox|item_name = Basic Magazine}}  
{{ItemBox|item_name = Basic Magazine}}  
Line 60: Line 62:
"description": "The display name of the item (for special cases such as Bullet Lifesteal (item) or Spirit Lifesteal (item))",
"description": "The display name of the item (for special cases such as Bullet Lifesteal (item) or Spirit Lifesteal (item))",
"example": "Bullet Lifesteal",
"example": "Bullet Lifesteal",
"type": "string"
},
"componentOf": {
"description": "The name of the item this is a component of, for linking",
"example": "Headhunter",
"type": "string"
"type": "string"
},
},
Line 81: Line 78:
"example": "500",
"example": "500",
"type": "number"
"type": "number"
},
"active": {
"description": "Overrides default item active status. See Module:ItemData",
"example": "true",
"type": "boolean"
}
}
},
},
Line 91: Line 83:
"item_name",
"item_name",
         "display_name",
         "display_name",
        "componentOf",
"item_type",
"item_type",
"item_price",
"item_price"
"active"
]
]
}
}
</templatedata>
</templatedata>
</noinclude>
</noinclude>