Mercurial > Kubik
changeset 115:f79b9703f37e
nicer creep
| author | Radomir Dopieralski <sheep-devel@sheep.art.pl> |
|---|---|
| date | Sun, 06 Jul 2014 20:19:57 +0000 |
| parents | 7166833e2414 |
| children | 84a6ec24a915 |
| files | creep.py |
| diffstat | 1 files changed, 8 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/creep.py Sun Jul 06 21:41:18 2014 +0200 +++ b/creep.py Sun Jul 06 20:19:57 2014 +0000 @@ -4,12 +4,12 @@ STRIDE = 42 SPEED = 1 -SWING = 12 -SWING_SPEED = 3 -SPREAD = 40 +SWING = 18 +SWING_SPEED = 2 +SPREAD = 30 HEIGHT = -30 STEP = -10 -FPS = 40 +FPS = 24 def swing(robot): @@ -54,10 +54,10 @@ delay = (2 * STRIDE / SPEED + 6) / 4 animations = [ swing(robot), - creep(robot.legs[0], 1, 0, robot), - creep(robot.legs[1], 1, delay, robot), - creep(robot.legs[3], -1, delay * 2, robot), - creep(robot.legs[2], -1, delay * 3, robot), + creep(robot.legs[0], 1, delay * 0 + 4, robot), + creep(robot.legs[1], 1, delay * 1 - 4, robot), + creep(robot.legs[3], -1, delay * 2 + 4, robot), + creep(robot.legs[2], -1, delay * 3 - 4, robot), ] robot.home() try:
