[7538] Hide some implementation details for reputation/forced faction reaction. Author: VladimirMangos

--HG--
branch : trunk
This commit is contained in:
megamage
2009-03-25 16:04:08 -06:00
parent 312b8e5b73
commit 02440eaa10
9 changed files with 147 additions and 116 deletions

View File

@@ -876,15 +876,7 @@ void WorldSession::HandleSetFactionAtWar( WorldPacket & recv_data )
recv_data >> repListID;
recv_data >> flag;
FactionStateList::iterator itr = GetPlayer()->m_factions.find(repListID);
if (itr == GetPlayer()->m_factions.end())
return;
// always invisible or hidden faction can't change war state
if(itr->second.Flags & (FACTION_FLAG_INVISIBLE_FORCED|FACTION_FLAG_HIDDEN) )
return;
GetPlayer()->SetFactionAtWar(&itr->second,flag);
GetPlayer()->SetFactionAtWar(repListID,flag);
}
//I think this function is never used :/ I dunno, but i guess this opcode not exists
@@ -892,7 +884,7 @@ void WorldSession::HandleSetFactionCheat( WorldPacket & /*recv_data*/ )
{
//CHECK_PACKET_SIZE(recv_data,4+4);
//sLog.outDebug("WORLD SESSION: HandleSetFactionCheat");
sLog.outError("WORLD SESSION: HandleSetFactionCheat, not expected call, please report.");
/*
uint32 FactionID;
uint32 Standing;
@@ -912,7 +904,7 @@ void WorldSession::HandleSetFactionCheat( WorldPacket & /*recv_data*/ )
}
}
*/
GetPlayer()->UpdateReputation();
GetPlayer()->SendFactionStates();
}
void WorldSession::HandleMeetingStoneInfo( WorldPacket & /*recv_data*/ )
@@ -977,11 +969,7 @@ void WorldSession::HandleSetWatchedFactionInactiveOpcode(WorldPacket & recv_data
uint8 inactive;
recv_data >> replistid >> inactive;
FactionStateList::iterator itr = _player->m_factions.find(replistid);
if (itr == _player->m_factions.end())
return;
_player->SetFactionInactive(&itr->second, inactive);
_player->SetFactionInactive(replistid, inactive);
}
void WorldSession::HandleToggleHelmOpcode( WorldPacket & /*recv_data*/ )