ЗАЧЕМ ДУМАТЬ ЕСЛИ МОЖНО НЕ ДУМАТЬ
-
Автор темы
- #1
Почему скамится вх ?
вот код вх
вот код вх
C++:
#include "includes.h"
#include "WallHack.h"
#include "Vectors.h"
#include "offsetsM.h"
#include "Address.h"
#include "UnityFunctions.h"
#include <iostream>
class Vector2WH
{
public:
Vector2 Pos[2];
};
Vector2WH GetPosToRender(int i)
{
Addrs addrs;
BotsController* botController = addrs.BotsControllerR;
if(addrs.gameState == 16)
return { -1000,-1000,0 };
if (botController)
{
if(addrs.mController == NULL)
return { -1000,-1000,0 };
if (addrs.deathPos != 0)
{
if (addrs.goCamera == NULL)
return { -1000,-1000,0 };
}
uintptr_t* EnemyGameObject = botController->BotsGo->go[i];
if (EnemyGameObject)
{
uintptr_t* Transform = UnityFunct::GetTransform(EnemyGameObject, nullptr);
Vector3 TransformPos = UnityFunct::TranfsormGetposes(Transform, nullptr);
uintptr_t camera = UnityFunct::CameraGetCur(nullptr);
if (camera)
{
Vector3 screenpos = UnityFunct::WorldToScreen(camera, TransformPos, UnityFunct::GetEye(camera, nullptr), nullptr);
if (screenpos.z >= 1.0f)
{
Vector3 screenposH = UnityFunct::WorldToScreen(camera, { TransformPos.x,TransformPos.y + 2,TransformPos.z}, UnityFunct::GetEye(camera, nullptr), nullptr);
if (screenposH.z >= 1.0f)
{
Vector2WH posArray;
posArray.Pos[0] = { screenpos.x,UnityFunct::GetHScreen(nullptr) - screenpos.y,3 };
posArray.Pos[1] = { screenposH.x,UnityFunct::GetHScreen(nullptr) - screenposH.y,3 };
float width = abs((UnityFunct::GetHScreen(nullptr) - screenposH.y) - (UnityFunct::GetHScreen(nullptr) - screenpos.y)) * 0.3f;
return { posArray.Pos[0].x + width, posArray.Pos[0].y ,3,posArray.Pos[1].x - width, posArray.Pos[1].y,3 };
}
}
}
}
}
return { -1000,-1000,0 };
}
int GetNumPlayer()
{
Addrs addrs;
BotsController* botController = addrs.BotsControllerR;
if (addrs.gameState == 16)
return;
if (addrs.mController == NULL)
return;
if (addrs.deathPos != 0)
{
if (addrs.goCamera == NULL)
return;
}
if (botController)
{
return botController->BotsGo->Count;
}
return 0;
}
void WallHack::Render()
{
for (int i = 0; i < GetNumPlayer(); i++)
{
Vector2WH pos = GetPosToRender(i);
if (pos.Pos[0].d == 3 && pos.Pos[0].y >= 0)
ImGui::GetBackgroundDrawList()->AddRect({ pos.Pos[0].x,pos.Pos[0].y }, { pos.Pos[1].x,pos.Pos[1].y }, ImColor{ 255,0,0,255 }, 0, 15, 2);
}
}