from eventAPI import *
from APIUtils import *

def fireEvent(e):
   if (getTag(e, "lFlagU") == 2):
      return 1
   elif (getTag(e, "lFlagU") == 0):
      showMessage(e, ["As you approach the queen, the many ants that were attending to her needs interpose themselves."])
      setTag(e, "lFlagU", 1)
   else:
      showMessage(e, ["Once again, you endeavor to take over the throne of the queendom of the giant ants."])
   cr = combat(e, [("Ant Queen", 1, 0, 40), ("Fire Ant", 9, 3, 30), ("Warrior Ant", 20, 5, 10)])
   if (cr == 1):
      showMessage(e, ["After executing the queen and her attendants, you strike a royal pose. This will likely impress the other ants roaming this burrow..."])
      setTag(e, "lFlagU", 2)
      return 1
   elif (cr == 3):
      showMessage(e, ["They slaughter you for your attempted regicide (as if they wouldn't have otherwise)."])
   else:  
      showMessage(e, ["You flee, oh yes you do, indeed you do!"])
      return 0

