Kyatric
"Java is not JavaScript and HTML5 is JavaScript based."
whoops my bad. (FIXED) thanks.
--------
I'm sure those plugins work great, and will get people were they want to go most the time. I haven't looked at them much, so maybe they have a lot more customization than C1's path-finding behavior.
but the main reason I put the time in bringing this tutorial over to construct 2 is because i think its worth peoples time to try and learn this system themselves.
Personally A* was one of those things that seemed impossible for me to grasp. But when i took the time to stop using plugins as a crutch, and dove in. i found a wealth of knowledge , and leveled up as a game-maker majorly.
it opened up all kinds of possibility's. (thus my crazed rant).
I realized A* doesn't just search tile maps. it can search thru any node system.
which is awesome.
and construct handles A* in the array object surprisingly well.
--------------------------
thus the code itself can't really be plugged in and played as is without some complications. but its mainly intended to be a simple, good, starting point. not a solution.
I've tried it, as is, on large maps(within reason), and it works fine, the real slow down seems to come from drawing so many tiles. which can be fixed with custom tile drawing/destroying.like this
but if you do that. the loop 100 should be a while loop, with some condition to make it stop if it cant get there. but that just complicates things as far as my example.
However, for truly LARGE maps, you'll need to add on to the code, not necessarily completely re-wright it.
basically breaking down the tile-map array into another smaller array (the Meta Array), then A* search a small segment at a time of the tile-map array based off the META Maps A* Path stored in the object. and that regression could go on forever for GALAXY SIZED MAPS!!....if you wanted...
But A* is A*, no matter what, 2d/3d/40d/waypoints/jumpgates/platformers ext.
what is checked, and how the distance formulas are figured out change.
but the basic process doesn't.
having done absurd complex things with C1's arrays, I'm willing to bet there still the best rout to go outside actual plugin coding in C2.
----------------------------------------------------------------
Plus it( in theory) is compatible with the current arcade.