Play Home Contribute Github Join Us! Discourse Staff Members Github Contribution Guides Team

The Prisoner help for Python

Hello. I am having trouble with The Prisoner level. I am using Python. I am using a DeKalb county Chromebook (if that effects anything). I don’t get any errors running the code, but I’m having trouble beating the level. I am only using my unlocked code. I have hero.attack(“target”), hero.moveLeft(), hero.moveRight(), hero.moveUp(), hero.moveDown(), and hero.say(message). I cannot get past line 7 in my code before I die. My code is below

# Free the prisoner, defeat the guard and grab the gem.
# Defeat the guard, named "Two".
# Free Patrick from behind the "Weak Door".
hero.moveRight()
hero.attack("Weak Door")
hero.moveRight(3)
hero.moveDown (2)
hero.moveUp(1)
hero.moveLeft(2)
hero.moveRight()
hero.moveLeft(3)
# Get the gem.
hero.moveRight(4)
hero.moveDown(3)
hero.moveRight()
1 Like

Howdy Angeline and welcome to the forum!

Patrick is an archer, so can be of assistance in taking out Two. Try attacking Two once to distract him, then go for the gem. You should be able to complete the level with only 6 lines of code.