Pathfinding and GameObjects with Velocity

Yeah, but that’s because it checks if the original path is occupied. Your path isn’t, and therefore should remain the same.

If you look at my pseudocode, and actual code, you see they match 1 to 1. I seriously doubt yours do, with all your timeouts :slight_smile: I can match every if and else…
I mean, don’t take shortcuts, try to match your code exactly, including timers.

Well something is afoot, and I can’t put my finger on what… anyway, i THINK i did the github thing right, here it is:

Hmm, not quite, something wrong with your main, but whatever.

I had hoped to be able to run this, but without a database, I guess that’s not going to happen.
First thing I noticed (or actually Chrome did it for me :slight_smile: ):

levelData[i][j] = Math.floor(Math.random() * (maxTileRange - minTileRange + 1) ) + minnTileRange;

minnTileRange is not defined → typo

that typo has been corrected but does not appear to have had any bearing on the issue I am having…

I’ve gone as far as to log out my levelData tile index and it appears to be functioning correctly, water tiles are indeed in their correct indexes, I don’t think the issue lies in the tiles themselves, i have a hunch it has something to do with some configuration of easystar, but thats coming from a total game dev newb, I can’t be certain…

Is there a configuration of easystar I am missing here?

PS: you can run this anytime at http://astralforge.net as a live development demo

I’ve update my take on the tutorial with visible tile id’s.
My advice would be to make sure you understand that tutorial, it works, and I only changed a couple of lines to basically do exactly what you aim for. If I changed the sprites and projected it to Isometric it would be your game :slight_smile:

That’s not very useful for debugging. It would help if you made a non database version.

the reason I didn’t follow that tutorial as strictly as perhaps I should have is this:
doesnt the units not being strictly bound to within the center of each tile make a vast difference? I cannot have my units move along strict tile coordinates, they need to be able to move freely among world x/y points…

Easystar can only find you a tile based path. You should set enableDiagonals() and disableCornerCutting(). Start with this, and then try optimizing your movement. It is definitely possible to move freely with some extra checks.

I am aware easystar can only find me a tile based path, I am just using that as a starting point for my movement. The issue I am having is that easystar appears to be ignoring what I am designating unacceptable tiles for some reason which leads me to believe its a configuration issue with easystar itself. I digress, I will start with those diagonal and cornercutting checks first and advise from there. thanks :slight_smile: