Plan main:
    Execute go_to(grey_door)
    Execute toggle
    Execute go_to(red_key)
    Execute pickup
    Execute go_to(red_door)
    Execute toggle

Effect main:
    if at(grey_door) and not in_inventory(red_key):
        Reward 1

#Effect old:
#    if A == forward and at_any(Wall):
#        Reward -1
#    if A == forward and agent.dir == pointing_right:
#        agent.x' -> agent.x + 1
#        S' -> S
#    if A == forward and agent.dir == pointing_left:
#        agent.x' -> agent.x - 1
#        S' -> S
#    if A == forward and agent.dir == pointing_up:
#        agent.y' -> agent.y - 1
#        S' -> S
#    if A == forward and agent.dir == pointing_down:
#        agent.y' -> agent.y + 1
#        S' -> S
#    if A == pickup and at(green_key):
#        Reward 0.5
#    if A == toggle and at(green_door) and in_inventory(green_key):
#        Reward 0.5
#    if A == go_to and at(goal):
#        Reward 1