Stop sliding

This commit is contained in:
ineedbots 2020-09-17 00:56:11 -06:00 committed by GitHub
parent 030eba1c62
commit a9dc7e669b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -157,6 +157,7 @@ resetBotVars()
self.bot.runningafter = false; self.bot.runningafter = false;
self.bot.fire_pressed = false; self.bot.fire_pressed = false;
self.bot.is_frozen_internal = true;
self.bot.ads_pressed = false; self.bot.ads_pressed = false;
self.bot.ads_lowest = 9; self.bot.ads_lowest = 9;
@ -853,7 +854,7 @@ moveHack()
// clamp to ground // clamp to ground
trace = physicsTrace(self.origin + (0.0,0.0,50.0), self.origin + (0.0,0.0,-40.0), false, undefined); trace = physicsTrace(self.origin + (0.0,0.0,50.0), self.origin + (0.0,0.0,-40.0), false, undefined);
if(!self.bot.jumping && (trace[2] - (self.origin[2]-40.0)) > 0.0 && ((self.origin[2]+50.0) - trace[2]) > 0.0) if(!self.bot.jumping && self.bot.is_frozen_internal && (trace[2] - (self.origin[2]-40.0)) > 0.0 && ((self.origin[2]+50.0) - trace[2]) > 0.0)
{ {
self SetOrigin(trace); self SetOrigin(trace);
} }
@ -899,6 +900,7 @@ fireHack()
if (self.bot.isfrozen) if (self.bot.isfrozen)
shouldFire = false; shouldFire = false;
self.bot.is_frozen_internal = !shouldFire;
self FreezeControls(!shouldFire); self FreezeControls(!shouldFire);
} }
} }