|
|
||
|---|---|---|
| data | ||
| game.js | ||
| gameworld.js | ||
| index.html | ||
| old.html | ||
| pyodide-worker.js | ||
| readme.md | ||
| robot.js | ||
| sensor.js | ||
| todo.md | ||
readme.md
import robot import time
robot.move(0.00006) while True: if robot.get_sensors()[0]["hitpoint"]["x"] is not None: robot.turn(0.001) elif robot.get_sensors()[1]["hitpoint"]["x"] is not None: robot.turn(-0.001) else: robot.turn(0) time.sleep(0.1)