Changeset 189

Show
Ignore:
Timestamp:
11/19/08 13:44:45 (17 years ago)
Author:
yumileroy
Message:

[svn] Possession:
* Fixed player not having PvP flag on remove
* Fixed pet resetting its aggro on remove
* Fixed pet bar resetting on remove (?)
* Added dummy handler for NOT_ACTIVE_MOVER, display message only in debug logging mode

Original author: gvcoman
Date: 2008-11-07 16:49:42-06:00

Location:
trunk/src/game
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/game/MovementHandler.cpp

    r174 r189  
    539539} 
    540540 
     541void WorldSession::HandleNotActiveMoverOpcode(WorldPacket& /*recv_data*/) 
     542{ 
     543    sLog.outDebug("WORLD: Recvd CMSG_MOVE_NOT_ACTIVE_MOVER"); 
     544} 
     545 
    541546void WorldSession::HandleMountSpecialAnimOpcode(WorldPacket& /*recvdata*/) 
    542547{ 
  • trunk/src/game/Opcodes.cpp

    r152 r189  
    750750    /*0x2CF*/ { "CMSG_MOVE_FEATHER_FALL_ACK",       STATUS_LOGGEDIN, &WorldSession::HandleFeatherFallAck            }, 
    751751    /*0x2D0*/ { "CMSG_MOVE_WATER_WALK_ACK",         STATUS_LOGGEDIN, &WorldSession::HandleMoveWaterWalkAck          }, 
    752     /*0x2D1*/ { "CMSG_MOVE_NOT_ACTIVE_MOVER",       STATUS_NEVER,    &WorldSession::Handle_NULL                     }, 
     752    /*0x2D1*/ { "CMSG_MOVE_NOT_ACTIVE_MOVER",       STATUS_LOGGEDIN, &WorldSession::HandleNotActiveMoverOpcode      }, 
    753753    /*0x2D2*/ { "SMSG_PLAY_SOUND",                  STATUS_NEVER,    &WorldSession::Handle_ServerSide               }, 
    754754    /*0x2D3*/ { "CMSG_BATTLEFIELD_STATUS",          STATUS_LOGGEDIN, &WorldSession::HandleBattlefieldStatusOpcode   }, 
  • trunk/src/game/Player.cpp

    r186 r189  
    1866118661    SetPossessedTarget(target); 
    1866218662 
     18663    uint32 flags1 = target->GetUInt32Value(UNIT_FIELD_FLAGS); 
     18664 
    1866318665    target->SetUInt32Value(UNIT_FIELD_FACTIONTEMPLATE, getFaction()); 
    1866418666    target->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE); 
     
    1866818670    SetUInt64Value(PLAYER_FARSIGHT, target->GetGUID()); 
    1866918671 
     18672    uint32 flags2 = target->GetUInt32Value(UNIT_FIELD_FLAGS); 
     18673 
    1867018674    if(target->GetTypeId() == TYPEID_UNIT) 
    1867118675    { 
     
    1872118725    } 
    1872218726 
     18727    // Interrupt any current casting of the target 
     18728    if(target->IsNonMeleeSpellCasted(true)) 
     18729        target->InterruptNonMeleeSpells(true); 
     18730 
    1872318731    RemovePossessedTarget(); 
    1872418732 
     
    1874418752 
    1874518753    target->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_UNKNOWN5); 
    18746     target->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE); 
    1874718754    RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_DISABLE_MOVE); 
    1874818755    SetUInt64Value(PLAYER_FARSIGHT, 0); 
     
    1875918766    else 
    1876018767    { 
     18768        target->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE); 
    1876118769        if(((Creature*)target)->isPet()) 
    18762         { 
    18763             ((Pet*)target)->InitPetCreateSpells(); 
    1876418770            PetSpellInitialize(); 
    18765         } 
    18766  
    18767         if (target->isAlive()) 
     18771        else if (target->isAlive()) 
    1876818772        { 
    1876918773            // If we're still hostile to our target, continue attacking otherwise reset threat and go home 
    18770             if (target->getVictim()) 
    18771             { 
    18772                 Unit* victim = target->getVictim(); 
     18774            if (Unit* victim = target->getVictim()) 
     18775            { 
    1877318776                FactionTemplateEntry const* t_faction = target->getFactionTemplateEntry(); 
    1877418777                FactionTemplateEntry const* v_faction = victim->getFactionTemplateEntry(); 
     
    1878418787                } 
    1878518788            }  
    18786             else if (target->GetTypeId() == TYPEID_UNIT) 
     18789            else 
    1878718790            { 
    1878818791                target->GetMotionMaster()->Clear(); 
     
    1879118794             
    1879218795            // Add high amount of threat on the player 
    18793             if(target != GetPet() && attack) 
     18796            if(attack) 
    1879418797                target->AddThreat(this, 1000000.0f); 
    1879518798        } 
  • trunk/src/game/WorldSession.h

    r174 r189  
    321321        void HandlePossessedMovement(WorldPacket& recv_data, MovementInfo& movementInfo, uint32& MovementFlags); 
    322322        void HandleSetActiveMoverOpcode(WorldPacket &recv_data); 
     323        void HandleNotActiveMoverOpcode(WorldPacket &recv_data); 
    323324        void HandleMoveTimeSkippedOpcode(WorldPacket &recv_data); 
    324325