mirror of
https://github.com/liyunfan1223/mod-playerbots.git
synced 2026-02-20 18:10:02 +01:00
Defense check on the player itself
This commit is contained in:
parent
7f64dc20c0
commit
3bc576f7fb
@ -209,8 +209,8 @@ public:
|
||||
|
||||
void OnPlayerGiveXP(Player* player, uint32& amount, Unit* /*victim*/, uint8 /*xpSource*/) override
|
||||
{
|
||||
// when default no XP scaling.
|
||||
if (sPlayerbotAIConfig->randomBotXPRate == 1.0)
|
||||
// early return
|
||||
if (sPlayerbotAIConfig->randomBotXPRate == 1.0 || !player)
|
||||
return;
|
||||
|
||||
// when player is no bot.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user