From d9a5554c4bc5d9fef1bd3bed0061b1e3d84ef259 Mon Sep 17 00:00:00 2001 From: Kleopatra Angelidi Date: Mon, 22 Apr 2013 23:34:13 +0300 Subject: fixed description --- weatbag/tiles/n2w4.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 weatbag/tiles/n2w4.py (limited to 'weatbag') diff --git a/weatbag/tiles/n2w4.py b/weatbag/tiles/n2w4.py new file mode 100644 index 0000000..961409a --- /dev/null +++ b/weatbag/tiles/n2w4.py @@ -0,0 +1,20 @@ +from weatbag import words +from weatbag.utils import transfer + + +class Tile: + def describe(self): + print("You are standing in front of the hut.\nIt has a door but you " + "can't open it because the doorknob is missing.") + + def action(self, player, do): + if (do[0] in words.use) and do[1]=='doorknob': + if player.has('doorknob'): + player.give('doorknob') + print("Doorknob fits fine, clicks and voila! Door is open!") + else: + print("You'll need a doorknob to open the door.") + else: + print("Sorry, I don't understand.") + +test_items = ['doorknob'] -- cgit v1.3