mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-13 14:41:28 +00:00
Fix for bot-enabled compile (cursory seems to be ok)
This commit is contained in:
parent
eae7183de2
commit
b475f66014
14
zone/bot.cpp
14
zone/bot.cpp
@ -2508,7 +2508,7 @@ void Bot::AI_Process() {
|
|||||||
if (GetArchetype() == ARCHETYPE_CASTER || GetClass() == ROGUE) {
|
if (GetArchetype() == ARCHETYPE_CASTER || GetClass() == ROGUE) {
|
||||||
if (tar_distance <= melee_distance_max) {
|
if (tar_distance <= melee_distance_max) {
|
||||||
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2520,7 +2520,7 @@ void Bot::AI_Process() {
|
|||||||
if (caster_distance_min && tar_distance < caster_distance_min && !tar->IsFeared()) { // Caster back-off adjustment
|
if (caster_distance_min && tar_distance < caster_distance_min && !tar->IsFeared()) { // Caster back-off adjustment
|
||||||
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
||||||
if (DistanceSquared(Goal, tar->GetPosition()) <= caster_distance_max) {
|
if (DistanceSquared(Goal, tar->GetPosition()) <= caster_distance_max) {
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2528,7 +2528,7 @@ void Bot::AI_Process() {
|
|||||||
else if (tar_distance < melee_distance_min) { // Melee back-off adjustment
|
else if (tar_distance < melee_distance_min) { // Melee back-off adjustment
|
||||||
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
if (PlotPositionAroundTarget(this, Goal.x, Goal.y, Goal.z)) {
|
||||||
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2536,7 +2536,7 @@ void Bot::AI_Process() {
|
|||||||
else if (backstab_weapon && !behind_mob) { // Move the rogue to behind the mob
|
else if (backstab_weapon && !behind_mob) { // Move the rogue to behind the mob
|
||||||
if (PlotPositionAroundTarget(tar, Goal.x, Goal.y, Goal.z)) {
|
if (PlotPositionAroundTarget(tar, Goal.x, Goal.y, Goal.z)) {
|
||||||
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotRunspeed(), true, false); // rogues are agile enough to run in melee range
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotRunspeed(), true, false); // rogues are agile enough to run in melee range
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2547,7 +2547,7 @@ void Bot::AI_Process() {
|
|||||||
PlotPositionAroundTarget(tar, Goal.x, Goal.y, Goal.z)) // If we're behind the mob, we can attack when it's enraged
|
PlotPositionAroundTarget(tar, Goal.x, Goal.y, Goal.z)) // If we're behind the mob, we can attack when it's enraged
|
||||||
{
|
{
|
||||||
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
if (DistanceSquared(Goal, tar->GetPosition()) <= melee_distance_max) {
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotWalkspeed(), true, false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2699,7 +2699,7 @@ void Bot::AI_Process() {
|
|||||||
tar_ndx = 20;
|
tar_ndx = 20;
|
||||||
}
|
}
|
||||||
|
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, GetBotRunspeed());
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, GetBotRunspeed());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -2827,7 +2827,7 @@ void Bot::AI_Process() {
|
|||||||
tar_ndx = 20;
|
tar_ndx = 20;
|
||||||
}
|
}
|
||||||
|
|
||||||
CalculateNewPosition2(Goal.x, Goal.y, Goal.z, speed);
|
CalculateNewPosition(Goal.x, Goal.y, Goal.z, speed);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user