Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/game/AI/ScriptedAI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */

#include "WorldPacket.h"
#include "Server/WorldPacket.h"
#include "ScriptedAI.h"
#include "GridSearchers.h"

Expand Down Expand Up @@ -346,4 +346,4 @@ void ScriptedAI::Ambush(Unit* pNewVictim, uint32 embushSpellId)
m_creature->CastSpell(pNewVictim, embushSpellId, true);
if (m_creature->AI())
m_creature->AI()->AttackStart(pNewVictim);
}
}
6 changes: 3 additions & 3 deletions src/game/AccountMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include "Policies/SingletonImp.h"
#include "Util.h"
#include "World.h"
#include "WorldSession.h"
#include "Server/WorldSession.h"
#include "MasterPlayer.h"
#include "Anticheat.h"
#include "Crypto/Authentication/SRP6.h"
Expand Down Expand Up @@ -376,7 +376,7 @@ void AccountMgr::LoadAccountBanList(bool silent)
sLog.Out(LOG_BASIC, LOG_LVL_MINIMAL, "Loading account_banned ...");

std::unique_ptr<QueryResult> banresult(LoginDatabase.PQuery("SELECT `id`, `unbandate`, `bandate` FROM `account_banned` WHERE `active` = 1 AND (`unbandate` > UNIX_TIMESTAMP() OR `bandate` = `unbandate`)"));

if (!banresult)
{
if (!silent)
Expand Down Expand Up @@ -539,7 +539,7 @@ AccountPersistentData& AccountMgr::GetAccountPersistentData(uint32 accountId)
if (itr != m_accountPersistentData.end())
return itr->second;
}

{
std::lock_guard<std::shared_timed_mutex> guard(m_accountPersistentDataMutex);
return m_accountPersistentData[accountId];
Expand Down
2 changes: 1 addition & 1 deletion src/game/Anticheat/Anticheat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ AnticheatManager* GetAnticheatLib()
}

#include "World.h"
#include "WorldSession.h"
#include "Server/WorldSession.h"

#include "MovementAnticheat/MovementAnticheat.h"
#include "WardenAnticheat/Warden.hpp"
Expand Down
28 changes: 14 additions & 14 deletions src/game/Anticheat/MovementAnticheat/MovementAnticheat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#include "Chat.h"
#include "Player.h"
#include "GameObject.h"
#include "WorldSession.h"
#include "Server/WorldSession.h"
#include "MoveSpline.h"
#include "World.h"
#include "MovementPacketSender.h"
Expand Down Expand Up @@ -211,7 +211,7 @@ uint32 MovementAnticheat::ComputeCheatAction(std::stringstream& reason)
uint32 action = CHEAT_ACTION_NONE;

auto AddPenaltyForCheat = [&action, &reason, this](bool total, CheatType cheatType, eConfigBoolValues enabledConfig, eConfigUInt32Values thresholdConfig, eConfigUInt32Values penaltyConfig)
{
{
if (sWorld.getConfig(enabledConfig))
{
ASSERT(cheatType < CHEATS_COUNT);
Expand Down Expand Up @@ -610,7 +610,7 @@ uint32 MovementAnticheat::HandlePositionTests(Player* pPlayer, MovementInfo& mov
(sWorld.getConfig(CONFIG_BOOL_AC_MOVEMENT_PLAYERS_ONLY) && (m_session->GetSecurity() != SEC_PLAYER)) ||
!pPlayer->movespline->Finalized())
return 0;

if (pPlayer != me)
InitNewPlayer(pPlayer);

Expand Down Expand Up @@ -682,7 +682,7 @@ uint32 MovementAnticheat::HandlePositionTests(Player* pPlayer, MovementInfo& mov
cheatFlags |= flags;
}

if (IsFallEndOpcode(opcode) ||
if (IsFallEndOpcode(opcode) ||
movementInfo.HasMovementFlag(MOVEFLAG_ROOT))
m_knockBack = false;

Expand All @@ -697,8 +697,8 @@ uint32 MovementAnticheat::HandlePositionTests(Player* pPlayer, MovementInfo& mov
{
me->m_movementInfo.moveFlags = movementInfo.moveFlags;
me->m_movementInfo.CorrectData();
}
}

if (HAS_CHEAT(CHEAT_TYPE_OVERSPEED_JUMP) &&
sWorld.getConfig(CONFIG_BOOL_AC_MOVEMENT_CHEAT_OVERSPEED_JUMP_REJECT))
{
Expand Down Expand Up @@ -733,7 +733,7 @@ uint32 MovementAnticheat::HandleFlagTests(Player* pPlayer, MovementInfo& movemen
if (!sWorld.getConfig(CONFIG_BOOL_AC_MOVEMENT_ENABLED) ||
(sWorld.getConfig(CONFIG_BOOL_AC_MOVEMENT_PLAYERS_ONLY) && (m_session->GetSecurity() != SEC_PLAYER)))
return 0;

if (me != pPlayer)
InitNewPlayer(pPlayer);

Expand Down Expand Up @@ -941,7 +941,7 @@ bool MovementAnticheat::CheckFallReset(MovementInfo const& movementInfo) const
if (!GetLastMovementInfo().HasMovementFlag(MOVEFLAG_JUMPING | MOVEFLAG_FALLINGFAR))
return true;
}

return movementInfo.fallTime != 0 || movementInfo.jump.zspeed != 0.0f;
}

Expand Down Expand Up @@ -997,7 +997,7 @@ bool MovementAnticheat::CheckMoveStart(MovementInfo const& movementInfo, uint16
!GetLastMovementInfo().HasMovementFlag(MOVEFLAG_FORWARD))
return true;
}

if (opcode == MSG_MOVE_START_BACKWARD)
{
if (!movementInfo.HasMovementFlag(MOVEFLAG_BACKWARD))
Expand Down Expand Up @@ -1065,7 +1065,7 @@ bool MovementAnticheat::CheckMoveStart(MovementInfo const& movementInfo, uint16
}
else
{

if (movementInfo.HasMovementFlag(MOVEFLAG_SWIMMING) &&
!GetLastMovementInfo().HasMovementFlag(MOVEFLAG_SWIMMING) &&
!me->HasCheatOption(PLAYER_CHEAT_FLY))
Expand Down Expand Up @@ -1260,7 +1260,7 @@ uint32 MovementAnticheat::CheckSpeedHack(MovementInfo const& movementInfo, uint1
(opcode == CMSG_MOVE_SPLINE_DONE) ||
IsInKnockBack() ||
!GetLastMovementInfo().ctime ||
me->IsTaxiFlying() ||
me->IsTaxiFlying() ||
me->IsBeingTeleported())
return 0;

Expand Down Expand Up @@ -1477,7 +1477,7 @@ void MovementAnticheat::CheckBotting(uint16 opcode, MovementInfo const& movement
// we store turns count here
m_cheatOccuranceTotal[CHEAT_TYPE_BOTTING]++;
}

m_movementPacketsCount++;
}

Expand All @@ -1500,7 +1500,7 @@ bool MovementAnticheat::CheckTeleport(MovementInfo const& movementInfo) const
float const distance2d = movementInfo.HasMovementFlag(MOVEFLAG_ONTRANSPORT) ?
GetDistance2D(GetLastMovementInfo().t_pos, movementInfo.t_pos) :
GetDistance2D(GetLastMovementInfo().pos, movementInfo.pos);

if (distance2d > 1.0f)
return true;

Expand All @@ -1512,7 +1512,7 @@ bool MovementAnticheat::CheckTeleport(MovementInfo const& movementInfo) const
float const distanceZ = movementInfo.HasMovementFlag(MOVEFLAG_ONTRANSPORT) ?
std::abs(GetLastMovementInfo().t_pos.z - movementInfo.t_pos.z) :
std::abs(GetLastMovementInfo().pos.z - movementInfo.pos.z);

if (distanceZ > 2.0f)
return true;
}
Expand Down
4 changes: 2 additions & 2 deletions src/game/Anticheat/WardenAnticheat/Warden.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@

#include "Common.h"
#include "Language.h"
#include "WorldPacket.h"
#include "WorldSession.h"
#include "Server/WorldPacket.h"
#include "Server/WorldSession.h"
#include "World.h"
#include "Log.h"
#include "Errors.h"
Expand Down
4 changes: 2 additions & 2 deletions src/game/Anticheat/WardenAnticheat/WardenMac.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#include "WardenMac.hpp"
#include "WardenModuleMgr.hpp"
#include "WardenScanMgr.hpp"
#include "WorldSession.h"
#include "Server/WorldSession.h"
#include "World.h"
#include "Database/DatabaseEnv.h"

Expand All @@ -43,7 +43,7 @@ void WardenMac::LoadScriptedScans()
WardenMac::WardenMac(WorldSession* session, BigNumber const& K)
: m_fingerprintSaved(false), Warden(session, session->GetPlatform() == CLIENT_PLATFORM_X86 ? sWardenModuleMgr.GetMacModule() : nullptr, K)
{

}

void WardenMac::Update()
Expand Down
2 changes: 1 addition & 1 deletion src/game/Anticheat/WardenAnticheat/WardenMac.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

#include "Warden.hpp"
#include "WardenScan.hpp"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"

#include <string>

Expand Down
2 changes: 1 addition & 1 deletion src/game/Anticheat/WardenAnticheat/WardenWin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include "WardenScan.hpp"
#include "../Anticheat.h"
#include "World.h"
#include "WorldSession.h"
#include "Server/WorldSession.h"
#include "Util.h"
#include "Log.h"
#include "Crypto/BigNumber.h"
Expand Down
2 changes: 1 addition & 1 deletion src/game/Anticheat/WardenAnticheat/WardenWin.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

#include "Warden.hpp"
#include "WardenScan.hpp"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"

#include <vector>

Expand Down
6 changes: 3 additions & 3 deletions src/game/AuctionHouse/AuctionHouseMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
#include "ObjectGuid.h"
#include "Player.h"
#include "World.h"
#include "WorldPacket.h"
#include "WorldSession.h"
#include "Server/WorldPacket.h"
#include "Server/WorldSession.h"
#include "Mail.h"
#include "TransactionLog.h"
#include "Policies/SingletonImp.h"
Expand Down Expand Up @@ -153,7 +153,7 @@ void AuctionHouseMgr::SendAuctionWonMail(AuctionEntry* auction)

uint32 owner_accid = sObjectMgr.GetPlayerAccountIdByGUID(owner_guid);

sLog.Player(bidder_accId, LOG_GM, LOG_LVL_BASIC,
sLog.Player(bidder_accId, LOG_GM, LOG_LVL_BASIC,
"GM %s (Account: %u) won item in auction: %s (Entry: %u Count: %u) and pay money: %u. Original owner %s (Account: %u)",
bidder_name.c_str(), bidder_accId, pItem->GetProto()->Name1, pItem->GetEntry(), pItem->GetCount(), auction->bid, owner_name.c_str(), owner_accid);
}
Expand Down
8 changes: 4 additions & 4 deletions src/game/Battlegrounds/BattleGround.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#include "ObjectGuid.h"
#include "ObjectMgr.h"
#include "Mail.h"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"
#include "Util.h"
#include "Formulas.h"
#include "GridNotifiersImpl.h"
Expand Down Expand Up @@ -690,7 +690,7 @@ void BattleGround::EndBattleGround(Team winner)
if (team == winner)
RewardMark(pPlayer, true);
// World of Warcraft Client Patch 1.8.4 (2005-12-06)
// - Battles must now last at least ten minutes after the start of the
// - Battles must now last at least ten minutes after the start of the
// battle in order for the losing team to receive a Mark of honor.
else if (GetStartTime() > 10 * MINUTE * IN_MILLISECONDS)
RewardMark(pPlayer, false);
Expand Down Expand Up @@ -1199,7 +1199,7 @@ void BattleGround::DecreaseInvitedCount(Team team)
}
}
void BattleGround::IncreaseInvitedCount(Team team)
{
{
switch (team)
{
case ALLIANCE:
Expand Down Expand Up @@ -1283,7 +1283,7 @@ bool BattleGround::AddObject(uint32 type, uint32 entry, float x, float y, float
delete go;
return false;
}

// add to world, so it can be later looked up from HashMapHolder
go->AddToWorld();
m_bgObjects[type] = go->GetObjectGuid();
Expand Down
2 changes: 1 addition & 1 deletion src/game/Battlegrounds/BattleGroundAB.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#include "BattleGroundMgr.h"
#include "Language.h"
#include "Util.h"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"

#if SUPPORTED_CLIENT_BUILD > CLIENT_BUILD_1_6_1

Expand Down
18 changes: 9 additions & 9 deletions src/game/Battlegrounds/BattleGroundAV.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "Creature.h"
#include "GameObject.h"
#include "Language.h"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"
#include "Chat.h"
#include "World.h"

Expand Down Expand Up @@ -129,7 +129,7 @@ void BattleGroundAV::initializeChallengeInvocationGoals(void)
m_challengeMinReputationNeeded[i] = REP_NEUTRAL; /** Real value REP_REVERED */

// World of Warcraft Client Patch 1.6.0 (2005-07-12)
// The minimum reputation needed to send a cavalry charge has been
// The minimum reputation needed to send a cavalry charge has been
// reduced to Honored.
m_challengeMinReputationNeeded[BG_AV_CAVALRY_ASSAULT] = sWorld.GetWowPatch() < WOW_PATCH_106 ? REP_REVERED : REP_HONORED;
m_challengeMinReputationNeeded[BG_AV_GROUND_ASSAULT] = REP_HONORED;
Expand Down Expand Up @@ -401,12 +401,12 @@ void BattleGroundAV::HandleKillUnit(Creature* creature, Player* killer)
{
ChangeMineOwner(BG_AV_SOUTH_MINE, GetAVTeamIndexByTeamId(killer->GetTeam()));
CompleteQuestForAll(7122);
}
}
else if (killer->GetTeam() == HORDE)
{
ChangeMineOwner(BG_AV_SOUTH_MINE, GetAVTeamIndexByTeamId(killer->GetTeam()));
CompleteQuestForAll(7124);
}
}
else // Never happens, this function HandleKillUnit is only called if a player kill a unit
ChangeMineOwner(BG_AV_SOUTH_MINE, BG_AV_TEAM_NEUTRAL);
break;
Expand Down Expand Up @@ -527,7 +527,7 @@ void BattleGroundAV::HandleQuestComplete(Unit* questGiver, uint32 questid, Playe
sprintf(sMessageRemaining,"Thanks for the supplies, %s",player->GetName());
((Creature*)questGiver)->MonsterSay(sMessageRemaining, 0, 0);

if (m_teamQuestStatus[teamIdx][0] == 500)
if (m_teamQuestStatus[teamIdx][0] == 500)
{
if (teamIdx == 0)
CastSpellOnTeam(28418, ALLIANCE);
Expand All @@ -537,7 +537,7 @@ void BattleGroundAV::HandleQuestComplete(Unit* questGiver, uint32 questid, Playe
sprintf(sMessageRemaining,"Seasoned units are entering the battle!");
((Creature*)questGiver)->MonsterYell(sMessageRemaining, 0, 0);
}
else if (m_teamQuestStatus[teamIdx][0] == 1000)
else if (m_teamQuestStatus[teamIdx][0] == 1000)
{
if (teamIdx == 0)
CastSpellOnTeam(28419, ALLIANCE);
Expand All @@ -547,7 +547,7 @@ void BattleGroundAV::HandleQuestComplete(Unit* questGiver, uint32 questid, Playe
sprintf(sMessageRemaining,"Veteran units are entering the battle!");
((Creature*)questGiver)->MonsterYell(sMessageRemaining, 0, 0);
}
else if (m_teamQuestStatus[teamIdx][0] == 1500)
else if (m_teamQuestStatus[teamIdx][0] == 1500)
{
if (teamIdx == 0)
CastSpellOnTeam(28420, ALLIANCE);
Expand Down Expand Up @@ -600,7 +600,7 @@ void BattleGroundAV::HandleQuestComplete(Unit* questGiver, uint32 questid, Playe
if (m_nodes[i].owner == teamIdx && m_nodes[i].state == POINT_CONTROLLED)
PopulateNode(i);
}
*/
*/
break;
case BG_AV_QUEST_A_COMMANDER1:
case BG_AV_QUEST_H_COMMANDER1:
Expand Down Expand Up @@ -964,7 +964,7 @@ void BattleGroundAV::EndBattleGround(Team winner)
RewardHonorToTeam(uint32(GetBonusHonorFromKill(towersSurvived[i] * BG_AV_KILL_SURVIVING_TOWER) * GetHonorModifier()), team[i]);
}
sLog.Out(LOG_BASIC, LOG_LVL_DEBUG, "BattleGroundAV: EndbattleGround: bgteam: %u towers:%u honor:%u rep:%u", i, towersSurvived[i], GetBonusHonorFromKill(towersSurvived[i] * BG_AV_KILL_SURVIVING_TOWER), towersSurvived[i] * BG_AV_REP_SURVIVING_TOWER);

// World of Warcraft Client Patch 1.7.0 (2005-09-13)
// - Alterac Valley now correctly rewards honor for owning graveyards at
// the end of the game.
Expand Down
4 changes: 2 additions & 2 deletions src/game/Battlegrounds/BattleGroundMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
#include "ObjectMgr.h"
#include "ProgressBar.h"
#include "World.h"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"
#include "Language.h"
#include "GameEventMgr.h"
#include "Policies/SingletonImp.h"
Expand Down Expand Up @@ -175,7 +175,7 @@ GroupQueueInfo* BattleGroundQueue::AddGroup(Player* leader, Group* grp, BattleGr
Player* member = itr->getSource();
if (!member)
continue; // this should never happen

if (excludedMembers && (std::find(excludedMembers->begin(), excludedMembers->end(), member->GetGUIDLow()) != excludedMembers->end()))
continue;

Expand Down
2 changes: 1 addition & 1 deletion src/game/Battlegrounds/BattleGroundWS.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "GameObject.h"
#include "ObjectMgr.h"
#include "BattleGroundMgr.h"
#include "WorldPacket.h"
#include "Server/WorldPacket.h"
#include "Language.h"
#include "World.h"

Expand Down
Loading