Jump to content

[Crash][Mangos-0.12]RandomMovementGenerator


Recommended Posts

Posted

Hi,

(

rev. = s0036

custom patches = some, but I can't see one related to this

)

From some time, I've got this crash on my server : http://pastebin.com/Yyz7Bjvy (I have several of these log always the same)

After doing my homework, it seems like the RandomMovementGenerator<Creature>::_setRandomLocation(Creature &creature) function ask for the creature.GetRespawnCoord that return false values because the creature implied is a summoned one (so not referenced in the mCreatureDataMap).

If I'm correct, I guess there would be two way of fixing this : either create an exception in the GetCreatureDataPair(uint32 guid) function to handle summoned creature, or do it in the RandomMovementGenerator<Creature>::_setRandomLocation(Creature &creature) function.

But Maybe I'm totally wrong :P So I'm waiting for experts tip for this one.

Posted

mangos-0.12 in proccess slow move step by step sync with mangos master (backporting appropriate commits and commit parts).

In result any mangos-0.12 changes different from mangos master accepted only in case some code part expected to be different for 2.4.3 client in result client differences.

movegens expected to be exactly same work (except client flags) in mangos-0.12 and master. So if some porblem exist in mangos-0.12 and not exist in mangos master then

or (1) some commit with fix not backported, or (2) backproted wrongly.

So best way compare related code work in mangos-0.12 and master and detect problematic code differecnes. If related not backported commit not high dependent from early

commits i can backport it in prio for fix crash if you point to like commit. ;)

Posted
creature.GetRespawnCoord that return false values because the creature implied is a summoned

But function return GetSummonPoint(x, y, z, orient); in summon case that set for all existed summon types...

Ok, except used for EffectSummonPet. But MotionMaster::Initialize call selectMovementGenerator that always select follow movegen for unit with owner...

Posted
But function return GetSummonPoint(x, y, z, orient); in summon case that set for all existed summon types...

Ok, except used for EffectSummonPet. But MotionMaster::Initialize call selectMovementGenerator that always select follow movegen for unit with owner...

Yeah that's what I saw too. I tried to call SetSummonPoint in EffectSummonPet. Dunno if this will help, what do you think ? I tried hoping this would solve anything, 'cause it's the only possible issue I could found so far.

Posted

Thanks to you Vladimir I've enhanced my understanding in this part of mangos. I think I've found the problem (even if I'm not entirely sure but it looks like it) : a creature summoned by another creature had a MovementType = 1 (random). And, as you said, it seems that shouldn't happen. So I put the MovementType back to 0, I'll see if I have the same crash again.

Maybe if it happens again with another creature I should write a fix directly in the core to consider MovementType of a creature summoned by another creature automatically to 0 in Spell::EffectSummonPet

×
×
  • 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