Self learning automated movement
- by Super1
I am trying to make a small demo in Javascript,
I have a black border and a car the car travels randomly and a line is drawn of its trail. When the user click inside the area it creates an object (we'll call this the wall). If the car hits the wall then it goes back 3 paces and tries a different route. When its hit the wall it needs to log down its location so it does NOT make that mistake again.
Here is my example:
http://jsfiddle.net/Jtq3E/
How can I get the car to move by itself and create a trail?