A* Into 3D Terrain.
Hi, I have made an 3D terrain and now I whant to insert an
PathFinding of some sort, first I have think about using the A*.
Allright I whant it to do this, I have an object in this case
it is a stone on the left side on the terrain..
Now I whant the stone to move to the right side and search the
best way to reach its goal(the right side), but it cant just
take the straight way over the hills if you know what I meen,
how do it setup the pathfinding on an terrain if I whant this to work?
I have not to god knowledge about pathfinding so were can I find
something about this?
is there any examples out there source/tutorials?
hope someone can point me somewere.
Edit : I use 3D - OpenGL.
Thanks.
-[ thx ]-
There are some decent articles here at Gamedev about A* in the Articles -> Programming -> Artificial Intelligence section.
Quote: Original post by X5-ProgrammerGood thought, but pathfinding doesn't have anything to do with what 3d api you're using. It's only concerned with data structures.
Edit : I use 3D - OpenGL.
I'm just pointing this out to get rid of this confusion early. We had one poor fellow in here once that just couldn't get it through his head that pathfinding didn't care about how he was drawing stuff to the screen.
C-Junkie:
I have got this question 1000 times... What do you use opengl or directX, 2D or 3D so now I always say what I use...
I Know that pathfinding doesn't have anything with 3d api..
I have got this question 1000 times... What do you use opengl or directX, 2D or 3D so now I always say what I use...
I Know that pathfinding doesn't have anything with 3d api..
-[ thx ]-
Hi,
A quick google search will give you tons of infos on how to use / implement A*.
Check out the articles here on GameDev and check out James Matthews' Generation5.org website. He has a sweet "A* explorer" with code provided, so you can easily learn from that.
Cheers
Eric
A quick google search will give you tons of infos on how to use / implement A*.
Check out the articles here on GameDev and check out James Matthews' Generation5.org website. He has a sweet "A* explorer" with code provided, so you can easily learn from that.
Cheers
Eric
Hi there!
In my pathfinding I've used a cost for each "tile"... for instance; it´s cheaper to travel downhill (if the angle from the previous is within the allowed travel angle for the unit), and more expensive to go uphill.
Normal, flat ground = 5 points
Height difference = -+ up to 5 points
Type of Terrain = + up to 5 points.
Then simply do A* as normal.
This would make a unit for instance skip a high hill path if there's another, less demanding path... OR if there's a paved road through the hills, he would then take that path.
This works GREAT! :)
Hope it helps!
Regards;
Robert
In my pathfinding I've used a cost for each "tile"... for instance; it´s cheaper to travel downhill (if the angle from the previous is within the allowed travel angle for the unit), and more expensive to go uphill.
Normal, flat ground = 5 points
Height difference = -+ up to 5 points
Type of Terrain = + up to 5 points.
Then simply do A* as normal.
This would make a unit for instance skip a high hill path if there's another, less demanding path... OR if there's a paved road through the hills, he would then take that path.
This works GREAT! :)
Hope it helps!
Regards;
Robert
"Game Maker For Life, probably never professional thou." =)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement