stage.set_axis(8)
stage.create_grid_overlay(1, "black")
# guide_pt = codesters.Point(-4, -6)
# guide_pt.set_color("purple")
# guide_pt.set_opacity(.7)
# guide_pt.say("\n\nI'm the goal!")
sprite = codesters.Point(0, 0)
sprite.set_color("green")
sprite.set_size(1.5)
sprite.glide_to(-6 -4)
try:
tval1 = sprite.get_x()
tval2 = sprite.get_y()
except:
tval1 = "DNE"
tval2 = "DNE"
t1 = TestObjective()
t1.add_success(tval1 == -6 and tval2 == -4, "Great job debugging the program!")
t1.add_failure(tval1 == "DNE" or tval2 == "DNE", "Oops! Did you delete your sprite?")
t1.add_failure(tval1 == 0 and tval2 == 0, "Oops! Did you delete the Glide To command?")
t1.add_failure(tval1 != -6 or tval2 != -4, "Make sure you fix the Glide To command so your sprite goes to (-6, -4)!")
tester = TestManager()
tester.add_test_list([t1])
tester.run_tests()
tester.display_first_feedback()