Dynamic A* Pathfinding 3.2

Advanced game related topics
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

tmyke wrote:on my Pentium IV 640 (3.02Ghz) - 1Mo RAM - NVidia 6800GT 256Mo :
FPS: 12/40
Validation time: 0 ms
Path generation time: 0 ms


on my Pentium M 1.7Ghz - 512Mo RAM - ATI 9700 Pro:
FPS: 15/40
Validation time: 0.108 ms
Path generation time: 0.004 ms


Very good code, I like much and congratulation.
:)
Thanks for testing! As I'm sure you can tell by the FPS, I'm having a heck of a time with finding a good ratio between FPS and cpu usage in the example, that would be good on all machines..
I love Purebasic.
tmyke
Enthusiast
Enthusiast
Posts: 132
Joined: Fri Sep 29, 2006 1:10 pm
Location: France

Post by tmyke »

It's not easy to find the good ratio.

For example, an important pathfinding in 3D game, it's then necessary to find a
divide CPU very fine.

therefore, each user must be define well the power CPU according
to the necessary resources.

;)
Strength and wisdom.
Image
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

tmyke wrote:It's not easy to find the good ratio.

For example, an important pathfinding in 3D game, it's then necessary to find a
divide CPU very fine.

therefore, each user must be define well the power CPU according
to the necessary resources.

;)
It's not the pathfinding which is using all of the cpu.. :P
Also, It already spreads the pathfinding over multiple frames already.
I love Purebasic.
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

Updated to 3.01, check the changelog.

Note: The fps problem in the example should be fixed.
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

Updated to 3.1, the ray functionality works again and added more optimizations. Please check the changelog.
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

Fixed a few bugs, some were pretty stupid bugs on my part, check the first post for updated code :)
I love Purebasic.
untune
User
User
Posts: 56
Joined: Sun Jul 06, 2008 10:07 pm
Location: Bolton, UK

Post by untune »

Line 82: Structure field not found: tilesize

Shame because i'm excited about this one! :D
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

I updated my first post with the proper code. Sorry about that.
I love Purebasic.
User avatar
thyphoon
Enthusiast
Enthusiast
Posts: 345
Joined: Sat Dec 25, 2004 2:37 pm

Post by thyphoon »

Very good job Heathen !

I have juste a Question. How can do to find path with "star Treck bridge" (yes i don't know the name for that :P ).
exemple

if you are on map(12,23) you have translate to map(57,32)

i use this in my game when i have many floor level like a building. When somebody go to ladder or staircases it's translate directly to the next floor.

I hope you understand my bad english!

best regards

Thy
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

thyphoon wrote:Very good job Heathen !

I have juste a Question. How can do to find path with "star Treck bridge" (yes i don't know the name for that :P ).
exemple

if you are on Block(12,23) you have translate to Block(57,32)

i use this in my game when i have many floor level like a building. When somebody go to ladder or staircases it's translate directly to the next floor.

I hope you understand my bad english!

best regards

Thy
Hello, I don't really understand your question, could you try rephrasing it?

edit: Do you mean teleporting from one tile to another?
I love Purebasic.
User avatar
thyphoon
Enthusiast
Enthusiast
Posts: 345
Joined: Sat Dec 25, 2004 2:37 pm

Post by thyphoon »

Heathen wrote: Hello, I don't really understand your question, could you try rephrasing it?
Yes ! I retry with a little picture
Image
I want to start in orange square and go to Yellow square

it's a Building with 2 floor.Green square are Ladder or Staircase

Do you understand what I say ?
Some case (ladder/staircase) are like magic door . if you go on your are translate in other case.

Do you understand my idea ? :P
Heathen
Enthusiast
Enthusiast
Posts: 498
Joined: Tue Sep 27, 2005 6:54 pm
Location: At my pc coding..

Post by Heathen »

yes, I understand now. Right now that isn't possible with the current engine, but I will look at my code and see how much work it would be to add it. I don't think it will be too hard to add.
Last edited by Heathen on Thu Aug 14, 2008 3:39 pm, edited 2 times in total.
I love Purebasic.
User avatar
thyphoon
Enthusiast
Enthusiast
Posts: 345
Joined: Sat Dec 25, 2004 2:37 pm

Post by thyphoon »

Heathen wrote:yes, I understand now. Right now that isn't possible with the current engine, but I will look at my code and see how much work it would be to add it. I don't think it will be too hard to add.
Thanks your are the best !! :D
User avatar
Rook Zimbabwe
Addict
Addict
Posts: 4322
Joined: Tue Jan 02, 2007 8:16 pm
Location: Cypress TX
Contact:

Post by Rook Zimbabwe »

I get an error on line 83

Structure Field not found : tilesize

I have both files... cut and pasted and saved in same place... correctly named too! :?

And I say don't let monsters use Magic Doors! :wink:

I changed that field name to TileHeight and now I get an error on line 87

Structure Field not found : alt_copymemory
Binarily speaking... it takes 10 to Tango!!!

Image
http://www.bluemesapc.com/
untune
User
User
Posts: 56
Joined: Sun Jul 06, 2008 10:07 pm
Location: Bolton, UK

Post by untune »

Rook Zimbabwe wrote:I get an error on line 83

Structure Field not found : tilesize

I have both files... cut and pasted and saved in same place... correctly named too! :?

And I say don't let monsters use Magic Doors! :wink:

I changed that field name to TileHeight and now I get an error on line 87

Structure Field not found : alt_copymemory
Same as I got, still get the same :?
Post Reply