dwlerwill
Technical User
- May 25, 2001
- 329
Hi All
I am making a game in VB and it is 90% completed but I am stuck on one aspect.
The movement, I want to move the players position from one square to another square on the board each square has a grid reference and they enter the square they want to move from and to and it moves them one square at a time to the destination.
The problem is the only way I can work out how to do this is via hundereds of case statments.
Sample of what I want to do.
Imagine this is a sample map
50
40 E
30
20
10 S
01 02 03 04 05
The start is square 1001 and the end is 4004
What would you guys think is the best way to move the person 1 square at a time to the End via the quickest route?
I know this is probably a bizarre and badly worded question but any help would be very welcome
David Lerwill
"If at first you don't succeed go to the pub"
I am making a game in VB and it is 90% completed but I am stuck on one aspect.
The movement, I want to move the players position from one square to another square on the board each square has a grid reference and they enter the square they want to move from and to and it moves them one square at a time to the destination.
The problem is the only way I can work out how to do this is via hundereds of case statments.
Sample of what I want to do.
Imagine this is a sample map
50
40 E
30
20
10 S
01 02 03 04 05
The start is square 1001 and the end is 4004
What would you guys think is the best way to move the person 1 square at a time to the End via the quickest route?
I know this is probably a bizarre and badly worded question but any help would be very welcome
David Lerwill
"If at first you don't succeed go to the pub"