Начинающий
- Статус
- Оффлайн
- Регистрация
- 8 Май 2026
- Сообщения
- 5
- Реакции
- 0
static void* (*GetGameplayInstance)() = (void*(*)())getRealOffset(0x1020AC0DC);
static void* (*GetLocalPawn)() = (void*(*)())getRealOffset(0x1020AC77C);
static bool (*IsAlive)(void*) = (bool(*)(void*))getRealOffset(0x104085620);
static monoString* (*get_NickName)(void*) = (monoString*(*)(void*))getRealOffset(0x1023B58E0);
static bool (*get_IsBot)(void*) = (bool(*)(void*))getRealOffset(0x1023BADC0);
static bool (*IsRobot)(void*) = (bool(*)(void*))getRealOffset(0x1023BAFC4);
static void* (*GetComponentTransform)(void*) = (void*(*)(void*))getRealOffset(0x10767F56C);
static void (*GetTransformPosition)(void*, Vector3*) = (void(*)(void*, Vector3*))getRealOffset(0x1076F4870);
static void* (*GetMainCamera)() = (void*(*)())getRealOffset(0x107679B9C);
static Matrix4x4 (*GetWorldToCameraMatrix)(void*) = (Matrix4x4(*)(void*))getRealOffset(0x107679460);
static Matrix4x4 (*GetProjectionMatrix)(void*) = (Matrix4x4(*)(void*))getRealOffset(0x107679548);
static float (*GetHealth)(void*) = (float(*)(void*))getRealOffset(0x10172CFD4);
static void (*SetHealth)(void*, float) = (void(*)(void*, float))getRealOffset(0x10172CFDC);
static bool (*IsFullHPProgressBar)(void*) = (bool(*)(void*))getRealOffset(0x10172CFE4);
static inline Vector3 GetPlayerPosition(void* player) {
if (!player) return Vector3::Zero();
Vector3 loc = Vector3::Zero();
void* transform = GetComponentTransform(player);
if (transform) GetTransformPosition(transform, &loc);
return loc;
}
static inline Vector3 GetTransformPositionInternal(void* transform) {
if (!transform) return Vector3::Zero();
Vector3 loc = Vector3::Zero();
GetTransformPosition(transform, &loc);
return loc;
}
static inline Matrix4x4 GetWorldToCamera() {
void* cam = GetMainCamera();
return cam ? GetWorldToCameraMatrix(cam) : Matrix4x4();
}
static inline Matrix4x4 GetProjectionMatrixInternal() {
void* cam = GetMainCamera();
return cam ? GetProjectionMatrix(cam) : Matrix4x4();
}
static inline Vector4 GetViewCoords(Vector3 p, Matrix4x4 mv) {
return Vector4(
p.x * mv[0][0] + p.y * mv[1][0] + p.z * mv[2][0] + mv[3][0],
p.x * mv[0][1] + p.y * mv[1][1] + p.z * mv[2][1] + mv[3][1],
p.x * mv[0][2] + p.y * mv[1][2] + p.z * mv[2][2] + mv[3][2],
p.x * mv[0][3] + p.y * mv[1][3] + p.z * mv[2][3] + mv[3][3]
);
}
static inline Vector4 GetClipCoords(Vector4 v, Matrix4x4 proj) {
return Vector4(
v.X * proj[0][0] + v.Y * proj[1][0] + v.Z * proj[2][0] + v.W * proj[3][0],
v.X * proj[0][1] + v.Y * proj[1][1] + v.Z * proj[2][1] + v.W * proj[3][1],
v.X * proj[0][2] + v.Y * proj[1][2] + v.Z * proj[2][2] + v.W * proj[3][2],
v.X * proj[0][3] + v.Y * proj[1][3] + v.Z * proj[2][3] + v.W * proj[3][3]
);
}
static inline Vector3 NormalizeCoords(Vector4 v) {
if (v.W == 0.0f) return Vector3::Zero();
return Vector3(v.X / v.W, v.Y / v.W, v.Z / v.W);
}
static inline Vector2 GetScreenCoords(Vector3 n) {
return Vector2(
(kWidth / 2.0f * n.x) + (n.x + kWidth / 2.0f),
-(kHeight / 2.0f * n.y) + (n.y + kHeight / 2.0f)
);
}
static inline NSString* monoStringToNSString(monoString* str) {
if (!str || str->length <= 0 || str->chars[0] == 0) return @"";
return [[NSString alloc] initWithCharacters:(const unichar*)str->chars length:str->length];
}
static inline bool GetEnemyLabels(float Distance, void* enemyInfo, NSString** labelLine) {
if (!enemyInfo || !labelLine) return false;
int distM = (int)Distance;
monoString* mNick = get_NickName(enemyInfo);
NSString* nameEnemy = mNick ? monoStringToNSString(mNick) : @"";
bool isBot = (get_IsBot && get_IsBot(enemyInfo)) || (IsRobot && IsRobot(enemyInfo));
NSString* label = isBot ? @"BOT" : (nameEnemy.length > 0 ? nameEnemy : @"Player");
*labelLine = [NSString stringWithFormat:@"%@ [%dm]", label, distM];
return true;
}
static void* (*GetLocalPawn)() = (void*(*)())getRealOffset(0x1020AC77C);
static bool (*IsAlive)(void*) = (bool(*)(void*))getRealOffset(0x104085620);
static monoString* (*get_NickName)(void*) = (monoString*(*)(void*))getRealOffset(0x1023B58E0);
static bool (*get_IsBot)(void*) = (bool(*)(void*))getRealOffset(0x1023BADC0);
static bool (*IsRobot)(void*) = (bool(*)(void*))getRealOffset(0x1023BAFC4);
static void* (*GetComponentTransform)(void*) = (void*(*)(void*))getRealOffset(0x10767F56C);
static void (*GetTransformPosition)(void*, Vector3*) = (void(*)(void*, Vector3*))getRealOffset(0x1076F4870);
static void* (*GetMainCamera)() = (void*(*)())getRealOffset(0x107679B9C);
static Matrix4x4 (*GetWorldToCameraMatrix)(void*) = (Matrix4x4(*)(void*))getRealOffset(0x107679460);
static Matrix4x4 (*GetProjectionMatrix)(void*) = (Matrix4x4(*)(void*))getRealOffset(0x107679548);
static float (*GetHealth)(void*) = (float(*)(void*))getRealOffset(0x10172CFD4);
static void (*SetHealth)(void*, float) = (void(*)(void*, float))getRealOffset(0x10172CFDC);
static bool (*IsFullHPProgressBar)(void*) = (bool(*)(void*))getRealOffset(0x10172CFE4);
static inline Vector3 GetPlayerPosition(void* player) {
if (!player) return Vector3::Zero();
Vector3 loc = Vector3::Zero();
void* transform = GetComponentTransform(player);
if (transform) GetTransformPosition(transform, &loc);
return loc;
}
static inline Vector3 GetTransformPositionInternal(void* transform) {
if (!transform) return Vector3::Zero();
Vector3 loc = Vector3::Zero();
GetTransformPosition(transform, &loc);
return loc;
}
static inline Matrix4x4 GetWorldToCamera() {
void* cam = GetMainCamera();
return cam ? GetWorldToCameraMatrix(cam) : Matrix4x4();
}
static inline Matrix4x4 GetProjectionMatrixInternal() {
void* cam = GetMainCamera();
return cam ? GetProjectionMatrix(cam) : Matrix4x4();
}
static inline Vector4 GetViewCoords(Vector3 p, Matrix4x4 mv) {
return Vector4(
p.x * mv[0][0] + p.y * mv[1][0] + p.z * mv[2][0] + mv[3][0],
p.x * mv[0][1] + p.y * mv[1][1] + p.z * mv[2][1] + mv[3][1],
p.x * mv[0][2] + p.y * mv[1][2] + p.z * mv[2][2] + mv[3][2],
p.x * mv[0][3] + p.y * mv[1][3] + p.z * mv[2][3] + mv[3][3]
);
}
static inline Vector4 GetClipCoords(Vector4 v, Matrix4x4 proj) {
return Vector4(
v.X * proj[0][0] + v.Y * proj[1][0] + v.Z * proj[2][0] + v.W * proj[3][0],
v.X * proj[0][1] + v.Y * proj[1][1] + v.Z * proj[2][1] + v.W * proj[3][1],
v.X * proj[0][2] + v.Y * proj[1][2] + v.Z * proj[2][2] + v.W * proj[3][2],
v.X * proj[0][3] + v.Y * proj[1][3] + v.Z * proj[2][3] + v.W * proj[3][3]
);
}
static inline Vector3 NormalizeCoords(Vector4 v) {
if (v.W == 0.0f) return Vector3::Zero();
return Vector3(v.X / v.W, v.Y / v.W, v.Z / v.W);
}
static inline Vector2 GetScreenCoords(Vector3 n) {
return Vector2(
(kWidth / 2.0f * n.x) + (n.x + kWidth / 2.0f),
-(kHeight / 2.0f * n.y) + (n.y + kHeight / 2.0f)
);
}
static inline NSString* monoStringToNSString(monoString* str) {
if (!str || str->length <= 0 || str->chars[0] == 0) return @"";
return [[NSString alloc] initWithCharacters:(const unichar*)str->chars length:str->length];
}
static inline bool GetEnemyLabels(float Distance, void* enemyInfo, NSString** labelLine) {
if (!enemyInfo || !labelLine) return false;
int distM = (int)Distance;
monoString* mNick = get_NickName(enemyInfo);
NSString* nameEnemy = mNick ? monoStringToNSString(mNick) : @"";
bool isBot = (get_IsBot && get_IsBot(enemyInfo)) || (IsRobot && IsRobot(enemyInfo));
NSString* label = isBot ? @"BOT" : (nameEnemy.length > 0 ? nameEnemy : @"Player");
*labelLine = [NSString stringWithFormat:@"%@ [%dm]", label, distM];
return true;
}