[8382] Implement ByteArray functions for skip read of fields not needed for server in received packets. Author: VladimirMangos

* Use this fucntions in some case.
    * Change some packets to form: read fields first check later for better control recieved packets structure.
    * Fix CMSG_STAND_STATE_CHANGE packet structure to more correct.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-08-19 16:54:52 -05:00
parent 012d6fa865
commit edc05f2c19
8 changed files with 76 additions and 40 deletions

View File

@@ -355,10 +355,9 @@ void WorldSession::HandleCastSpellOpcode(WorldPacket& recvPacket)
void WorldSession::HandleCancelCastOpcode(WorldPacket& recvPacket)
{
// increments with every CANCEL packet, don't use for now
uint8 counter;
uint32 spellId;
recvPacket >> counter;
recvPacket.read_skip<uint8>(); // counter, increments with every CANCEL packet, don't use for now
recvPacket >> spellId;
if(_player->IsNonMeleeSpellCasted(false))