64
edits
*>Ashen No edit summary |
|||
(3 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{deprecated}} | |||
==Getting rid of that big gray status bar at the top== | ==Getting rid of that big gray status bar at the top== | ||
''When I test my game, there is this gray box at the very top of the screen that I can't get rid of. I don't want it there. What is it, and how do I get rid of it?'' | ''When I test my game, there is this gray box at the very top of the screen that I can't get rid of. I don't want it there. What is it, and how do I get rid of it?'' | ||
Line 93: | Line 95: | ||
''How would I go about creating my own custom inventory GUI? I don't much like the default AGS one. OR, I have a problem creating my own inventory GUI. HELP!'' | ''How would I go about creating my own custom inventory GUI? I don't much like the default AGS one. OR, I have a problem creating my own inventory GUI. HELP!'' | ||
Everything you need to know about custom inventory GUIs can be found in [http://www. | Everything you need to know about custom inventory GUIs can be found in [http://www.adventuregamestudio.co.uk/forums/index.php?topic=10946.0 this thread]. | ||
==Inventory items don't show up== | ==Inventory items don't show up== | ||
Line 180: | Line 182: | ||
''I want an interaction to happen only when the player has an Inventory Item (like a key to open a door) OR something not to happen when the player has an Item. How do I do that?'' | ''I want an interaction to happen only when the player has an Inventory Item (like a key to open a door) OR something not to happen when the player has an Item. How do I do that?'' | ||
Simply use the [http://www. | Simply use the [http://www.adventuregamestudio.co.uk/manual/ags49.htm#character.inventoryquantity InventoryQuantity] property, e.g.: | ||
if (player.InventoryQuantity[iKey.ID] == 0) Display("You don't have the key."); | if (player.InventoryQuantity[iKey.ID] == 0) | ||
Display("You don't have the key."); | |||
Or: | Or: | ||
if (player.InventoryQuantity[iStolen.ID] != 0) Display("You can't go in there carrying Stolen goods."); | if (player.InventoryQuantity[iStolen.ID] != 0) | ||
Display("You can't go in there carrying Stolen goods."); | |||
If you want to stop the player from taking an Item multiple times (like taking someting out of a drawer), you're better using a variable. If you use InventoryQuantity and the player can lose the Item later in the game, they'll be able to go back and pick it up again. | If you want to stop the player from taking an Item multiple times (like taking someting out of a drawer), you're better using a variable. If you use InventoryQuantity and the player can lose the Item later in the game, they'll be able to go back and pick it up again. | ||
'''Note:''' | '''Note:''' | ||
* The InventoryQuantity property was introduced in V2.7. Before that, use | * The InventoryQuantity property was introduced in V2.7. Before that, use the ''character[].inv'' array. | ||
[[Category:AGS Beginners' FAQ]] | [[Category:AGS Beginners' FAQ]] |
edits