Skip to content
This repository has been archived by the owner on Nov 5, 2018. It is now read-only.

LegitStrafe Changes #735

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

LegitStrafe Changes #735

wants to merge 3 commits into from

Conversation

rennmaus25
Copy link

Since I fucked up last time, now with proper formatting.
Made it possible to strafe while pressing the "move" (WASD) buttons. It's a lot more convenient in my opinion.

Made it possible to strafe while pressing the move keys
now noshoot alows shooting when your looking at the enemy which makes a lot more sense in my opinion
Copy link
Contributor

@meyer9 meyer9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style changes and suggestions

trace->TraceRay(ray, 0x46004003, &traceFilter, &tr);
C_BasePlayer* target = (C_BasePlayer*) tr.m_pEntityHit;
//if the player your aiming at is the aimbot target you can shoot
if(target==player)return;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

space before and after if parentheses

traceFilter.pSkip = localplayer;
trace->TraceRay(ray, 0x46004003, &traceFilter, &tr);
C_BasePlayer* target = (C_BasePlayer*) tr.m_pEntityHit;
//if the player your aiming at is the aimbot target you can shoot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

space after // in comments

if (cmd->mousedx <= 1 && cmd->mousedx >= -1)
return;

switch (Settings::AutoStrafe::type)
{
case AutostrafeType::AS_FORWARDS:
cmd->sidemove = cmd->mousedx < 0.f ? -450.f : 450.f;
cmd->forwardmove=0.f;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see above

if (cmd->mousedx <= 1 && cmd->mousedx >= -1)
return;

switch (Settings::AutoStrafe::type)
{
case AutostrafeType::AS_FORWARDS:
cmd->sidemove = cmd->mousedx < 0.f ? -450.f : 450.f;
cmd->forwardmove=0.f;
cmd->sidemove = cmd->mousedx < 0.f ? -450.f :cmd->mousedx==0?0.f: 450.f;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cmd->sidemove = cmd->mousedx < 0.f ? -450.f : cmd->mousedx == 0 ? 0.f : 450.f;

This could also be split into separate if statements to make it more clear what is going on.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants