[Enhancement]Better AutoStrafe
Closed this issue · 2 comments
master-of-darkness commented
Now I can`t create pull request,but I have better autostrafer
`if (pLocal->GetMoveType() == MOVETYPE_LADDER || pLocal->GetMoveType() == MOVETYPE_NOCLIP)
return;
if (pLocal->GetFlags() & FL_ONGROUND)
return;
static CConVar* cl_sidespeed = I::ConVar->FindVar(XorStr("cl_sidespeed"));
if (cl_sidespeed == nullptr)
return;
G::pLocal->GetVelocity().Length2D();
pCmd->flForwardMove = (10000.f / pLocal->GetLocalPlayer()->GetVelocity().Length2D() > 450.f) ? 450.f : 10000.f / pLocal->GetLocalPlayer()->GetVelocity().Length2D();
pCmd->flSideMove = (pCmd->sMouseDeltaX != 0) ? (pCmd->sMouseDeltaX < 0.0f) ? -450.f : 450.f : (pCmd->iCommandNumber & 1) ? -450.f : 450.f;`
Deleted user commented
????
pLocal->GetLocalPlayer()->GetVelocity()
why not just pLocal->GetVelocity()
rollraw commented
don't think it would be really better, also in case of base practically pointless