Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (494)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  A* (AStar) pathfinding algorithm  (Read 7462 times)
0 Members and 1 Guest are viewing this topic.
Offline princec

JGO Kernel


Medals: 378
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Posted 2002-11-18 22:24:04 »

An A* algorithm now lives up in the shaven puppy game library. Find it on the sourceforge cvs:

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/spgl/spgl/src/com/shavenpuppy/jglib/algorithms/

(You'll also find Bresenham's line drawing algorithm, a hacked Perlin noise generator, and a radix sorter)

Cas Smiley

Offline larth

Innocent Bystander




Java roolz!


« Reply #1 - Posted 2003-06-22 13:31:49 »

Quote
An A* algorithm now lives up in the shaven puppy game library. Find it on the sourceforge cvs:

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/spgl/spgl/src/com/shavenpuppy/jglib/algorithms/

(You'll also find Bresenham's line drawing algorithm, a hacked Perlin noise generator, and a radix sorter)

Cas :)


Kewl! What's the license for the files without any license mentioned, f.x. the A star files?


/Lars
Offline whome

Junior Member




Carte Noir Java


« Reply #2 - Posted 2003-06-22 15:33:09 »

Life-After-Bresenham
2-step linedrawing algorithm beats them all 10-0:
http://escience.anu.edu.au/lecture/cg/Line/lifeAfterBresenham.en.html
Browse down to see a full pseudocode.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline swpalmer

JGO Coder




Where's the Kaboom?


« Reply #3 - Posted 2003-06-23 00:10:10 »

How is line drawing applied to the more complicated problem of pathfinding?  Drawing a straight line between two points is much simpler than general pathfinding.

Offline zparticle

Senior Member




Thick As A Brick


« Reply #4 - Posted 2003-10-01 18:13:31 »

I'm considering using the A* algo in a game I've almost got finished. However I'm concerned that the algo will cause an enormous amount of garbage collection making the game jerky.  

Has anyone actually used A* in a 2D platformer type game?

What effects did you see if any?

Offline princec

JGO Kernel


Medals: 378
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #5 - Posted 2003-10-01 19:21:01 »

Have a look at the A* code I've released. No allocation.

Cas Smiley

Offline tom
« Reply #6 - Posted 2004-01-07 00:13:04 »

Anyone tried the AStarInt class?

I'm having some problems with it. I've narrowed it down to the AStarInt.NodeList class. Profiling shows that it spends a lot of time in java.util.Arrays.mergeSort. The problems went away when I rewrote the NodeList class to use an ArrayList with brute force pop, remove and get functions. Also the rewritten class uses less steps to complete the search. Which makes me wonder if there is a bug.

Offline princec

JGO Kernel


Medals: 378
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #7 - Posted 2004-01-07 06:43:49 »

Well, I didn't have any problems when I was testing it but as I never got to use it in anger I couldn't really say...

Cas Smiley

Offline tom
« Reply #8 - Posted 2004-01-07 18:56:43 »

Well it might be just me. I do have the ability to mess things up now and then   Smiley

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Dwinin (22 views)
2014-09-12 09:08:26

Norakomi (55 views)
2014-09-10 13:57:51

TehJavaDev (66 views)
2014-09-10 06:39:09

Tekkerue (33 views)
2014-09-09 02:24:56

mitcheeb (55 views)
2014-09-08 06:06:29

BurntPizza (38 views)
2014-09-07 01:13:42

Longarmx (24 views)
2014-09-07 01:12:14

Longarmx (30 views)
2014-09-07 01:11:22

Longarmx (29 views)
2014-09-07 01:10:19

mitcheeb (37 views)
2014-09-04 23:08:59
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!