|
Your time now: Mon Nov 23, 2009 4:37 pm
|
View unanswered posts | View active topics
| Author |
Message |
|
itendsnow
|
Post subject: Maze Solving Techniques Posted: Wed Apr 18, 2007 1:26 pm |
|
Joined: Wed Apr 18, 2007 1:24 pm Posts: 0
|
|
I'm wanting some help with regards to what is possible in java.
I'm writing a mouse than can solve a 2D maze, 16*16 cells. I'm wanting to make sure the mouse can explore the maze and then solve it based on all the routes its found. I figured I could use the faster flood algorithm once I have solved the maze since that would be allowed given I have aquired all the data. I was wondering if any one knew how I could get my mouse to explore the maze fully, recognise that fact and if it say could explore as far as it could make it follow a path back to the start of it finished search? I guess I'd have to use arrays and maybe stacks to implement this.
Any code snippets/ideas would help so I could visualise the actual code and how to start writing it.
|
|
| Top |
|
 |
|
ggomez
|
Post subject: You can try this Posted: Wed Apr 18, 2007 9:25 pm |
|
Joined: Tue Apr 17, 2007 4:30 am Posts: 45 Location: !!!!!MéXiCo¡¡¡¡¡¡
|
|
mmm....
make one mouse class with a draw method ( something like draw(Graphic g) )
that way the mouse object can draw itself, in that class you can put some methods like location,move, etc.
Then you can draw the maze and add the mouse object, you can use the method of the mouse class to control it.
well thats somes graphics advices,
i´ll see if i can get some code.
good luck
|
|
| Top |
|
 |
|
Page 1 of 1
|
[ 2 posts ] |
|
Who is online |
Users browsing this forum: No registered users and 0 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|
|