Jump to content

MMaps Redux


Guest auntieMangos

Recommended Posts

  • Replies 1.2k
  • Created
  • Last Reply

Top Posters In This Topic

1: If you experience a crash with the generator please include the following information:

  • * The map #
    * The tile #
    * The last message printed in the console before the crash
    * The settings you used

2: I've made progress with liquids. A bit more work to do, but I need some information:

  • * What is the maximum water depth I should allow creatures to walk through?
    Keep in mind some creatures are shorter than others - gnomes have to swim in water that other creatures can stand in.
    * Are there any creatures that should be allowed to swim through non-water (lava, slime, ocean, dark water) liquids?
    I can save some processing time and disk space if we can toss out certain data types.

Also, after that last feature addition I had a ton of bugs. I want to try and make this a smoother experience than the last one. It takes a lot of time to build the maps, and I don't want to compound that with bugs that make you start over all the time.

Link to comment
Share on other sites

ok sorry about the crash log but the last thing that i saw was that, the number of the map and something about extracting buildings i have to extract again the mmaps for get well the information about the log and its takes too long just wondering if was normal that happen because this is a proyect in proggress so mybe is normal i just very happy that works only in instances thanks anyway i will try to extract the maps again to get the error

my settings are on windows 7 and visual basic 2008 express edition

thanks for the time and mmaps =D

Link to comment
Share on other sites

What is the maximum water depth I should allow creatures to walk through?

Keep in mind some creatures are shorter than others - gnomes have to swim in water that other creatures can stand in.

I'm not sure I understand the question. Max depth can vary a lot. Giants can wade through a lake while a gnome can nearly drown in a puddle. I suppose it depends on what you use as your standard measure. If you go with gnome, then you're looking at about 2 feet or ~0.6 meters. Isn't there some flag or value that is used to determine if a creature or character can wade through or must swim?

Link to comment
Share on other sites

I was planning on using the shortest creature as a standard, but I thought about it again and I should be doing something taller than that. Otherwise water may end up being a barrier to tall creatures that can't swim, even if the water is shallow enough to wade through. Probably a tauren-sized monster, or a small ogre?

I don't know about any existing flags, that's why I asked! I'm learning all of this as I go :)

Link to comment
Share on other sites

1: If you experience a crash with the generator please include the following information:

  • * The map #
    * The tile #
    * The last message printed in the console before the crash
    * The settings you used

Well it doesn't crash, but if you extract map 001 (just: MoveMapGen.exe 001) you'll see this messages:

Happens with 00,00, 01,00 and 02,00 (iirc). Nothing unusual in the console. If you click ignore [German: Ignorieren] the extractor continues, if you click retry [German: Wiederholen] it should debug the application, but at least for me (now with win7 x64) and visual studio c++ express 2010 nothing happens.

I don't know if anything strange happens, if you just ignore it. Haven't had time to check, my graphic card was broken :-/

Regards

Skirnir

PS: I'm always a bit scary to extract all the mmaps, since they change that often and with my core2duo it still takes a sh*tload of time. So I don't know if you run into this problem anywhere else.

Link to comment
Share on other sites

Well it doesn't crash, but if you extract map 001 (just: MoveMapGen.exe 001) you'll see this messages:

Hmm, I'll try to fix that. My local repo conflicts with github, so it may be a bit before I push a change.

Sort of offtopic rambling:

I don't understand why it's happening - the string should never be longer than 16 characters long, and I allocated space for 18.

Someone else (vladex maybe? I don't remember) had reported a similar issue with the old mmap generator on tiles with the number 00. Perhaps it's related to x64...

PS: I'm always a bit scary to extract all the mmaps, since they change that often and with my core2duo it still takes a sh*tload of time.

That warning dialog you posted only appears when you compile for Debug, which adds a lot of overhead and really slows down execution. If you compile for Release, the maps get extracted a lot faster!

Link to comment
Share on other sites

I was planning on using the shortest creature as a standard, but I thought about it again and I should be doing something taller than that. Otherwise water may end up being a barrier to tall creatures that can't swim, even if the water is shallow enough to wade through. Probably a tauren-sized monster, or a small ogre?

I don't know about any existing flags, that's why I asked! I'm learning all of this as I go :)

atm there is the interpretation of unit_flags | 32768 means swimming

the height: I think you should try to use: if (water_height > model_height) swimming=true;

and you asked for different types of liquid, I think there should be nothing special: If a mob can walk over fire, and this mob can swim, he will be able to swim through lava.

Perhaps (till talked with a mangos-dev) the simpliest way is to just implement a new function

bool CanTraverse(LiquidType type) because I think these questions are not mmaps ;)

Link to comment
Share on other sites

I don't know about any existing flags, that's why I asked! I'm learning all of this as I go

You've already worked miracles with this as it is! I wish I knew a tenth of what you've already learned.

I have faith you'll get it figured out, faramir. Just remember to occasionally apply cold compresses to your skull so that massive brain doesn't overheat! lol

I think Schmoozerd might have the right idea of creating a function. It could be very unpredictable for movement in liquids to have one set height for every creature.

I have no experience with retail, but I have noticed creatures that do live around the lava streams in Searing Gorge. In Netherstorm, there are Oozes and Toxic Slimes that live in the contaminated waters near one of the mana forges. Maybe there needs to be new Inhabit Types to cover these environments? Perhaps a sub-type? This would save a lot of hard coding for each particular creature and use SQL data to determine if a creature can traverse lava/slime/water/sludge/etc.

Link to comment
Share on other sites

Wasn't getting the answers I expected, so I'll give you guys more information to work with:

Here is what is produced by the current revision on github (just something to compare with): Current navmesh picture

Here is the same map, but with liquid included: Liquid picutre

As you can see, the surface of the water (blue area) becomes a part of the navmesh.

Here is the reason I asked the question about walkable depth

  • * the water navmesh must be lower than the surface of the water in order for creatures to swim in the water instead of walk on top of water
    I have ideas on how to handle in mangos core, so it isn't a huge concern
    * there is water that is shallow enough to walk through, but it hides the ground underneath - as far as the navmesh is concerned, creatures that cannot swim can only get to the water and as a result can't pass through the water.
    This can only be done at build time, so whatever height we pick will be used by every creature in the game no matter how tall or short they are

Lowered liquid picture

As you can see, I lowered the level of the liquid (by 1 yard in this example), thus exposing more of the ground.

This allows all creatures to 'walk' across that 'ground' - even if they are so short that they are actually swimming through water.

In some cases, this may cause conflicts with other parts of mangos core - my pathfinding may determine that a location is solid ground, while the core may determine that the same location is underwater.

It's a complicated concept, and I don't feel like I'm expressing it very well.

In any case, there are still some issues that I have to work on.

You may notice in the picture all of the tiny black dots where the water meets the ground - these are gaps in the terrain mesh, which create holes in the navmesh. It messes up pathfinding from one surface type to the other.

edit: here is some lava

Link to comment
Share on other sites

Hm, just had an idea that might make this all much simpler:

Instead of 'water', I can use 'shallow water', 'water', and 'deep water' or something. That way the navmesh is more flexible.

After all, I have 16 possible terrain types to work with. The only ones I currently use are:

  • * ground
    * water (includes 'water' and 'ocean')
    * lava
    * slime
    * dark water (not sure what this exactly means)
    * unspecified liquid (a height is specified in the client data, but not a type)
Link to comment
Share on other sites

I believe what is meant by "dark water" refers to the deep ocean. It's that point where the sea bottom drops away completely and it is no longer possible to dive deep enough to even reach the bottom with unlimited breath. There is a distinct color change at that boundary, where the water turns much darker than it is inshore. Beyond this point, there are no creatures, not even fish, and players that swim out that far from shore begin to suffer fatigue.

This is just all conjecture based on observation, but it makes sense to me. Then again, game programmers sometimes use labels that are counter-intuitive.

This water-mesh you're referring to and what depth it needs to have established...

It seems you're saying the height used will determine if any water is passable by any creature. Wouldn't this instead mean you'd need to use the largest creature's height? This means anything shorter than that measure would have to swim across. This would solve the issue of very shallow water, wouldn't it? Since the water navmesh would lie below ground level at those places, any creature could then walk, wade, or swim across as needed.

Or am I still not getting it?

Link to comment
Share on other sites

Also check this link because I do think that this is what the original Dev was refering to and I do seem to remeber something about it like an area that was supposed to be and didn't make the finnal cut....http://www.google.com/url?sa=t&source=web&cd=10&ved=0CEkQFjAJ&url=http%3A%2F%2Fwww.mmowned.com%2Fforums%2Fworld-of-warcraft%2Fexploration%2F240455-under-eastern-kingdom-swimming-mount-dark-water-rediscovered.html&ei=Vg0iTIboKIO8lQf8tOScAQ&usg=AFQjCNF_ogQy0At6TP9jkzairQ4DxpnZTg&sig2=ZOFZG6ZmDwB2zk079dLz7w

Link to comment
Share on other sites

@Iowahc, yes the source on Git works right now.

@faramir118, would some for of seperate volumetic "imprint" based maps work for liquids? ie take a cube for area water would be, then "cut" non passable objects out of it, and swimming can only happen while in the volume? From this you can flag standing when a creature is less than 30% of its height in water, and over a walkable poly at the same depth, they walk on mmap instead of swim. (30% is guessed value, analysis of retail would be needed to approximate actual value)

edit:

Just noticed playing around on retail that if the mob can't swim, it will evade and not attempt to follow you into the water, it does maintain aggro and attacks as soon as you step out if still in range. They will go into water that is approx 75% of player height then stop and enter evade.

edit2: if the ai cannot find a path to player, it also triggers evade mode.

Link to comment
Share on other sites

@Iowahc, yes the source on Git works right now.

It works, but if you don't have a Meshes directory it crashes (unless you apply this fix)

would some for of seperate volumetic "imprint" based maps work for liquids? ie take a cube for area water would be, then "cut" non passable objects out of it, and swimming can only happen while in the volume?

Yes, I had thought about using convex volumes for liquids - unfortunately, it would have to be written from scratch.

Just noticed playing around on retail that if the mob can't swim, it will evade and not attempt to follow you into the water, it does maintain aggro and attacks as soon as you step out if still in range. They will go into water that is approx 75% of player height then stop and enter evade.

Interesting that they maintain aggro, I assumed they they just started fleeing. Although now that I think about it, mobs on retail don't truly 'reset' until they have reached their spawn/home.

What happens when a character that is swimming is on top of the threat list? Does the mob ignore that player, but still keep track of thread?

if the ai cannot find a path to player, it also triggers evade mode.

Yes, I just haven't looked into that portion of the code.

Link to comment
Share on other sites

What happens when a character that is swimming is on top of the threat list? Does the mob ignore that player, but still keep track of thread?

Aggro system on mangos needs some love from a long time.

1) NPC should aggro on all types of spellhits (miss, dodge etc) - but this is offtopic here

2) if there is no top threat target in availeble range, they try to attack from ranged abilities. If they don't have this kind of abilities they attack closest target in melee range. This also affects rooted, or freezed creatures. If you turn on showing `target of target` you will see that target is changing. When root faids NPC resume to attack previus target (if temporary does not build enough threat)

3) creatures chaising player share threat with all friendly units on their path

I think that NPC attention should be fixed in more generic way than some problems with your patch would be solved or at least simplified.

Link to comment
Share on other sites

Isn't that only for when you're using mmaps in debug mode or is it also needed for "release" compiles?

It's only for debugging the navmesh in RecastDemo, but he said he was using the debugOutput parameter - maybe a better answer would have been 'stop using debugOutput'. It's something that only I will ever need to use.

I think that NPC attention should be fixed in more generic way than some problems with your patch would be solved or at least simplified.

Agreed. That may be a whole project unto itself.

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