Jump to content

How to modify the melee attack range ?


Recommended Posts

Posted

Hi everyone, I wondering how to modify the melee attack range ?

Indeed, most of melee classes are very powerful with a long range of melee attack.

Thank you in advance and sorry for my english.

Posted

This problem is freaking me out, too.

I was looking for some suggestions for quite a longer time, but i found nothing really helpful.

I hope, that someone is able to fix this.

  • 4 months later...
Posted

there is in Player::Update

    if (hasUnitState(UNIT_STAT_MELEE_ATTACKING))
   {
       Unit *pVictim = getVictim();
       if (pVictim && !IsNonMeleeSpellCasted(false))
       {
           // default combat reach 10
           // TODO add weapon,skill check

           float pldistance = ATTACK_DISTANCE;

           if (isAttackReady(BASE_ATTACK))
           {
               if(!IsWithinDistInMap(pVictim, pldistance))
               {
                   setAttackTimer(BASE_ATTACK,100);
                   if(m_swingErrorMsg != 1)                // send single time (client auto repeat)
                   {
                       SendAttackSwingNotInRange();
                       m_swingErrorMsg = 1;
                   }
               }
...

in Object.h ATTACK_DISTANCE is set to 5.0f

Posted

Yes, I think it depends on class but, even with this factor of variation : a rogue, a war and a paladin (all melee class but at least 3 of them), hit farther than on retail i'm sure of it ^^.

I will try to make a short movie to show you.

Anyway, thank you.

PS : it's very important, because this could change a lot of things in PvP.

PS 2 : if somebody have more infos, share it !

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