tag:blogger.com,1999:blog-8967321114965538903.post372983989791355445..comments2023-05-13T09:33:56.238+01:00Comments on Lane Defence: A* Pathfinding Tutorial : Part 2FireFlyhttp://www.blogger.com/profile/08398015936723710602noreply@blogger.comBlogger16125tag:blogger.com,1999:blog-8967321114965538903.post-69637440299050577442011-12-05T17:24:30.019+00:002011-12-05T17:24:30.019+00:00I will have a look tonight and see if I can find w...I will have a look tonight and see if I can find where you went wrong!FireFlyhttps://www.blogger.com/profile/08398015936723710602noreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-26048035708984462582011-12-05T17:08:12.073+00:002011-12-05T17:08:12.073+00:00Never mind. No matter what I do I can not seem to ...Never mind. No matter what I do I can not seem to get my code to work. Most of the the time I end up in an infinite loop until the closed list runs out of memory...<br /><br />Here is my most recent attempt at the pathfinder.cs class<br /><br />http://pastebin.com/7UbbUBcYJTnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-60149064748033333702011-12-02T12:03:37.303+00:002011-12-02T12:03:37.303+00:00so heres my attempt at implementing A* completely
...so heres my attempt at implementing A* completely<br />(also, I found the traceback to start part pretty easy, unless I did it wrong lol)<br /><br />Level.cs (map.cs): http://pastebin.com/R6Pz5evn<br />Node.cs: http://pastebin.com/ubT6iF2G<br />Pathfinder.cs: http://pastebin.com/hzdLN3Ge<br /><br />I JUST got done writing it. Now im going to go test it lolJTnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-79114208055683725932011-11-08T15:21:39.538+00:002011-11-08T15:21:39.538+00:00Hi, great tutorial....can you do a tutorial in gam...Hi, great tutorial....can you do a tutorial in gamestate after part 3?<br /><br />your the best keep it up :)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-50138425550116739002011-11-02T11:46:35.798+00:002011-11-02T11:46:35.798+00:00Same question here,we are waiting for the part 3. ...Same question here,we are waiting for the part 3. Will you keep going?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-23661758907535111112011-10-29T21:12:13.654+01:002011-10-29T21:12:13.654+01:00Are you still working on this?Are you still working on this?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-28734295377536359482011-10-21T18:00:54.337+01:002011-10-21T18:00:54.337+01:00One question about the steps though, in step 3 C a...One question about the steps though, in step 3 C and D, you say if the active node is equal to the target node, return, if not, continue checking the neighbours. Does that mean that in code it basically just loops through the neighbours part over and over again ? ( which is what I have at the moment ) Because that way, it's never setting a new "activeNode" its just hopping through the actual neighbour nodes, continuously.Michaelnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-701116852943004542011-10-21T18:00:13.169+01:002011-10-21T18:00:13.169+01:00This comment has been removed by the author.Michael Duwéhttps://www.blogger.com/profile/09867324839788171386noreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-43169694538936263402011-10-21T12:13:57.472+01:002011-10-21T12:13:57.472+01:00Thanks for these tutorials, I was pulling my hair ...Thanks for these tutorials, I was pulling my hair out on how to implement pathfinding for a small maze game. I created a level similar to the way you did it, only I had two separate arrays for the horizontal and vertical walls since they would be implemented differently, and created a levelpath based on those 2 arrays. I understood the theory of it before, but didn't really get how to implement it properly with C#. Your first tutorial was just a godsend, i couldn't believe I missed such an obvious way :D. Thank you.Michaelnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-3625602518749087042011-09-28T15:42:07.033+01:002011-09-28T15:42:07.033+01:00When will the next part be released??When will the next part be released??Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-67810897390864007052011-09-21T20:15:04.419+01:002011-09-21T20:15:04.419+01:00I can't wait until the third installment. Any ...I can't wait until the third installment. Any estimates on when?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-45925692420429613432011-09-13T19:48:08.706+01:002011-09-13T19:48:08.706+01:00Something I would like to suggest to you as either...Something I would like to suggest to you as either one of your tutorials or just something to keep in mind is the use of priority queues instead of lists. In pathfinding on A* and your open list gets huge, the overhead for finding the smallest F-value can get quite large. Using a priority queue: http://en.wikipedia.org/wiki/Priority_queue can greatly reduce the this overhead and provide exponential performance boosts.Bmanhttp://www.brokedowngames.comnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-13443792395091326742011-08-28T11:13:25.180+01:002011-08-28T11:13:25.180+01:00Nice, I hope you will post the 3rd version soon! T...Nice, I hope you will post the 3rd version soon! This (http://www.phstudios.com/forums/index.php?/topic/1909-towerdefense-astar-algorithm/) tutorial helped me a lot, it's a great site with lot's of xna tutorials. I hope someone has any use of it! <br /><br />(This guy is also making a towerdefence tutorial =P)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-29828463266265821472011-08-23T14:02:02.292+01:002011-08-23T14:02:02.292+01:00Hi, thxs alot for all of those tutorial that's...Hi, thxs alot for all of those tutorial that's help me alot.<br />But i follow ur tuto since the start and i still got a little problem. When i kill a monster or when a monster reach the end i don't win any gold and i don't lose live. I look ur code and mine but i don't see where is my mistake did u have any idea ? (I can send u my project if u want :x). <br /><br />Thxs in advence<br /><br />P.S. Sorry for my bad english :s<br /><br />Edit : Nevermind i fixe my problem. I just add Player player to my update WaveManager méthod (public void Update(GameTime gameTime, Player player)) and same thing in wave & game1 and that work nowZerohttps://www.blogger.com/profile/00374767340877025238noreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-82007540499349620002011-08-23T13:55:36.654+01:002011-08-23T13:55:36.654+01:00This comment has been removed by the author.Zerohttps://www.blogger.com/profile/00374767340877025238noreply@blogger.comtag:blogger.com,1999:blog-8967321114965538903.post-80143691089263932032011-08-22T18:33:27.959+01:002011-08-22T18:33:27.959+01:00Also want to point out that if you ever have any q...Also want to point out that if you ever have any questions concerning any AI-related topics including pathing, I have always received kind and helpful advice from the users at aigamedev.comAnonymousnoreply@blogger.com