Ask Question

Name:
Title:
Your Question:

Answer Question

Name:
Your Answer:
User Submitted Source Code!


Description:
  j
Language: C/C++
Code:
#define WPM mem.Write
#define RPM mem.Read
 
typedef struct Vector {
     float x, y, z;
}Vector;
 
void rsc() {
     while (true) {
          DWORD PlayerBase = RPM<DWORD>(Client + dw_LocalPlayer);
          DWORD ClientState = RPM<DWORD>(Engine + dwClientState);
          static Vector oldAimPunch;
          static Vector fixedAngle;
 
          if (GetKeyState(VK_LBUTTON))
          {
               Vector aimpunch = RPM<Vector>(PlayerBase + m_aimPunchAngle);
               aimPunch.x = aimPunch.x * 2.f;
               aimPunch.y = aimPunch.y * 2.f;
 
               Vector viewAngle = RPM<Vector>(ClientState + dwClientState_ViewAngles);
               fixedAngle.x = viewAngle.x - (aimPunch.x - oldAimPunch.x);
               fixedAngle.y = viewAngle.y - (aimPunch.y - oldAimPunch.y);
               WPM<Vector>(ClientState + dwClientState_ViewAngles, fixedAngle);
 
               oldAimPunch = aimPunch;
          }
          else
          {
               oldAimPunch.x = 0;
               oldAimPunch.y = 0;
               fixedAngle.x = 0;
               fixedAngle.y = 0;
          }
          Sleep(1);
     }
}
Comments: