#plane of fire treasure 1
from eventAPI import *
from APIUtils import *

rtpofireTreasure1=0

def fireEvent(e):
   global rtpofireTreasure1
   rtpofireTreasure1 = getTag(e, "rtpofireTreasure1")
   rtpofireTree = getTag(e, "rtpofireTree")
   if (rtpofireTreasure1 == 1):
      return 1
   elif (rtpofireTree == 4):
      showMessage(e, ["Just as you were told, you find a small cache buried in the ash.", "", "The contents are singed, but still intact."])
      chest(e, -1, 0, 0, ["Redwood Staff"], dice(1, 4, 1), "Treasure")
      rtpofireTreasure1 = 1
      setTag(e, "rtpofireTreasure1", rtpofireTreasure1)
   else:
      return 1