Continuous Alchemy help - Python

Hello,

I’ve been having some trouble lately with continuous alchemy lately. My hero doesn’t get to the water fast enough. here is my code:

# Race munchkins to the water distilled by Omarn Brewstone!
# Use the `continue` statement to avoid poison.
while True:
    enemy = hero.findNearestEnemy()
    item = hero.findNearestItem()
    
    # If there is no enemy, continue out of the loop.
    if not enemy:
        continue
    
    # If there is no item, ask for a potion then continue:
    if not item:
        hero.say("Give me a drink!")
        continue
    
    # If the item.type "poison", continue out of the loop.
    if item.type == "poison":
        continue
    # At this point, the potion must be a bottle of water
    # so moveXY to the potion, then back to the start!
    hero.moveXY(item.pos.x, item.pos.y)
    hero.moveXY(34, 47)

Thanks!

1 Like

Hi @S_T and welcome back to the forum! :partying_face:

Can you show me your equipment, because nothing seems wrong with the code itself.

Andrei

As I thought. Try to do the level without the ring of speed because with it the code will not work.

Andrei

1 Like

Or try to get better boots if you have the gems.

Andrei

1 Like

This topic was automatically closed 12 hours after the last reply. New replies are no longer allowed.

Also instead of moving to the item’s position, move to the x mark close to Omarn. That might be slowing you down

2 Likes

And that heavy iron breastplate too even though you have the ring of speed

1 Like