#Lair level 3 entrance
from eventAPI import *
from APIUtils import *

lair3Gate = 0

def fireEvent(e):
    global lair3Gate
    lair3Gate = getTag(e, "lair3Gate")
    if(not lair3Gate):
        showMessage(e,
            ["From out of the ether, a disembodied voice poses a riddle"])
        answer = stringInput(e,
            ["All about you, but never seen",
             "Its gentle caress makes the grass lean.",
             "A gentle zephyr or mighty squall",
             "This element has the respect of all.",
             "From smallest ant to greatest bear",
             "All must take a breath of..."])
        if (answer.lower() != "air"):
            return 0
        else:
            lair3Gate = 1
            setTag(e, "lair3Gate", lair3Gate)
    showPicture(e, "Cave")
    if (poseYesNo(e,
        ["You see before you leading up into the Lair.",
         "Do you enter?"])):
        tickGame(e, 60)
        setExit(e, "maps/lair3.cfg", 18, 5, 180)
    return 0
