Drink verb and keep container/cup?

NecroDeath
13 Sept 2016, 20:22

Complete noob here, I want to create a glass of wine, player can drink wine (once) but also keep the glass. I can create the verb drink but how do I make the wine in glass disappear/change the description in the inventory when they drink? Any help appreciated!


The Pixie
13 Sept 2016, 21:33

See here:
http://pixie-if.blogspot.co.uk/p/handling-water.html


NecroDeath
13 Sept 2016, 22:11

thanks!


Father
14 Sept 2016, 18:08

You could have an empty cup object set to invisible in the players inventory. When you drink the cup of water set the empty to visible and set full to invisible.


NecroDeath
14 Sept 2016, 18:23

Yes I went for that solution in end, when you drink the wine the glass of wine disappears from your inventory and i replaced by empty glass (moved from 'game' objects)