This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
give_item [2020/02/19 09:16] – justin | give_item [2021/04/21 18:30] – justin | ||
---|---|---|---|
Line 2: | Line 2: | ||
---- | ---- | ||
- | Gives the specified item to the player. The ID of the item is case-sensitive and should match the name assigned to it in the [[item_editor|Item Editor]]. The item will be placed into the first open slot of the player' | + | Gives one or more of the specified |
====Signature: | ====Signature: | ||
<code python> | <code python> | ||
- | give_item(item_id, | + | give_item(item_id, |
</ | </ | ||
^Argument^Description^Type^Required^ | ^Argument^Description^Type^Required^ | ||
- | |item_id|ID of the item (as defined in the [[Item Editor]]).|[[String]]|Yes| | + | |item_id|ID of the [[item]] (as defined in the [[Item Editor]]).|[[String]]|Yes| |
- | |count|How many of the item to give to the player.|[[Number]]|No| | + | |count|How many of the [[item]] to give to the player |
====Example: | ====Example: | ||
Line 17: | Line 17: | ||
give_item(" | give_item(" | ||
</ | </ | ||
- | // | + | // |
<WRAP center round tip 100%> | <WRAP center round tip 100%> | ||
- | Use the **Give Item** function to reward the player for completing a quest or as a way of collecting items from treasure chests and other containers. | + | Use the **Give Item** function to reward the player for completing a quest or as a way of collecting |
</ | </ | ||