Continuous Alchemy


Hello I started this code combat 6 month ago, and I am stuck in Continuous Alchemy . My code is this.
enemy = self.findNearest(self.findEnemies())
item = self.findNearest(self.findItems())

if not enemy:
    self.say("I see an enemy!")

#If there is an enemy, but no item, ask for a potion and continue out of the loop.
if not item:
    self.say("Give me a drink!")

#Use an if-statement to check the item's type. If the type is "poison", continue out of the loop.
if item.type is "poison":

Help Me!!!
Can someone show me the code?


No, we do not post correct code. That would take away the point of the game.

To format your code correctly, please highlight all of it before clicking the </> button.

Could you be a bit more specific? What problem are you experiencing?

One thing I notice is that you have no code for actually taking action. What will you do if there is an enemy and a potion and the potion is not poison?