Redoing movement to introduce proper rotation

This commit is contained in:
KimLS
2018-09-24 22:41:53 -07:00
parent 1aa97957d8
commit 29ea65a71e
25 changed files with 423 additions and 1311 deletions
+2 -7
View File
@@ -93,7 +93,7 @@ void NPC::StopWandering()
{ // stops a mob from wandering, takes him off grid and sends him back to spawn point
roamer = false;
CastToNPC()->SetGrid(0);
SendPosition();
StopNavigation();
Log(Logs::Detail, Logs::Pathing, "Stop Wandering requested.");
return;
}
@@ -150,7 +150,7 @@ void NPC::PauseWandering(int pausetime)
moving = false;
DistractedFromGrid = true;
Log(Logs::Detail, Logs::Pathing, "Paused Wandering requested. Grid %d. Resuming in %d ms (0=not until told)", GetGrid(), pausetime);
SendPosition();
StopNavigation();
if (pausetime < 1) { // negative grid number stops him dead in his tracks until ResumeWandering()
SetGrid(0 - GetGrid());
}
@@ -619,11 +619,6 @@ float Mob::GetFixedZ(const glm::vec3 &destination, int32 z_find_offset) {
return new_z;
}
void Mob::DumpMovement(Client *to)
{
mMovementManager->Dump(this, to);
}
void Mob::FixZ(int32 z_find_offset /*= 5*/, bool fix_client_z /*= false*/) {
glm::vec3 current_loc(m_Position);