Jump to content

MoveMaps


Recommended Posts

  • Replies 201
  • Created
  • Last Reply

Top Posters In This Topic

On my point of view about the algorithm to be used for searching a path, I would also recommend a LRTA* like (Learning Real Time A*), but not right this one, better use MTS (Moving Target Search) which is LRTA* on moving target (like pet following a player who has jumped above stair). MTS just reduce itself to LRTA* when the target is fixed.

Link to comment
Share on other sites

Hello all,

I had some free time and wanted to work a bit on this project again ;)

Here are files updated to run with current maps/vmaps.

I am not able to make a diff since the GIT repository is very strange and all files have end line problem.

src/mmap/GridMapManager.h: http://pastebin.ca/1821114

src/mmap/GridMapManager.cpp: http://pastebin.ca/1821115

And some changes to be done to fix bugs:

In src/mmap/MoveMapBoxContainer.cpp line 361, inscrease the mmapname char array a bit, it's too short.

char mmapname[25];

And a cosmetic one:

In src/mmap/MoveMapBoxContainer.cpp line 352, add a line feed:

printf("Processing %s\\n", filename);

For the viewer to work, remove this *40 in src/viewer/ModelContainerView.cpp line 62

iVARAreaRef = VARArea::create (settings.window.width * settings.window.height * 60 + 8);

and forget about the command "load *"

Anyway, it seams to me that settings.window.width * settings.window.height * 60 is completly non sens, this VarArea should have the size of the objects we put inside, not related to window size if I am correct.

Have fun going on with this project :)

Neo2003

Link to comment
Share on other sites

Anyone got this to compile under linux?

edit:

here are neo's changes and changes to make it compile under linux (just some includes missing)

Not sure if this will work, since it just silently fails for me

gotisch@gotisch-desktop:~/programmieren/MoveMaps/Debug/src/generator$ ./mmap-generator 0 51 29 1
gotisch@gotisch-desktop:~/programmieren/MoveMaps/Debug/src/generator$ 

But hopefully that is just because i dont have vmaps anywhere atm.

diff: http://pastebin.ca/1828118

edit2: ok compiles, generation works and viewer works.

can someone maybe explain again what is red dots and blue lines? in viewer?

This doesnt look right anyway you look at it (if image not allowed pleases delete, and sorry :eek:)

screenshot14x.png

the house is below red dots.

edit 12312 (feels like it )

screenshot17ti.th.png

Here is image of movemaps + vmaps in stormwind (where they where correctly generated) and on right is a path + visited zones.

Looking at generated zones, paths, and visited zones during pathfinding. Imho work still first needs to be done on two things: generation of mmaps, and with that correct generation of zones. The fewer zones the better imo. fewer zones will also result in faster pathfinding. and less memory usage.What algorithm is later chosen to do actualy finding of path is not so important at the moment imo.

In case someone wanted to hear my opinion

Link to comment
Share on other sites

so,

i played around a bit with recast and here are results:

screenshot22.th.png

screenshot23qt.th.png

I don't find those so bad? I don't really understand why we have to rewrite everything from the ground up, if we have a rebust navmesh generation and pathfinding library at our hands? its writte by a proffessional game developer and its open source \\o/ maybe we can't use .obj files because there compression rate sux :).

I added here my ugly hack ( i really really suck at c++) to generate .obj file for recast: http://pastebin.ca/1832908

to generate it you just oben some vmap with the viewer (from jolans repo + fixes said above)

the generated .obj file (way to big because its a txt file) is here: http://rapidshare.com/files/361741912/map.obj.tar.gz.html

recast/ detour can be found here: http://code.google.com/p/recastnavigation/

nice explanation also can be found here: http://critterai.org/nmgen

So isnt using this library an alternative? or am i missing something here?

Link to comment
Share on other sites

I think (this is based on nothing but looking at the images you posted) the blue dots represent collideable objects (the fence, exterior house) and the red dots represent ground in which is freely passable (ground, floors in house).

And the path finding system you have seems to work alright, the only thing that might need implementation is to force the NPC to be a certain distance from the edge, just to make sure the game doesn't screw up and they fall.

Link to comment
Share on other sites

so,

I don't find those so bad? I don't really understand why we have to rewrite everything from the ground up, if we have a rebust navmesh generation and pathfinding library at our hands?

Yes, but at the time we were doing mmaps, recast didn't exist. I think its around 1-2 years since ralf started it.

Link to comment
Share on other sites

Well, I can't seem to get this to work. Whenever I try to generate my mmaps I get this returned:

C:\\Users\\Nick Taylor\\Projects\\MoveMaps\\bin\\Win32_Release>generator.exe 0 51 29 1

Now reading ..\\..\\demodata/vmaps/000_51_29.vmap
Now reading ..\\..\\demodata/vmaps/000_51_30.vmap
Now reading ..\\..\\demodata/vmaps/000_51_28.vmap
Now reading ..\\..\\demodata/vmaps/000_52_29.vmap
Now reading ..\\..\\demodata/vmaps/000_50_29.vmap
Size: 538 x 539
Found 0 starting point(s)

C:\\Users\\Nick Taylor\\Projects\\MoveMaps\\bin\\Win32_Release>

But the vmaps change depending on which coords are used in the command, which is expected. I am probably just missing some step somewhere, there isn't really a good set of instructions on how to get this to work, or I'm just completely oblivious and can't find it.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use