G_FreeEntity = 0x279140
G_FreeTurret = 0x2B98E8,
G_Find = 0x27894C
G_ModelIndex = 0x276180
G_EntAttach = 0x27783C
G_EntDetach = 0x277A00
G_EntDetachAll = 0x277BB4
SL_FindLowercaseString = 0x48EAB8
SL_GetString = 0x48F108
G_DObjGetWorldTagPos = 0x2781A4
Weapon_RocketLauncher_Fire = 0x2A5C28
G_FireGrenade = 0x215B08
G_EntLink = 0x2AD440
G_EntUnlink = 0x2AD5C0
G_SetOrigin = 0x279698
G_SetAngle = 0x279D78
G_AddEvent = 0x279950
G_GivePlayerWeapon = 0x2A8364
G_InitializeAmmo = 0x1E6838
SetClientViewAngles = 0x1E1D90
Player_Die = 0x1FD510
SV_GetConfigString = 0x2671B0
SV_SetConfigString = 0x34C738
Scr_PlayerKilled = 0x248F20
ScriptEntCmdGetCommandTimes = 0x267208
ScriptMover_SetupMove = 0x268A38
Trace_GetEntityHitID = 0x306F30
G_GetPlayerViewOrigin = 0x1E60D0
G_LocationalTrace = 0x35C5A8
SV_LinkEntity = 0x359C00
SV_UnlinkEntity = 0x359B3C
ClientThink = 0x1E0B38
ClientThink_real = 0x1DF850
BG_GetWeaponDef = 0x607098
G_TempEntity = 0x279740
G_SetModel = 0x277644
G_Spawn = 0x278C60
G_SpawnTurret = 0x2BA5C8
G_SpawnHelicopter = 0x22C558
SP_Turret = 0x2BAE58
SP_script_model = 0x2670E8
SP_script_brushmodel = 0x267074
SP_script_origin = 0x2671B0
R_SetFrameFog = 0x7AA1E0
Add_Ammo = 0x208B48
FPS = 0x3979EC
CheatProtection = 0x3DBF70
ServerDetails = 0xF57FC5
ServerCache = 0xF57FE4
FPS = 0x3979EC
G_LocalizedStringIndex = 0x275D24
G_SoundAliasIndex = 0x4F495C
SV_GameSendServerCommand = 0x34A1DC
Cbuf_AddText = 0x313E88
Key_IsDown = 0x1185BC (Pointer = 0xF0A7CC)
G_GetWeaponIndexForName = 0x2A6BE8
cl_ingame = 0x1CB68E8
vectoangles = 0x3CAE00
vectoyaw = 0x3CAC18
Non-Host | Red Box = 0x783E0 (0x38, 0x60, 0x00, 0x01)
Non-Host | Disable Red Box Perk Check = 0x78604 (0x60, 0x00, 0x00, 0x00)
Non-Host | VSAT = 0x33C60 (0x60, 0x00, 0x00, 0x00)
Non-Host | No Recoil = 0xF9E54 (0x60, 0x00, 0x00, 0x00)
LocalPlayerName = 0x26C067F
level_locals_t = 0x1608100
G_MaterialIndex = 0x276020
G_HudElems = 0x15DDB00
HUDIndexSize = 0x88
To Use these add any of these values to G_Client, Example G_Client + 0x34 = Client Velocity, To Get To The Next Client Just Do A Simple Sum Like G_Client + Value + (clientIndex * 0x580 or you can use this (0x5808 Is G_Client Size)
public UInt32 G_Client(int clientIndex, UInt32 Mod = 0x00)
{
return (0x1780F28+ (UInt32)Mod) + ((UInt32)clientIndex * 0x580;
}
Then you can do G_Client(0, 0x34); - Velocity for client 0
G_Client = 0x1780F28
ClientVelocity = 0x34 //float[3]
ClientFriction = 0xC //float[3]
ClientCurrentWeapon = 0x1B8 //Int32
ClientFreeze = 0x5694 //Int32
ClientViewModel = 0x54F4 //Int32
ClientButtonMonitoring = 0x569C //Int32
ClientAnalogRight = 0x5463, //Int16
ClientAnalogLeft = 0x5460, //Int16
ClientPlayerName = 0x5544 //String
ClientOrigin = 0x28 //float[3]
ClientAngles = 0x56BC //float[3]
ClientCurrentViewModel = 0x54F4 //Int32
ClientTeam = 0x5504 //Int32
ClientIsAlive = 0x55D0 //Int32
ClientStance = 0xFC //Int32
ClientGodMode = 0x18 //Int32
ClientPerks = 0x548 //
ClientPrimaryCamo = 0x2D8 //Int32
ClientSecondaryCamo = 0x2BC //Int32
ClientTactical = 0x30C //Int32
ClientLethal = 0x2F0 //Int32
ClientKillstreak1 = 0x42B //Int32
ClientKillstreak2 = 0x4302 //Int32
ClientKillstreak3 = 0x434 //Int32
PrimaryAmmo = 0x43C //Int32
SecondaryAmmo = 0x438 //Int32
LethalAmmo = 0x440 //Int32
TacticalAmmo = 0x444 //Int32
CurrentWeaponInView = 0x1B8 //Int32 (By Sticky)
LocationSelectorMap = 0x4B0 //Int32
LocationSelectorType = 0x4B4 //Int32
To Use these add any of these values to G_Entity, Example G_Entity + 0x134 = Entity/Client Origin, To Get To The Next Entity Just Do A Simple Sum Like G_Entity + Value + (clientIndex * 0x31C) or you can use this (0x31C Is Entity Size)
public static UInt32 G_Entity(int entityIndex, UInt32 Mod = 0x00)
{
return (0x16B9F20 + (UInt32)Mod) + ((UInt32)entityIndex * 0x31C);
}
Then you can do G_Entity(0, 0x134); - Origin for entity/client 0
G_Entity = 0x16B9F20
G_EntitySize = 0x31C
EntModelIndex = 0x16C //Int32
EntOrigin = 0x134 //float[3]
EntAngles = 0x140 //float[3]
To Use these add any of these values to client_s, To Get To The Next client Just Do A Simple Sum Like client_s + Value + (clientIndex * 0x4E180) or you can use this (0x4E180 Is Index Size)
client_s = 0x1BB6CC0
client_s Size = 0x4E180
Found By SC58
To Use these add any of these values to centity_s, To Get To The Next client Just Do A Simple Sum Like client_s + Value + (clientIndex * 0x374) or you can use this (0x374 Is Index Size)
centity_s = 0x37910610
centity_s Size = 0x374
centity_s Origin = 0x2C
To Use these add any of these values to level_locals_t, Example G_Entity + 0x798 = Level Time.
public static UInt32 level_locals_t(UInt32 Mod = 0x00)
{
return (0x1608100 + (UInt32)Mod);
}
Then you can do level_locals_t(0, 0x79; - level_time
level_locals_t = 0x1608100
ObjectiveIndex = 0x94
LevelTime = 0x798 //Int32
EnablePrecache = 0x40 //Int32
LocationSelectorDefaultSize = 0x2B04 //float
public static void AddEvent(Int32 clientIndex, Int32 Event, Object eventParams)
{
RPC.Call(0x279950, G_Entity(clientIndex), Event, eventParams);
}
public static void playRumble(Int32 clientIndex, Int32 RumbleIndex)
{
if (RumbleIndex != 0)
{ AddEvent(clientIndex, 0x70, RumbleIndex); }
}
public class Offsets
{
//BG_WeaponDef Offsets
public static UInt32
WeaponOffset = 0,
BG_GetNumWeapons = 0x607084,
BG_GetWeaponDef = 0x607098,
weapTypet = 0x1C,
weapClasst = 0x20,
penetrateType_ = 0x24,
ImpactType_ = 0x28,
weapInventoryTypet = 0x2C,
weapFireTypet = 0x30,
OffhandClass_ = 0x34,
weapStancet = 0x38;
//Weapon Indexes
public static UInt32
DefaultWeap = 0,
MP7 = 2,
PDW = 4,
Vector = 6,
MSMC = 8,
Chiqom = 10,
Skorpian = 12,
Peacekeeper = 14,
MTAR = 16,
TYPE25 = 18,
SWAT = 20,
FAL = 28,
M27 = 32,
SCAR = 36,
SMR = 40,
M8A1 = 44,
AN94 = 48,
Remington = 52,
S12 = 53,
KSG = 54,
M1216 = 55,
MK48 = 56,
QBBLSW = 58,
LSAT = 60,
HAMR = 62,
SVUAS = 64,
DSR50 = 65,
Ballista = 66,
XPR50 = 67,
KAP40 = 69,
Tac45 = 71,
Five7 = 72,
Executioner = 74,
B23R = 77,
FiveSeven = 78,
Tac45DW = 79,
B23RDW = 80,
ExecutionerDW = 81,
KAP40DW = 82,
SMAW = 84,
FHJ18 = 85,
RPG = 86,
CombatKnife = 87,
AssaultShield = 89,
Crossbow = 90,
BallisticKnife = 91;
//WeaponDef classes
public class weapFireType_t
{
public static UInt32
Full_Auto = 1,
Single_Shot = 2,
Round_Burst2 = 3,
Round_Burst3 = 4,
Round_Burst4 = 5,
Round_Burst5 = 6,
StackedFire = 7,
Minigun = 8,
ChargedShot = 9,
Jetgun = 10;
}
public class ImpactType
{
public static UInt32
Impact_None = 1,
Bullet_Small = 2,
Bullet_Large = 3,
Bullet_AP = 4,
Bullet_Xtreme = 5,
Shotgun = 6,
Grenade_Bounce = 7,
Grenade_Explode = 8,
Rifle_Gernade = 9,
Rocket_Explode = 10,
Rocket_Explode_Xtreme = 11,
Projectile_dud = 12,
Mortar_Shell = 13,
Tank_Shell = 14,
Bolt = 15,
Blade = 16,
Grenade = 17,
Rocket = 18,
FlashBang = 19;
}
public class OffhandClass
{
public static UInt32
Class_None = 1,
Frag = 2,
Smoke = 3,
Flash = 4,
Gear = 5,
SupplyDropMarker = 6;
}
public class weapStance_t
{
public static UInt32
Standing = 1,
Duck = 2,
Prone = 3;
}
public class weapInventoryType_t
{
public static UInt32
Primary = 1,
Offhand = 2,
Item = 3,
AltMode = 4,
Melee = 5,
dwLeftHand = 6;
}
public class weapClass_t
{
public static UInt32
rifle = 1,
mg = 2,
smg = 3,
spread = 4,
pistol = 5,
grenade = 6,
rocketlauncher = 7,
turret = 8,
non_player = 9,
gas = 10,
item = 11,
melee = 12,
KillstreakStored = 13,
pistol_Spread = 14;
}
public class weapType_t
{
public static UInt32
Bullet = 1,
Grenade = 2,
Projectile = 3,
Binoculars = 4,
Gas = 5,
Bomb = 6,
Mine = 7,
Melee = 8,
RiotShield = 9;
}
public class penetrateType
{
public static UInt32
none = 1,
small = 2,
medium = 3,
large = 4;
}
}
public static class Call
{
public static UInt32 BG_GetWeaponDef(UInt32 WeaponNum)
{
return RPC.Call(Offsets.BG_GetWeaponDef, WeaponNum);
}
public static UInt32 BG_GetNumWeapons(String WeaponName)
{
return RPC.Call(Offsets.BG_GetWeaponDef, WeaponName);
}
public static void ChangeweapType_t(UInt32 weapType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapTypet, weapType - 1);
}
public static void ChangeweapClass_t(UInt32 weapClass_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapClasst, weapClass_t - 1);
}
public static void ChangepenetrateType(UInt32 penetrateType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.penetrateType_, penetrateType - 1);
}
public static void ChangeImpactType(UInt32 ImpactType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.ImpactType_, ImpactType - 1);
}
public static void ChangeweapInventoryType_t(UInt32 weapInventoryType_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapInventoryTypet, weapInventoryType_t - 1);
}
public static void ChangeweapFireType_t(UInt32 weapFireType_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapFireTypet, weapFireType_t - 1);
}
public static void ChangeOffhandClass(UInt32 OffhandClass)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.OffhandClass_, OffhandClass - 1);
}
public static void ChangeweapStance_t(UInt32 weapStance_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapStancet, weapStance_t - 1);
}
}
}
public static Int32 G_GetWeaponIndexForName(string Weapon)
{
return RPC.Call(0x2A6BE8, 0x2100050, Weapon);
}
public static Int32 MagicBullet(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] Direction, UInt32 targetEnt)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (weaponIndex == 0)
Console.Write("MagicBullet() called with unknown weapon name: " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(Offsets.BG_GetWeaponDef, weaponIndex) + 0x1C)) == 1)
Console.Write("MagicBullet() does not work with grenade-type weapons\n");
else
return RPC.Call(0x2A5C28, entityIndex, weaponIndex, 0, Direction, Direction, targetEnt, Direction, startPosition);
return 0;
}
public static Int32 MagicGrenade(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] targetPosition, Int32 timeToBlow)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (Lib.ReadInt32(entityIndex + 0x154) == 0)
Console.Write("MagicGrenade() can only be called on players\n");
else if (weaponIndex == 0)
Console.Write("MagicGrenade() called with unknown weapon name: " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 1)
Console.Write("MagicGrenade() only works with grenade-type weapons\n");
else
return RPC.Call(0x215B08, entityIndex, startPosition, targetPosition, weaponIndex, "", 0, timeToBlow);
return 0;
}
public static void Cbuf_AddText(string Command)
{
RPC.Call(0x313E88, 0, Command);
}
public static void SV_GameSendServerCommand(Int32 clientIndex, String Command)
{
RPC.Call(0x34A1DC, clientIndex, 0, Command);
}
public static void iPrintln(Int32 client, String Text)
{
SV_GameSendServerCommand(client, "O \"" + Text + "\"");
}
public static void iPrintlnBold(Int32 client, String Text)
{
SV_GameSendServerCommand(client, "< \"" + Text + "\"");
}
public static void SetVision(int clientIndex, string Vision, string TransitionTime)
{
SV_GameSendServerCommand(clientIndex, "2 1060 \"" + Vision + "\" " + TransitionTime);
}
public static void setBlur(Int32 transitionTime, Single Strength)
{
SV_GameSendServerCommand(0, "( " + transitionTime + " " + Strength);
}
//Run This Function In A Loop
public static Boolean onPlayerDied(Int32 clientIndex)
{
if (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 1)
return true;
return false;
}
public static Boolean onPlayerSpawned(Int32 clientIndex)
{
if (onPlayerDied(clientIndex))
if (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 0)
return true;
return false;
}
public static void playSound(Int32 clientIndex, String soundName)
{
Int32 soundIndex = RPC.Call(Offsets.G_SoundAliasIndex, soundName);
Functions.SV_GameSendServerCommand(clientIndex, "B " + soundIndex);
}
public static Single[] GetTagOrigin(Int32 entityIndex, String tagName)
{
Int32 Entity = (Int32)G_Entity(entityIndex);
Int32 tagId = RPC.Call(0x48F108, tagName.ToLower(), 0);//SL_GetString
RPC.Call(0x2781A4, Entity, tagId, 0x2600270);//G_DObjGetWorldTagPos
return Lib.ReadSingle(0x2600270, 3);//Returns Origin
}
public static float[] AnglesToForward(float[] Angles, float Distance = 200f)
{
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance), (cp * sy * Distance), (-sp * Distance) };
return Forward;
}
public static float[] PlayerAnglesToForward(int clientIndex, float Distance = 200f)
{
float[] Angles = Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance) + Position[0], (cp * sy * Distance) + Position[1], (-sp * Distance) + Position[2] };
return Forward;
}
public static float[] vectoangles(float[] Angles)
{
float forward;
float yaw, pitch;
float[] angles = new float[3];
if (Angles[1] == 0 && Angles[0] == 0)
{
yaw = 0;
if (Angles[2] > 0) pitch = 90f;
else pitch = 270f;
}
else
{
if (Angles[0] != -1) yaw = (float)(Math.Atan2((double)Angles[1], (double)Angles[0]) * 180f / Math.PI);
else if (Angles[1] > 0) yaw = 90f;
else yaw = 270;
if (yaw < 0) yaw += 360f;
forward = (float)Math.Sqrt((double)(Angles[0] * Angles[0] + Angles[1] * Angles[1]));
pitch = (float)(Math.Atan2((double)Angles[2], (double)forward) * 180f / Math.PI);
if (pitch < 0) pitch += 360f;
}
angles[0] = -pitch;
angles[1] = yaw;
angles[2] = 0;
return angles;
}
public static float[] getVector(float[] point1, float[] point2)
{
return new float[] { (point2[0] - point1[0]), (point2[1] - point1[1]), (point2[2] - point1[2]) };
}
public static float Distance3D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltay = point2[1] - point1[1];
float deltaz = point2[2] - point1[2];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltay * deltay) + (deltaz * deltaz)));
}
public static float Distance2D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltaz = point2[1] - point1[1];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltaz * deltaz)));
}
public static float VecDistance3D(Single[] Vector)
{
return Convert.ToSingle(Math.Sqrt((Vector[0] * Vector[0]) + (Vector[1] * Vector[1]) + (Vector[2] * Vector[2])));
}
public static Single[] VecMultiply(Single[] Vector, Single Value)
{
return new Single[] { Vector[0] *= Value, Vector[1] *= Value, Vector[2] *= Value };
}
public static void vec_scale(float[] vec, float scale, out float[] Forward)
{
Forward = new float[] { vec[0] * scale, vec[1] * scale, vec[2] * scale };
}
public static float[] getPlayerPosition(int clientIndex)
{
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
return Position;
}
public static uint G_Client(int clientIndex, uint Mod = 0x00)
{
return (0x1780F28 + (UInt32)Mod) + ((uint)clientIndex * 0x580;
}
public static uint G_Entity(int entityIndex, uint Mod = 0x00)
{
return (0x16B9F20 + (UInt32)Mod) + ((uint)entityIndex * 0x31C);
}
public static bool ClientIsSameTeam(int clientIndex, int otherPlayer)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x5504)) == Lib.ReadInt32(G_Client(otherPlayer, 0x5504)));
}
public static bool ClientIsInGame(int clientIndex)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x00)) != 0);
}
public static bool ClientIsAlive(int clientIndex)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 0);
}
public static float[] vectoangles(float[] Angles)
{
float forward;
float yaw, pitch;
float[] angles = new float[3];
if (Angles[1] == 0 && Angles[0] == 0)
{
yaw = 0;
if (Angles[2] > 0) pitch = 90f;
else pitch = 270f;
}
else
{
if (Angles[0] != -1) yaw = (float)(Math.Atan2((double)Angles[1], (double)Angles[0]) * 180f / Math.PI);
else if (Angles[1] > 0) yaw = 90f;
else yaw = 270;
if (yaw < 0) yaw += 360f;
forward = (float)Math.Sqrt((double)(Angles[0] * Angles[0] + Angles[1] * Angles[1]));
pitch = (float)(Math.Atan2((double)Angles[2], (double)forward) * 180f / Math.PI);
if (pitch < 0) pitch += 360f;
}
angles[0] = -pitch;
angles[1] = yaw;
angles[2] = 0;
return angles;
}
public static float[] getVector(float[] point1, float[] point2)
{
return new float[] { (point2[0] - point1[0]), (point2[1] - point1[1]), (point2[2] - point1[2]) };
}
public static float Distance3D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltay = point2[1] - point1[1];
float deltaz = point2[2] - point1[2];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltay * deltay) + (deltaz * deltaz)));
}
public static float Distance2D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltaz = point2[1] - point1[1];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltaz * deltaz)));
}
public static void vec_scale(float[] vec, float scale, out float[] Forward)
{
Forward = new float[] { vec[0] * scale, vec[1] * scale, vec[2] * scale };
}
public static int GetNearestPlayer(Int32 clientIndex, Boolean EnemyOnly = false)
{
int nearestClient = 0;
float nearestDistance = 99999999;
for (int i = 0; i < 12; i++)
{
if (i != clientIndex)
{
if ((ClientIsInGame(i)) && ClientIsAlive(i))
{
if (Lib.ReadInt32(G_Client(clientIndex, 0x5504)) != 0 && EnemyOnly)
{
if (!ClientIsSameTeam(clientIndex, i))
{
float Distance = Distance3D(getPlayerPosition(clientIndex), getPlayerPosition(i));
if (Distance < nearestDistance)
{
nearestDistance = Distance;
nearestClient = i;
}
}
}
else
{
float Distance = Distance3D(getPlayerPosition(clientIndex), getPlayerPosition(i));
if (Distance < nearestDistance)
{
nearestDistance = Distance;
nearestClient = i;
}
}
}
}
}
return nearestClient;
}
public static bool[] AimbotStatus = new bool[12];
public static Thread[] AimbotThread = new Thread[12];
private static float CheckStance(int clientIndex)
{
Int32 CurrentStance = Lib.ReadByte(G_Client(clientIndex) + 0xFC + 0x03);
if (CurrentStance == 0x08 || CurrentStance == 0x0A || CurrentStance == 0x48 || CurrentStance == 0x4A)
{ return 44f; }
if (CurrentStance == 0x04 || CurrentStance == 0x06 || CurrentStance == 0x44 || CurrentStance == 0x46)
{ return 14f; }
return 0f;
}
private static float CheckStanceAttacker(int clientIndex)
{
Int32 CurrentStance = Lib.ReadByte(G_Client(clientIndex) + 0xFC + 0x03);
if (CurrentStance == 0x08 || CurrentStance == 0x0A || CurrentStance == 0x48 || CurrentStance == 0x4A)
{ return 46f; }
if (CurrentStance == 0x04 || CurrentStance == 0x06 || CurrentStance == 0x44 || CurrentStance == 0x46)
{ return 18f; }
return 0f;
}
private static void InitializeAimbot(int clientIndex)
{
PS3.Reconnect();
while (AimbotStatus[clientIndex])
{
int nearestPlayer = GetNearestPlayer(clientIndex);
if (nearestPlayer != clientIndex)
{
if (UnfairAimbot[clientIndex] == false && AimingRequired[clientIndex] == false)
{
SetClientViewAngles(clientIndex, nearestPlayer);
}
}
}
}
public static float[] PlayerAnglesToForward(int clientIndex, float Distance = 200f)
{
float[] Angles = Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance) + Position[0], (cp * sy * Distance) + Position[1], (-sp * Distance) + Position[2] };
return Forward;
}
public static float[] AnglesToForward(float[] Angles, float Distance = 200f)
{
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance), (cp * sy * Distance), (-sp * Distance) };
return Forward;
}
private static void SetClientViewAngles(int clientIndex, int Victim)
{
float[] Vec = getVector(getPlayerPosition(clientIndex), getPlayerPosition(Victim));
Vec[2] -= CheckStance(Victim);
Vec[2] += CheckStanceAttacker(clientIndex);
float[] Angles = vectoangles(Vec);
setViewAngles((UInt32)clientIndex, Angles);
}
public static void setViewAngles(UInt32 clientIndex, float[] Angles)
{
Lib.WriteSingle(0x10040000, Angles);
RPC.Call(0x1E1D90, G_Entity((Int32)clientIndex), 0x10040000);
}
public static float[] getViewAngles(int clientIndex)
{
return Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
}
public static void G_EntAttach(Int32 entityIndex, String modelName, String tagName)
{
Int32 tag = RPC.Call(0x48EAB8, tagName);//SL_FindLowercaseString(const char* string)
RPC.Call(0x27783C, G_Entity(entityIndex), modelName, tag, 0); //G_EntAttach(gentity_s *ent, cont char *modelName, unsigned int tagName, int ignoreCollision);
}
public static void SetClientViewAngles(int clientIndex, float[] Angles)
{
PS3.WriteSingle(0x10004000, Angles);
RPC.Call(0x1E1D90, G_Entity(clientIndex), Angles);
}
public static void SpinMode(int clientIndex, float Speed, string Direction = "Right")
{
if (Direction == "Left")
{
for (float X = -180; X < 180; )
{
SetClientViewAngles(clientIndex, new float[] { ReturnViewOrigin(clientIndex)[0], X, ReturnViewOrigin(clientIndex)[2] });
X += (float)Speed;
}
}
else if (Direction == "Right")
{
for (float X = 180; X > -180; )
{
SetClientViewAngles(clientIndex, new float[] { ReturnViewOrigin(clientIndex)[0], X, ReturnViewOrigin(clientIndex)[2] });
X += (float)Speed;
}
}
}
public static float[] ReturnViewOrigin(int clientIndex)
{
return PS3.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
}
public static UInt32 spawnEntity(String ModelName, Single[] Origin, Single[] Angles)
{
UInt32 Entity = (UInt32)RPC.Call(0x278C60);//G_Spawn
Lib.WriteSingle(Entity + 0x134, Origin);//Sets Entity Origin
Lib.WriteSingle((Entity + 0x140), Angles);//Sets Entity Angles
RPC.Call(0x277644, Entity, ModelName);//G_SetModel
RPC.Call(0x2670E8, Entity);//SP_Script_model
return Entity;//Returns Entity Index
}
public static UInt32 spawnTurret(String TurretType, String ModelName, float[] Origin, float[] Angles)
{
UInt32 Entity = (UInt32)RPC.Call(0x278C60);//G_Spawn
Lib.WriteSingle(Entity + 0x134, Origin);//Sets Entity Origin
Lib.WriteSingle((Entity + 0x140), Angles);//Sets Entity Angles
RPC.Call(0x277644, Entity, ModelName);//G_SetModel
RPC.Call(0x2BA5C8, Ent, TurretType);//G_SpawnTurret
return Ent;
}
public static String char_to_wchar(String text)
{
String wchar = text;
for (Int32 i = 0; i < text.Length; i++)
{
wchar = wchar.Insert(i * 2, "\0");
}
return wchar;
}
public static String doKeyboard(Int32 KeyboardType = 2, String Title = "Title", String PresetText = "", Int32 MaxLength = 20)
{
WriteByte(0x467507, (Byte)KeyboardType);
RPC.Call(0x4674AC, 0xD67E980, char_to_wchar(Title), char_to_wchar(PresetText), MaxLength, 0xD57560);
while (ReadInt32(0xD82140) != 0)
continue;
return ReadString(0x03090E22);
}
public static UInt32
DPADUp = 0x34,
DPADDown = 0x38,
DPADLeft = 0x3C,
DPADRight = 0x40;
public static bool DetectButton(int clientIndex, uint Button)
{
Int32 ButtonIndex = PS3.Extensions.ReadInt32(0x94641C + Button);
Int32 B1 = PS3.Extensions.ReadInt32(G_Client(clientIndex) + 0x56B;
Int32 B2 = PS3.Extensions.ReadInt32(G_Client(clientIndex) + 0x56A0);
if ((B1 == ButtonIndex) || (B2 == ButtonIndex))
return true;
return false;
}
public static float[] G_GetPlayerViewOrigin(int clientIndex)
{
PS3.SetMemory(0x2600250, new byte[0xC]);
RPC.Call(0x1E60D0, G_Client(clientIndex), 0x2600250);
return ReadSingle(0x2600250, 3);
}
public static void G_LocationalTrace(int Trace, float[] Start, float[] End)
{
RPC.Call(0x35C5A8, Trace, Start, End, 0, 0x280E8B3, 0);
}
public static int Trace_GetEntityHitId(int Trace)
{
return RPC.Call(0x306F30, Trace);
}
public static int TraceEntity(int clientIndex, float TracerDistance)
{
int Trace = 0x25D2B00;
float[] Start = G_GetPlayerViewOrigin(clientIndex);
float[] End = PlayerAnglesToForward(clientIndex, TracerDistance);
G_LocationalTrace(Trace, Start, End);
int Entity = Trace_GetEntityHitId(Trace) & 0xFFFF;
if (Entity < 0x3FE)
{ Entity = (int)G_Entity(Entity); }
else
{ Entity = 0; }
return Entity;
}
public static float[] TraceBullet(int clientIndex, float TracerDistance)
{
int Trace = 0x25D2B00;
float[] Start = G_GetPlayerViewOrigin(clientIndex);
float[] End = PlayerAnglesToForward(clientIndex, TracerDistance);
G_LocationalTrace(Trace, Start, End);
float[] BulletTrace = new float[3];
BulletTrace = new float[] { (((End[0] - Start[0]) * ReadFloat((uint)Trace + 0x10) + Start[0])), (((End[1] - Start[1]) * ReadFloat((uint)Trace + 0x10) + Start[1])), (((End[2] - Start[2]) * ReadFloat((uint)Trace + 0x10) + Start[2])) };
return BulletTrace;
}
public static int precacheShader(string Shader)
{
Lib.WriteInt32(0x1608100 + 0x40, 1);
return RPC.Call(0x276020, Shader);
}
//Enable By Calling Init(); , Not Enable();
private static uint function_address;
public static int Call(uint func_address, params object[] parameters)
{
int length = parameters.Length;
int index = 0;
uint num3 = 0;
uint num4 = 0;
uint num5 = 0;
uint num6 = 0;
while (index < length)
{
if (parameters[index] is int)
{
PS3.Extension.WriteInt32(0x10020000 + (num3 * 4), (int)parameters[index]);
num3++;
}
else if (parameters[index] is uint)
{
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), (uint)parameters[index]);
num3++;
}
else
{
uint num7;
if (parameters[index] is string)
{
num7 = 0x10022000 + (num4 * 0x400);
PS3.Extension.WriteString(num7, Convert.ToString(parameters[index]));
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), num7);
num3++;
num4++;
}
else if (parameters[index] is float)
{
PS3.Extension.WriteFloat(0x10020024 + (num5 * 4), (float)parameters[index]);
num5++;
}
else if (parameters[index] is float[])
{
float[] input = (float[])parameters[index];
num7 = 0x10021000 + (num6 * 4);
Lib.WriteSingle(num7, input);
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), num7);
num3++;
num6 += (uint)input.Length;
}
}
index++;
}
PS3.Extension.WriteUInt32(0x1002004C, func_address);
Thread.Sleep(20);
return PS3.Extension.ReadInt32(0x10020050);
}
public static void Enable()
{
PS3.SetMemory(function_address, new byte[] { 0x4E, 0x80, 0x00, 0x20 });
Thread.Sleep(20);
byte[] memory = new byte[]
{ 0x7C, 0x08, 0x02, 0xA6, 0xF8, 0x01, 0x00, 0x80, 0x3C, 0x60, 0x10, 0x02, 0x81, 0x83, 0x00, 0x4C,
0x2C, 0x0C, 0x00, 0x00, 0x41, 0x82, 0x00, 0x64, 0x80, 0x83, 0x00, 0x04, 0x80, 0xA3, 0x00, 0x08,
0x80, 0xC3, 0x00, 0x0C, 0x80, 0xE3, 0x00, 0x10, 0x81, 0x03, 0x00, 0x14, 0x81, 0x23, 0x00, 0x18,
0x81, 0x43, 0x00, 0x1C, 0x81, 0x63, 0x00, 0x20, 0xC0, 0x23, 0x00, 0x24, 0xc0, 0x43, 0x00, 0x28,
0xC0, 0x63, 0x00, 0x2C, 0xC0, 0x83, 0x00, 0x30, 0xC0, 0xA3, 0x00, 0x34, 0xc0, 0xC3, 0x00, 0x38,
0xC0, 0xE3, 0x00, 0x3C, 0xC1, 0x03, 0x00, 0x40, 0xC1, 0x23, 0x00, 0x48, 0x80, 0x63, 0x00, 0x00,
0x7D, 0x89, 0x03, 0xA6, 0x4E, 0x80, 0x04, 0x21, 0x3C, 0x80, 0x10, 0x02, 0x38, 0xA0, 0x00, 0x00,
0x90, 0xA4, 0x00, 0x4C, 0x90, 0x64, 0x00, 0x50, 0xE8, 0x01, 0x00, 0x80, 0x7C, 0x08, 0x03, 0xA6,
0x38, 0x21, 0x00, 0x70, 0x4E, 0x80, 0x00, 0x20 };
PS3.SetMemory(function_address + 4, memory);
PS3.SetMemory(0x10020000, new byte[0x2854]);
PS3.SetMemory(function_address, new byte[] { 0xF8, 0x21, 0xFF, 0x91 });
}
public static int Init()
{
function_address = 0x7AA1E0;
Enable();
return 0;
}
public static void Player_Die(int Killer, int Victim, int meansOfDeath = 18, int iWeapon = 0)
{
UInt32 Attacker = G_Entity(Killer);
UInt32 Inflictor = G_Entity(Victim);
RPC.Call(0x248F20, Inflictor, Attacker, Attacker, 0xFF, meansOfDeath, iWeapon, 0xD0300AD4C);
Thread.Sleep(100);
}
Code Is To Big For Thread!
[URL="https://pastebin.com/Px0Zs5c8"]Black Ops 2 HUD Elements[/URL] ([COLOR="#FF0000"]Link[/COLOR])
public static Single[] getClientViewAngles(Int32 clientIndex)
{
return Lib.ReadSingle(Offsets.Funcs.G_Client(clientIndex, 0x56BC), 3);
}
public static void setClientViewAngles(Int32 entityIndex, Single[] Angles)
{
if (Lib.ReadInt32((UInt32)entityIndex + 0x154) == 0)
Console.Write("setClientViewAngles can only be called on players\n");
else
RPC.Call(Offsets.SetClientViewAngles, G_Entity(entityIndex), Angles);
}
//Velocity = Speed In A Certain Direction
public static Single[] GetVelocity(Int32 clientIndex)
{
return Lib.ReadSingle(G_Client(clientIndex, 0x34), 3);
}
public static void SetVelocity(Int32 clientIndex, Single[] Velocity)
{
Lib.WriteSingle(G_Client(clientIndex, 0x34), 3);
}
concussion_grenade
death
default
default_night
drown
flare
flash_grenade
infrared
infrared_snow
int_frontend_char_trans
low_health
mp_array
mp_cracked
mp_havoc
mp_mountain
mp_nuked
mp_nuked2
mpintro
mpoutro
neutral
remote_mortar_enhanced
remote_mortar_infrared
taser_mine_shock
tvguided_mp
tvguided_sp
defaultweapon_mp
mp7_mp
pdw57_mp
vector_mp
insas_mp
qcw05_mp
evoskorpion_mp
peacekeeper_mp
tar21_mp
type95_mp
sig556_mp
sa58_mp
hk416_mp
scar_mp
saritch_mp
xm8_mp
an94_mp
870mcs_mp
saiga12_mp
ksg_mp
srm1216_mp
mk48_mp
qbb95_mp
lsat_mp
hamr_mp
svu_mp
dsr50_mp
ballista_mp
as50_mp
kard_dw_mp
fnp45_dw_mp
fiveseven_dw_mp
judge_dw_mp
beretta93r_dw_mp
fiveseven_mp
fnp45_mp
beretta93r_mp
judge_mp
kard_mp
m32_mp
smaw_mp
fhj18_mp
usrpg_mp
knife_held_mp
minigun_mp
riotshield_mp
crossbow_mp
knife_ballistic_mp
frag_grenade_mp
concussion_grenade_mp
sticky_grenade_mp
willy_pete_mp
hatchet_mp
sensor_grenade_mp
bouncingbetty_mp
emp_grenade_mp
satchel_charge_mp
proximity_grenade_mp
claymore_mp
pda_hack_mp
flash_grenade_mp
trophy_system_mp
tactical_insertion_mp
destructible_car_mp
explodable_barrel_mp
vcs_controller_mp
knife_mp
dogs_mp
dog_bite_mp
explosive_bolt_mp
scavenger_item_mp
scavenger_item_hack_mp
smoke_center_mp
proximity_grenade_aoe_mp
briefcase_bomb_mp
briefcase_bomb_defuse_mp
cobra_20mm_mp
inventory_supplydrop_mp
supplydrop_mp
ai_tank_drone_rocket_mp
ai_tank_drone_gun_mp
killstreak_ai_tank_mp
inventory_ai_tank_drop_mp
ai_tank_drop_mp
radar_mp
counteruav_mp
radardirection_mp
emp_mp
cobra_20mm_comlink_mp
heli_gunner_rockets_mp
littlebird_guard_minigun_mp
helicopter_comlink_mp
helicopter_guard_mp
helicopter_player_gunner_mp
chopper_minigun_mp
inventory_minigun_mp
inventory_m32_mp
missile_drone_projectile_mp
inventory_missile_drone_mp
missile_drone_mp
missile_swarm_projectile_mp
missile_swarm_mp
planemortar_mp
rc_car_weapon_mp
rcbomb_mp
remote_missile_missile_mp
remote_missile_bomblet_mp
remote_missile_mp
remote_mortar_missile_mp
remote_mortar_mp
qrdrone_turret_mp
killstreak_qrdrone_mp
straferun_gun_mp
straferun_rockets_mp
straferun_mp
auto_gun_turret_mp
microwave_turret_mp
killstreak_remote_turret_mp
autoturret_mp
turret_drop_mp
microwaveturret_mp
microwaveturret_drop_mp
auto_gun_turret_mp
heli_gunner_rockets_mp
straferun_rockets_mp
chopper_minigun_mp
mounted_turret_stand ([COLOR="#FF0000"]Must Be Precached, Works On Turbine[/COLOR])
j_head
j_neck
j_helmet
j_mainroot
j_spine
j_spine4
j_spineupper
j_spinelower
j_elbow_ri
j_elbow_le
j_wrist_ri
j_wrist_le
j_wristtwist_ri
j_wristtwist_le
j_knee_ri
j_knee_le
j_ankle_ri
j_ankle_le
j_clavicle_ri
j_clavicle_le
j_shoulder_ri
j_shoulder_le
j_hip_ri
j_hip_le
j_ball_ri
j_ball_le
tag_origin
tag_eye
tag_weapon
tag_weapon_right
tag_weapon_left
tag_inhand
default
concussion_grenade_mp
tabun_gas_mp
tabun_gas_nokick_mp
proximity_grenade
proximity_grenade_exit
flashbang
frag_grenade_mp
damage_mp
straferun
mp_radiation_high
mp_radiation_med
mp_radiation_low
vcs
ingame_controls
ingame_options
popup_leavegame
scoreboard
spectate
team_marinesopfor
changeclass
initteam_marines
class
initteam_opfor
changeclass_wager
changeclass_custom
changeclass_barebones
sidebet
sidebet_player
endgameupdate
action_seals
faction_pmc
white
black
perk_lightweight
perk_flak_jacket
perk_blind_eye
perk_hardline
perk_ghost
perk_hardwired
perk_scavenger
perk_cold_blooded
perk_fast_hands
perk_warrior
perk_dexterity
perk_hacker
perk_ninja
perk_marathon
perk_tactical_mask
perk_awareness
perk_null
killstreak_null
killstreak_null_drop
hud_ks_rcbomb
hud_ks_rcbomb_drop
hud_ks_u2_spyplane
hud_ks_u2_spyplane_drop
hud_ks_harpy_single
hud_ks_harpy_single_drop
hud_ks_counter_uav
hud_ks_counter_uav_drop
hud_ks_supply_drop
hud_supply_drop_drop
hud_ks_microwave_turret
hud_ks_microwave_turret_drop
hud_ks_predator
hud_ks_predator_drop
hud_ks_planemortar
hud_ks_planemortar_drop
hud_ks_auto_turret
hud_ks_auto_turret_drop
hud_ks_minigun
hud_ks_minigun_drop
hud_ks_m32
hud_ks_m32_drop
hud_ks_qr_drone
hud_ks_qr_drone_drop
hud_ks_talon
hud_ks_talon_drop
hud_ks_ai_helicopter
hud_ks_ai_helicopter_drop
hud_ks_spy_sat
hud_ks_spy_sat_drop
hud_ks_littlebird
hud_ks_littlebird_drop
hud_ks_straferun
hud_ks_straferun_drop
hud_ks_emp
hud_ks_emp_drop
hud_ks_reaper
hud_ks_reaper_drop
hud_ks_heli_gunner
hud_ks_heli_gunner_drop
hud_ks_dogs
hud_ks_dogs_drop
hud_ks_harpy
hud_ks_harpy_drop
hud_ks_player_helicopter
hud_ks_player_helicopter_drop
waypoint_second_chance
rank_pfc
rank_lcpl
rank_cpl
rank_sgt
rank_ssgt
rank_gysgt
rank_msgt
rank_mgysgt
rank_2ndlt
rank_lt
rank_cpt
rank_maj
rank_ltcol
rank_col
rank_bgen
rank_majgen
rank_ltgen
rank_gen
rank_com
rank_prestige01
rank_prestige02
rank_prestige03
rank_prestige04
rank_prestige05
rank_prestige06
rank_prestige07
rank_prestige08
rank_prestige09
rank_prestige10
rank_prestige11
progress_bar_bg
progress_bar_fg
progress_bar_fill
score_bar_bg
mpflag_spectator
hud_scavenger_pickup
gfx_fxt_fx_screen_droplets_02
damage_feedback
damage_feedback_flak
damage_feedback_tac
overlay_low_health
objpoint_default
compass_supply_drop_black
compass_supply_drop_green
compass_supply_drop_red
waypoint_recon_artillery_strike
hud_ks_m202
hud_ks_m202_drop
hud_ammo_refill
hud_ammo_refill_drop
hud_ks_ai_tank_drop
headicon_dead
mech_check_fill
mech_flame_bar
mech_flame_arrow_flipped
mp_hud_cluster_status
mp_hud_armed
mp_hud_deployed
reticle_side_round_big_top
reticle_side_round_big_right
reticle_side_round_big_left
reticle_side_round_big_bottom
hud_remote_missile_target
compass_lodestar
veh_hud_target
veh_hud_target_marked
veh_hud_target_unmarked
compassping_sentry_enemy
compassping_enemy_uav
hud_fofbox_hostile_vehicle
mp_hud_signal_strong
mp_hud_signal_failure
[URL="https://pastebin.com/TVvqC2Kw"]Complete Sound List[/URL]
public static void G_AddEvent(uint Client, int Event, uint EventParam)
{
RPC.Call(0x279950, 0x16B9F20 + 0x31C * Client, Event, EventParam);
}
public static void MagicBullet(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] Direction, UInt32 targetEnt)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (weaponIndex == 0)
Console.Write("MagicBullet() called with unknown weapon name " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 2)
Console.Write("MagicBullet() does not work with grenade-type weapons\n");
else
RPC.Call(0x2A5C28, entityIndex, weaponIndex, 0, Direction, Direction, targetEnt, Direction, startPosition);
}
public static void MagicGrenade(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] targetPosition, Int32 timeToBlow)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (Lib.ReadInt32(entityIndex + 0x154) == 0)
Console.Write("MagicGrenade() can only be called on players\n");
else if (weaponIndex == 0)
Console.Write("MagicGrenade() called with unknown weapon name " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 1)
Console.Write("MagicGrenade() only works with grenade-type weapons\n");
else
RPC.Call(0x215B08, entityIndex, startPosition, targetPosition, weaponIndex, "", 0, timeToBlow);
}
public static void MagicBullet(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] Direction, UInt32 targetEnt)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (weaponIndex == 0)
Console.Write("MagicBullet() called with unknown weapon name " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 2)
Console.Write("MagicBullet() does not work with grenade-type weapons\n");
else
RPC.Call(0x2A5C28, entityIndex, weaponIndex, 0, Direction, Direction, targetEnt, Direction, startPosition);
}
public static void MagicGrenade(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] targetPosition, Int32 timeToBlow)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (Lib.ReadInt32(entityIndex + 0x154) == 0)
Console.Write("MagicGrenade() can only be called on players\n");
else if (weaponIndex == 0)
Console.Write("MagicGrenade() called with unknown weapon name " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 1)
Console.Write("MagicGrenade() only works with grenade-type weapons\n");
else
RPC.Call(0x215B08, entityIndex, startPosition, targetPosition, weaponIndex, "", 0, timeToBlow);
}
G_FreeEntity = 0x279140
G_FreeTurret = 0x2B98E8,
G_Find = 0x27894C
G_ModelIndex = 0x276180
G_EntAttach = 0x27783C
G_EntDetach = 0x277A00
G_EntDetachAll = 0x277BB4
SL_FindLowercaseString = 0x48EAB8
SL_GetString = 0x48F108
G_DObjGetWorldTagPos = 0x2781A4
Weapon_RocketLauncher_Fire = 0x2A5C28
G_FireGrenade = 0x215B08
G_EntLink = 0x2AD440
G_EntUnlink = 0x2AD5C0
G_SetOrigin = 0x279698
G_SetAngle = 0x279D78
G_AddEvent = 0x279950
G_GivePlayerWeapon = 0x2A8364
G_InitializeAmmo = 0x1E6838
SetClientViewAngles = 0x1E1D90
Player_Die = 0x1FD510
SV_GetConfigString = 0x2671B0
SV_SetConfigString = 0x34C738
Scr_PlayerKilled = 0x248F20
ScriptEntCmdGetCommandTimes = 0x267208
ScriptMover_SetupMove = 0x268A38
Trace_GetEntityHitID = 0x306F30
G_GetPlayerViewOrigin = 0x1E60D0
G_LocationalTrace = 0x35C5A8
SV_LinkEntity = 0x359C00
SV_UnlinkEntity = 0x359B3C
ClientThink = 0x1E0B38
ClientThink_real = 0x1DF850
BG_GetWeaponDef = 0x607098
G_TempEntity = 0x279740
G_SetModel = 0x277644
G_Spawn = 0x278C60
G_SpawnTurret = 0x2BA5C8
G_SpawnHelicopter = 0x22C558
SP_Turret = 0x2BAE58
SP_script_model = 0x2670E8
SP_script_brushmodel = 0x267074
SP_script_origin = 0x2671B0
R_SetFrameFog = 0x7AA1E0
Add_Ammo = 0x208B48
FPS = 0x3979EC
CheatProtection = 0x3DBF70
ServerDetails = 0xF57FC5
ServerCache = 0xF57FE4
FPS = 0x3979EC
G_LocalizedStringIndex = 0x275D24
G_SoundAliasIndex = 0x4F495C
SV_GameSendServerCommand = 0x34A1DC
Cbuf_AddText = 0x313E88
Key_IsDown = 0x1185BC (Pointer = 0xF0A7CC)
G_GetWeaponIndexForName = 0x2A6BE8
cl_ingame = 0x1CB68E8
vectoangles = 0x3CAE00
vectoyaw = 0x3CAC18
Non-Host | Red Box = 0x783E0 (0x38, 0x60, 0x00, 0x01)
Non-Host | Disable Red Box Perk Check = 0x78604 (0x60, 0x00, 0x00, 0x00)
Non-Host | VSAT = 0x33C60 (0x60, 0x00, 0x00, 0x00)
Non-Host | No Recoil = 0xF9E54 (0x60, 0x00, 0x00, 0x00)
LocalPlayerName = 0x26C067F
level_locals_t = 0x1608100
G_MaterialIndex = 0x276020
G_HudElems = 0x15DDB00
HUDIndexSize = 0x88
To Use these add any of these values to G_Client, Example G_Client + 0x34 = Client Velocity, To Get To The Next Client Just Do A Simple Sum Like G_Client + Value + (clientIndex * 0x580 or you can use this (0x5808 Is G_Client Size)
public UInt32 G_Client(int clientIndex, UInt32 Mod = 0x00)
{
return (0x1780F28+ (UInt32)Mod) + ((UInt32)clientIndex * 0x580;
}
Then you can do G_Client(0, 0x34); - Velocity for client 0
G_Client = 0x1780F28
ClientVelocity = 0x34 //float[3]
ClientFriction = 0xC //float[3]
ClientCurrentWeapon = 0x1B8 //Int32
ClientFreeze = 0x5694 //Int32
ClientViewModel = 0x54F4 //Int32
ClientButtonMonitoring = 0x569C //Int32
ClientAnalogRight = 0x5463, //Int16
ClientAnalogLeft = 0x5460, //Int16
ClientPlayerName = 0x5544 //String
ClientOrigin = 0x28 //float[3]
ClientAngles = 0x56BC //float[3]
ClientCurrentViewModel = 0x54F4 //Int32
ClientTeam = 0x5504 //Int32
ClientIsAlive = 0x55D0 //Int32
ClientStance = 0xFC //Int32
ClientGodMode = 0x18 //Int32
ClientPerks = 0x548 //
ClientPrimaryCamo = 0x2D8 //Int32
ClientSecondaryCamo = 0x2BC //Int32
ClientTactical = 0x30C //Int32
ClientLethal = 0x2F0 //Int32
ClientKillstreak1 = 0x42B //Int32
ClientKillstreak2 = 0x4302 //Int32
ClientKillstreak3 = 0x434 //Int32
PrimaryAmmo = 0x43C //Int32
SecondaryAmmo = 0x438 //Int32
LethalAmmo = 0x440 //Int32
TacticalAmmo = 0x444 //Int32
CurrentWeaponInView = 0x1B8 //Int32 (By Sticky)
LocationSelectorMap = 0x4B0 //Int32
LocationSelectorType = 0x4B4 //Int32
To Use these add any of these values to G_Entity, Example G_Entity + 0x134 = Entity/Client Origin, To Get To The Next Entity Just Do A Simple Sum Like G_Entity + Value + (clientIndex * 0x31C) or you can use this (0x31C Is Entity Size)
public static UInt32 G_Entity(int entityIndex, UInt32 Mod = 0x00)
{
return (0x16B9F20 + (UInt32)Mod) + ((UInt32)entityIndex * 0x31C);
}
Then you can do G_Entity(0, 0x134); - Origin for entity/client 0
G_Entity = 0x16B9F20
G_EntitySize = 0x31C
EntModelIndex = 0x16C //Int32
EntOrigin = 0x134 //float[3]
EntAngles = 0x140 //float[3]
To Use these add any of these values to client_s, To Get To The Next client Just Do A Simple Sum Like client_s + Value + (clientIndex * 0x4E180) or you can use this (0x4E180 Is Index Size)
client_s = 0x1BB6CC0
client_s Size = 0x4E180
Found By SC58
To Use these add any of these values to centity_s, To Get To The Next client Just Do A Simple Sum Like client_s + Value + (clientIndex * 0x374) or you can use this (0x374 Is Index Size)
centity_s = 0x37910610
centity_s Size = 0x374
centity_s Origin = 0x2C
To Use these add any of these values to level_locals_t, Example G_Entity + 0x798 = Level Time.
public static UInt32 level_locals_t(UInt32 Mod = 0x00)
{
return (0x1608100 + (UInt32)Mod);
}
Then you can do level_locals_t(0, 0x79; - level_time
level_locals_t = 0x1608100
ObjectiveIndex = 0x94
LevelTime = 0x798 //Int32
EnablePrecache = 0x40 //Int32
LocationSelectorDefaultSize = 0x2B04 //float
public static void AddEvent(Int32 clientIndex, Int32 Event, Object eventParams)
{
RPC.Call(0x279950, G_Entity(clientIndex), Event, eventParams);
}
public static void playRumble(Int32 clientIndex, Int32 RumbleIndex)
{
if (RumbleIndex != 0)
{ AddEvent(clientIndex, 0x70, RumbleIndex); }
}
public class Offsets
{
//BG_WeaponDef Offsets
public static UInt32
WeaponOffset = 0,
BG_GetNumWeapons = 0x607084,
BG_GetWeaponDef = 0x607098,
weapTypet = 0x1C,
weapClasst = 0x20,
penetrateType_ = 0x24,
ImpactType_ = 0x28,
weapInventoryTypet = 0x2C,
weapFireTypet = 0x30,
OffhandClass_ = 0x34,
weapStancet = 0x38;
//Weapon Indexes
public static UInt32
DefaultWeap = 0,
MP7 = 2,
PDW = 4,
Vector = 6,
MSMC = 8,
Chiqom = 10,
Skorpian = 12,
Peacekeeper = 14,
MTAR = 16,
TYPE25 = 18,
SWAT = 20,
FAL = 28,
M27 = 32,
SCAR = 36,
SMR = 40,
M8A1 = 44,
AN94 = 48,
Remington = 52,
S12 = 53,
KSG = 54,
M1216 = 55,
MK48 = 56,
QBBLSW = 58,
LSAT = 60,
HAMR = 62,
SVUAS = 64,
DSR50 = 65,
Ballista = 66,
XPR50 = 67,
KAP40 = 69,
Tac45 = 71,
Five7 = 72,
Executioner = 74,
B23R = 77,
FiveSeven = 78,
Tac45DW = 79,
B23RDW = 80,
ExecutionerDW = 81,
KAP40DW = 82,
SMAW = 84,
FHJ18 = 85,
RPG = 86,
CombatKnife = 87,
AssaultShield = 89,
Crossbow = 90,
BallisticKnife = 91;
//WeaponDef classes
public class weapFireType_t
{
public static UInt32
Full_Auto = 1,
Single_Shot = 2,
Round_Burst2 = 3,
Round_Burst3 = 4,
Round_Burst4 = 5,
Round_Burst5 = 6,
StackedFire = 7,
Minigun = 8,
ChargedShot = 9,
Jetgun = 10;
}
public class ImpactType
{
public static UInt32
Impact_None = 1,
Bullet_Small = 2,
Bullet_Large = 3,
Bullet_AP = 4,
Bullet_Xtreme = 5,
Shotgun = 6,
Grenade_Bounce = 7,
Grenade_Explode = 8,
Rifle_Gernade = 9,
Rocket_Explode = 10,
Rocket_Explode_Xtreme = 11,
Projectile_dud = 12,
Mortar_Shell = 13,
Tank_Shell = 14,
Bolt = 15,
Blade = 16,
Grenade = 17,
Rocket = 18,
FlashBang = 19;
}
public class OffhandClass
{
public static UInt32
Class_None = 1,
Frag = 2,
Smoke = 3,
Flash = 4,
Gear = 5,
SupplyDropMarker = 6;
}
public class weapStance_t
{
public static UInt32
Standing = 1,
Duck = 2,
Prone = 3;
}
public class weapInventoryType_t
{
public static UInt32
Primary = 1,
Offhand = 2,
Item = 3,
AltMode = 4,
Melee = 5,
dwLeftHand = 6;
}
public class weapClass_t
{
public static UInt32
rifle = 1,
mg = 2,
smg = 3,
spread = 4,
pistol = 5,
grenade = 6,
rocketlauncher = 7,
turret = 8,
non_player = 9,
gas = 10,
item = 11,
melee = 12,
KillstreakStored = 13,
pistol_Spread = 14;
}
public class weapType_t
{
public static UInt32
Bullet = 1,
Grenade = 2,
Projectile = 3,
Binoculars = 4,
Gas = 5,
Bomb = 6,
Mine = 7,
Melee = 8,
RiotShield = 9;
}
public class penetrateType
{
public static UInt32
none = 1,
small = 2,
medium = 3,
large = 4;
}
}
public static class Call
{
public static UInt32 BG_GetWeaponDef(UInt32 WeaponNum)
{
return RPC.Call(Offsets.BG_GetWeaponDef, WeaponNum);
}
public static UInt32 BG_GetNumWeapons(String WeaponName)
{
return RPC.Call(Offsets.BG_GetWeaponDef, WeaponName);
}
public static void ChangeweapType_t(UInt32 weapType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapTypet, weapType - 1);
}
public static void ChangeweapClass_t(UInt32 weapClass_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapClasst, weapClass_t - 1);
}
public static void ChangepenetrateType(UInt32 penetrateType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.penetrateType_, penetrateType - 1);
}
public static void ChangeImpactType(UInt32 ImpactType)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.ImpactType_, ImpactType - 1);
}
public static void ChangeweapInventoryType_t(UInt32 weapInventoryType_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapInventoryTypet, weapInventoryType_t - 1);
}
public static void ChangeweapFireType_t(UInt32 weapFireType_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapFireTypet, weapFireType_t - 1);
}
public static void ChangeOffhandClass(UInt32 OffhandClass)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.OffhandClass_, OffhandClass - 1);
}
public static void ChangeweapStance_t(UInt32 weapStance_t)
{
PS3.Extension.WriteUInt32(Offsets.WeaponOffset + Offsets.weapStancet, weapStance_t - 1);
}
}
}
public static Int32 G_GetWeaponIndexForName(string Weapon)
{
return RPC.Call(0x2A6BE8, 0x2100050, Weapon);
}
public static Int32 MagicBullet(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] Direction, UInt32 targetEnt)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (weaponIndex == 0)
Console.Write("MagicBullet() called with unknown weapon name: " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(Offsets.BG_GetWeaponDef, weaponIndex) + 0x1C)) == 1)
Console.Write("MagicBullet() does not work with grenade-type weapons\n");
else
return RPC.Call(0x2A5C28, entityIndex, weaponIndex, 0, Direction, Direction, targetEnt, Direction, startPosition);
return 0;
}
public static Int32 MagicGrenade(UInt32 entityIndex, String weaponName, Single[] startPosition, Single[] targetPosition, Int32 timeToBlow)
{
Int32 weaponIndex = G_GetWeaponIndexForName(weaponName);
if (Lib.ReadInt32(entityIndex + 0x154) == 0)
Console.Write("MagicGrenade() can only be called on players\n");
else if (weaponIndex == 0)
Console.Write("MagicGrenade() called with unknown weapon name: " + weaponName + "\n");
else if (Lib.ReadInt32((UInt32)(RPC.Call(0x607098, weaponIndex) + 0x1C)) != 1)
Console.Write("MagicGrenade() only works with grenade-type weapons\n");
else
return RPC.Call(0x215B08, entityIndex, startPosition, targetPosition, weaponIndex, "", 0, timeToBlow);
return 0;
}
public static void Cbuf_AddText(string Command)
{
RPC.Call(0x313E88, 0, Command);
}
public static void SV_GameSendServerCommand(Int32 clientIndex, String Command)
{
RPC.Call(0x34A1DC, clientIndex, 0, Command);
}
public static void iPrintln(Int32 client, String Text)
{
SV_GameSendServerCommand(client, "O \"" + Text + "\"");
}
public static void iPrintlnBold(Int32 client, String Text)
{
SV_GameSendServerCommand(client, "< \"" + Text + "\"");
}
public static void SetVision(int clientIndex, string Vision, string TransitionTime)
{
SV_GameSendServerCommand(clientIndex, "2 1060 \"" + Vision + "\" " + TransitionTime);
}
public static void setBlur(Int32 transitionTime, Single Strength)
{
SV_GameSendServerCommand(0, "( " + transitionTime + " " + Strength);
}
//Run This Function In A Loop
public static Boolean onPlayerDied(Int32 clientIndex)
{
if (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 1)
return true;
return false;
}
public static Boolean onPlayerSpawned(Int32 clientIndex)
{
if (onPlayerDied(clientIndex))
if (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 0)
return true;
return false;
}
public static void playSound(Int32 clientIndex, String soundName)
{
Int32 soundIndex = RPC.Call(Offsets.G_SoundAliasIndex, soundName);
Functions.SV_GameSendServerCommand(clientIndex, "B " + soundIndex);
}
public static Single[] GetTagOrigin(Int32 entityIndex, String tagName)
{
Int32 Entity = (Int32)G_Entity(entityIndex);
Int32 tagId = RPC.Call(0x48F108, tagName.ToLower(), 0);//SL_GetString
RPC.Call(0x2781A4, Entity, tagId, 0x2600270);//G_DObjGetWorldTagPos
return Lib.ReadSingle(0x2600270, 3);//Returns Origin
}
public static float[] AnglesToForward(float[] Angles, float Distance = 200f)
{
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance), (cp * sy * Distance), (-sp * Distance) };
return Forward;
}
public static float[] PlayerAnglesToForward(int clientIndex, float Distance = 200f)
{
float[] Angles = Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance) + Position[0], (cp * sy * Distance) + Position[1], (-sp * Distance) + Position[2] };
return Forward;
}
public static float[] vectoangles(float[] Angles)
{
float forward;
float yaw, pitch;
float[] angles = new float[3];
if (Angles[1] == 0 && Angles[0] == 0)
{
yaw = 0;
if (Angles[2] > 0) pitch = 90f;
else pitch = 270f;
}
else
{
if (Angles[0] != -1) yaw = (float)(Math.Atan2((double)Angles[1], (double)Angles[0]) * 180f / Math.PI);
else if (Angles[1] > 0) yaw = 90f;
else yaw = 270;
if (yaw < 0) yaw += 360f;
forward = (float)Math.Sqrt((double)(Angles[0] * Angles[0] + Angles[1] * Angles[1]));
pitch = (float)(Math.Atan2((double)Angles[2], (double)forward) * 180f / Math.PI);
if (pitch < 0) pitch += 360f;
}
angles[0] = -pitch;
angles[1] = yaw;
angles[2] = 0;
return angles;
}
public static float[] getVector(float[] point1, float[] point2)
{
return new float[] { (point2[0] - point1[0]), (point2[1] - point1[1]), (point2[2] - point1[2]) };
}
public static float Distance3D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltay = point2[1] - point1[1];
float deltaz = point2[2] - point1[2];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltay * deltay) + (deltaz * deltaz)));
}
public static float Distance2D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltaz = point2[1] - point1[1];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltaz * deltaz)));
}
public static float VecDistance3D(Single[] Vector)
{
return Convert.ToSingle(Math.Sqrt((Vector[0] * Vector[0]) + (Vector[1] * Vector[1]) + (Vector[2] * Vector[2])));
}
public static Single[] VecMultiply(Single[] Vector, Single Value)
{
return new Single[] { Vector[0] *= Value, Vector[1] *= Value, Vector[2] *= Value };
}
public static void vec_scale(float[] vec, float scale, out float[] Forward)
{
Forward = new float[] { vec[0] * scale, vec[1] * scale, vec[2] * scale };
}
public static float[] getPlayerPosition(int clientIndex)
{
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
return Position;
}
public static uint G_Client(int clientIndex, uint Mod = 0x00)
{
return (0x1780F28 + (UInt32)Mod) + ((uint)clientIndex * 0x580;
}
public static uint G_Entity(int entityIndex, uint Mod = 0x00)
{
return (0x16B9F20 + (UInt32)Mod) + ((uint)entityIndex * 0x31C);
}
public static bool ClientIsSameTeam(int clientIndex, int otherPlayer)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x5504)) == Lib.ReadInt32(G_Client(otherPlayer, 0x5504)));
}
public static bool ClientIsInGame(int clientIndex)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x00)) != 0);
}
public static bool ClientIsAlive(int clientIndex)
{
return (Lib.ReadInt32(G_Client(clientIndex, 0x55D0)) == 0);
}
public static float[] vectoangles(float[] Angles)
{
float forward;
float yaw, pitch;
float[] angles = new float[3];
if (Angles[1] == 0 && Angles[0] == 0)
{
yaw = 0;
if (Angles[2] > 0) pitch = 90f;
else pitch = 270f;
}
else
{
if (Angles[0] != -1) yaw = (float)(Math.Atan2((double)Angles[1], (double)Angles[0]) * 180f / Math.PI);
else if (Angles[1] > 0) yaw = 90f;
else yaw = 270;
if (yaw < 0) yaw += 360f;
forward = (float)Math.Sqrt((double)(Angles[0] * Angles[0] + Angles[1] * Angles[1]));
pitch = (float)(Math.Atan2((double)Angles[2], (double)forward) * 180f / Math.PI);
if (pitch < 0) pitch += 360f;
}
angles[0] = -pitch;
angles[1] = yaw;
angles[2] = 0;
return angles;
}
public static float[] getVector(float[] point1, float[] point2)
{
return new float[] { (point2[0] - point1[0]), (point2[1] - point1[1]), (point2[2] - point1[2]) };
}
public static float Distance3D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltay = point2[1] - point1[1];
float deltaz = point2[2] - point1[2];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltay * deltay) + (deltaz * deltaz)));
}
public static float Distance2D(float[] point1, float[] point2)
{
float deltax = point2[0] - point1[0];
float deltaz = point2[1] - point1[1];
return Convert.ToSingle(Math.Sqrt((deltax * deltax) + (deltaz * deltaz)));
}
public static void vec_scale(float[] vec, float scale, out float[] Forward)
{
Forward = new float[] { vec[0] * scale, vec[1] * scale, vec[2] * scale };
}
public static int GetNearestPlayer(Int32 clientIndex, Boolean EnemyOnly = false)
{
int nearestClient = 0;
float nearestDistance = 99999999;
for (int i = 0; i < 12; i++)
{
if (i != clientIndex)
{
if ((ClientIsInGame(i)) && ClientIsAlive(i))
{
if (Lib.ReadInt32(G_Client(clientIndex, 0x5504)) != 0 && EnemyOnly)
{
if (!ClientIsSameTeam(clientIndex, i))
{
float Distance = Distance3D(getPlayerPosition(clientIndex), getPlayerPosition(i));
if (Distance < nearestDistance)
{
nearestDistance = Distance;
nearestClient = i;
}
}
}
else
{
float Distance = Distance3D(getPlayerPosition(clientIndex), getPlayerPosition(i));
if (Distance < nearestDistance)
{
nearestDistance = Distance;
nearestClient = i;
}
}
}
}
}
return nearestClient;
}
public static bool[] AimbotStatus = new bool[12];
public static Thread[] AimbotThread = new Thread[12];
private static float CheckStance(int clientIndex)
{
Int32 CurrentStance = Lib.ReadByte(G_Client(clientIndex) + 0xFC + 0x03);
if (CurrentStance == 0x08 || CurrentStance == 0x0A || CurrentStance == 0x48 || CurrentStance == 0x4A)
{ return 44f; }
if (CurrentStance == 0x04 || CurrentStance == 0x06 || CurrentStance == 0x44 || CurrentStance == 0x46)
{ return 14f; }
return 0f;
}
private static float CheckStanceAttacker(int clientIndex)
{
Int32 CurrentStance = Lib.ReadByte(G_Client(clientIndex) + 0xFC + 0x03);
if (CurrentStance == 0x08 || CurrentStance == 0x0A || CurrentStance == 0x48 || CurrentStance == 0x4A)
{ return 46f; }
if (CurrentStance == 0x04 || CurrentStance == 0x06 || CurrentStance == 0x44 || CurrentStance == 0x46)
{ return 18f; }
return 0f;
}
private static void InitializeAimbot(int clientIndex)
{
PS3.Reconnect();
while (AimbotStatus[clientIndex])
{
int nearestPlayer = GetNearestPlayer(clientIndex);
if (nearestPlayer != clientIndex)
{
if (UnfairAimbot[clientIndex] == false && AimingRequired[clientIndex] == false)
{
SetClientViewAngles(clientIndex, nearestPlayer);
}
}
}
}
public static float[] PlayerAnglesToForward(int clientIndex, float Distance = 200f)
{
float[] Angles = Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
float[] Position = Lib.ReadSingle(G_Client(clientIndex, 0x2, 3);
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance) + Position[0], (cp * sy * Distance) + Position[1], (-sp * Distance) + Position[2] };
return Forward;
}
public static float[] AnglesToForward(float[] Angles, float Distance = 200f)
{
float angle, sr, sp, sy, cr, cp, cy, PiDiv;
PiDiv = ((float)Math.PI / 180f);
angle = Angles[1] * PiDiv;
sy = (float)Math.Sin(angle);
cy = (float)Math.Cos(angle);
angle = Angles[0] * PiDiv;
sp = (float)Math.Sin(angle);
cp = (float)Math.Cos(angle);
angle = Angles[2] * PiDiv;
sr = (float)Math.Sin(angle);
cr = (float)Math.Cos(angle);
float[] Forward = new float[] { (cp * cy * Distance), (cp * sy * Distance), (-sp * Distance) };
return Forward;
}
private static void SetClientViewAngles(int clientIndex, int Victim)
{
float[] Vec = getVector(getPlayerPosition(clientIndex), getPlayerPosition(Victim));
Vec[2] -= CheckStance(Victim);
Vec[2] += CheckStanceAttacker(clientIndex);
float[] Angles = vectoangles(Vec);
setViewAngles((UInt32)clientIndex, Angles);
}
public static void setViewAngles(UInt32 clientIndex, float[] Angles)
{
Lib.WriteSingle(0x10040000, Angles);
RPC.Call(0x1E1D90, G_Entity((Int32)clientIndex), 0x10040000);
}
public static float[] getViewAngles(int clientIndex)
{
return Lib.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
}
public static void G_EntAttach(Int32 entityIndex, String modelName, String tagName)
{
Int32 tag = RPC.Call(0x48EAB8, tagName);//SL_FindLowercaseString(const char* string)
RPC.Call(0x27783C, G_Entity(entityIndex), modelName, tag, 0); //G_EntAttach(gentity_s *ent, cont char *modelName, unsigned int tagName, int ignoreCollision);
}
public static void SetClientViewAngles(int clientIndex, float[] Angles)
{
PS3.WriteSingle(0x10004000, Angles);
RPC.Call(0x1E1D90, G_Entity(clientIndex), Angles);
}
public static void SpinMode(int clientIndex, float Speed, string Direction = "Right")
{
if (Direction == "Left")
{
for (float X = -180; X < 180; )
{
SetClientViewAngles(clientIndex, new float[] { ReturnViewOrigin(clientIndex)[0], X, ReturnViewOrigin(clientIndex)[2] });
X += (float)Speed;
}
}
else if (Direction == "Right")
{
for (float X = 180; X > -180; )
{
SetClientViewAngles(clientIndex, new float[] { ReturnViewOrigin(clientIndex)[0], X, ReturnViewOrigin(clientIndex)[2] });
X += (float)Speed;
}
}
}
public static float[] ReturnViewOrigin(int clientIndex)
{
return PS3.ReadSingle(G_Client(clientIndex, 0x56BC), 3);
}
public static UInt32 spawnEntity(String ModelName, Single[] Origin, Single[] Angles)
{
UInt32 Entity = (UInt32)RPC.Call(0x278C60);//G_Spawn
Lib.WriteSingle(Entity + 0x134, Origin);//Sets Entity Origin
Lib.WriteSingle((Entity + 0x140), Angles);//Sets Entity Angles
RPC.Call(0x277644, Entity, ModelName);//G_SetModel
RPC.Call(0x2670E8, Entity);//SP_Script_model
return Entity;//Returns Entity Index
}
public static UInt32 spawnTurret(String TurretType, String ModelName, float[] Origin, float[] Angles)
{
UInt32 Entity = (UInt32)RPC.Call(0x278C60);//G_Spawn
Lib.WriteSingle(Entity + 0x134, Origin);//Sets Entity Origin
Lib.WriteSingle((Entity + 0x140), Angles);//Sets Entity Angles
RPC.Call(0x277644, Entity, ModelName);//G_SetModel
RPC.Call(0x2BA5C8, Ent, TurretType);//G_SpawnTurret
return Ent;
}
public static String char_to_wchar(String text)
{
String wchar = text;
for (Int32 i = 0; i < text.Length; i++)
{
wchar = wchar.Insert(i * 2, "\0");
}
return wchar;
}
public static String doKeyboard(Int32 KeyboardType = 2, String Title = "Title", String PresetText = "", Int32 MaxLength = 20)
{
WriteByte(0x467507, (Byte)KeyboardType);
RPC.Call(0x4674AC, 0xD67E980, char_to_wchar(Title), char_to_wchar(PresetText), MaxLength, 0xD57560);
while (ReadInt32(0xD82140) != 0)
continue;
return ReadString(0x03090E22);
}
public static UInt32
DPADUp = 0x34,
DPADDown = 0x38,
DPADLeft = 0x3C,
DPADRight = 0x40;
public static bool DetectButton(int clientIndex, uint Button)
{
Int32 ButtonIndex = PS3.Extensions.ReadInt32(0x94641C + Button);
Int32 B1 = PS3.Extensions.ReadInt32(G_Client(clientIndex) + 0x56B;
Int32 B2 = PS3.Extensions.ReadInt32(G_Client(clientIndex) + 0x56A0);
if ((B1 == ButtonIndex) || (B2 == ButtonIndex))
return true;
return false;
}
public static float[] G_GetPlayerViewOrigin(int clientIndex)
{
PS3.SetMemory(0x2600250, new byte[0xC]);
RPC.Call(0x1E60D0, G_Client(clientIndex), 0x2600250);
return ReadSingle(0x2600250, 3);
}
public static void G_LocationalTrace(int Trace, float[] Start, float[] End)
{
RPC.Call(0x35C5A8, Trace, Start, End, 0, 0x280E8B3, 0);
}
public static int Trace_GetEntityHitId(int Trace)
{
return RPC.Call(0x306F30, Trace);
}
public static int TraceEntity(int clientIndex, float TracerDistance)
{
int Trace = 0x25D2B00;
float[] Start = G_GetPlayerViewOrigin(clientIndex);
float[] End = PlayerAnglesToForward(clientIndex, TracerDistance);
G_LocationalTrace(Trace, Start, End);
int Entity = Trace_GetEntityHitId(Trace) & 0xFFFF;
if (Entity < 0x3FE)
{ Entity = (int)G_Entity(Entity); }
else
{ Entity = 0; }
return Entity;
}
public static float[] TraceBullet(int clientIndex, float TracerDistance)
{
int Trace = 0x25D2B00;
float[] Start = G_GetPlayerViewOrigin(clientIndex);
float[] End = PlayerAnglesToForward(clientIndex, TracerDistance);
G_LocationalTrace(Trace, Start, End);
float[] BulletTrace = new float[3];
BulletTrace = new float[] { (((End[0] - Start[0]) * ReadFloat((uint)Trace + 0x10) + Start[0])), (((End[1] - Start[1]) * ReadFloat((uint)Trace + 0x10) + Start[1])), (((End[2] - Start[2]) * ReadFloat((uint)Trace + 0x10) + Start[2])) };
return BulletTrace;
}
public static int precacheShader(string Shader)
{
Lib.WriteInt32(0x1608100 + 0x40, 1);
return RPC.Call(0x276020, Shader);
}
//Enable By Calling Init(); , Not Enable();
private static uint function_address;
public static int Call(uint func_address, params object[] parameters)
{
int length = parameters.Length;
int index = 0;
uint num3 = 0;
uint num4 = 0;
uint num5 = 0;
uint num6 = 0;
while (index < length)
{
if (parameters[index] is int)
{
PS3.Extension.WriteInt32(0x10020000 + (num3 * 4), (int)parameters[index]);
num3++;
}
else if (parameters[index] is uint)
{
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), (uint)parameters[index]);
num3++;
}
else
{
uint num7;
if (parameters[index] is string)
{
num7 = 0x10022000 + (num4 * 0x400);
PS3.Extension.WriteString(num7, Convert.ToString(parameters[index]));
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), num7);
num3++;
num4++;
}
else if (parameters[index] is float)
{
PS3.Extension.WriteFloat(0x10020024 + (num5 * 4), (float)parameters[index]);
num5++;
}
else if (parameters[index] is float[])
{
float[] input = (float[])parameters[index];
num7 = 0x10021000 + (num6 * 4);
Lib.WriteSingle(num7, input);
PS3.Extension.WriteUInt32(0x10020000 + (num3 * 4), num7);
num3++;
num6 += (uint)input.Length;
}
}
index++;
}
PS3.Extension.WriteUInt32(0x1002004C, func_address);
Thread.Sleep(20);
return PS3.Extension.ReadInt32(0x10020050);
}
public static void Enable()
{
PS3.SetMemory(function_address, new byte[] { 0x4E, 0x80, 0x00, 0x20 });
Thread.Sleep(20);
byte[] memory = new byte[]
{ 0x7C, 0x08, 0x02, 0xA6, 0xF8, 0x01, 0x00, 0x80, 0x3C, 0x60, 0x10, 0x02, 0x81, 0x83, 0x00, 0x4C,
0x2C, 0x0C, 0x00, 0x00, 0x41, 0x82, 0x00, 0x64, 0x80, 0x83, 0x00, 0x04, 0x80, 0xA3, 0x00, 0x08,
0x80, 0xC3, 0x00, 0x0C, 0x80, 0xE3, 0x00, 0x10, 0x81, 0x03, 0x00, 0x14, 0x81, 0x23, 0x00, 0x18,
0x81, 0x43, 0x00, 0x1C, 0x81, 0x63, 0x00, 0x20, 0xC0, 0x23, 0x00, 0x24, 0xc0, 0x43, 0x00, 0x28,
0xC0, 0x63, 0x00, 0x2C, 0xC0, 0x83, 0x00, 0x30, 0xC0, 0xA3, 0x00, 0x34, 0xc0, 0xC3, 0x00, 0x38,
0xC0, 0xE3, 0x00, 0x3C, 0xC1, 0x03, 0x00, 0x40, 0xC1, 0x23, 0x00, 0x48, 0x80, 0x63, 0x00, 0x00,
0x7D, 0x89, 0x03, 0xA6, 0x4E, 0x80, 0x04, 0x21, 0x3C, 0x80, 0x10, 0x02, 0x38, 0xA0, 0x00, 0x00,
0x90, 0xA4, 0x00, 0x4C, 0x90, 0x64, 0x00, 0x50, 0xE8, 0x01, 0x00, 0x80, 0x7C, 0x08, 0x03, 0xA6,
0x38, 0x21, 0x00, 0x70, 0x4E, 0x80, 0x00, 0x20 };
PS3.SetMemory(function_address + 4, memory);
PS3.SetMemory(0x10020000, new byte[0x2854]);
PS3.SetMemory(function_address, new byte[] { 0xF8, 0x21, 0xFF, 0x91 });
}
public static int Init()
{
function_address = 0x7AA1E0;
Enable();
return 0;
}
public static void Player_Die(int Killer, int Victim, int meansOfDeath = 18, int iWeapon = 0)
{
UInt32 Attacker = G_Entity(Killer);
UInt32 Inflictor = G_Entity(Victim);
RPC.Call(0x248F20, Inflictor, Attacker, Attacker, 0xFF, meansOfDeath, iWeapon, 0xD0300AD4C);
Thread.Sleep(100);
}
Code Is To Big For Thread!
[URL="https://pastebin.com/Px0Zs5c8"]Black Ops 2 HUD Elements[/URL] ([COLOR="#FF0000"]Link[/COLOR])
public static Single[] getClientViewAngles(Int32 clientIndex)
{
return Lib.ReadSingle(Offsets.Funcs.G_Client(clientIndex, 0x56BC), 3);
}
public static void setClientViewAngles(Int32 entityIndex, Single[] Angles)
{
if (Lib.ReadInt32((UInt32)entityIndex + 0x154) == 0)
Console.Write("setClientViewAngles can only be called on players\n");
else
RPC.Call(Offsets.SetClientViewAngles, G_Entity(entityIndex), Angles);
}
//Velocity = Speed In A Certain Direction
public static Single[] GetVelocity(Int32 clientIndex)
{
return Lib.ReadSingle(G_Client(clientIndex, 0x34), 3);
}
public static void SetVelocity(Int32 clientIndex, Single[] Velocity)
{
Lib.WriteSingle(G_Client(clientIndex, 0x34), 3);
}
concussion_grenade
death
default
default_night
drown
flare
flash_grenade
infrared
infrared_snow
int_frontend_char_trans
low_health
mp_array
mp_cracked
mp_havoc
mp_mountain
mp_nuked
mp_nuked2
mpintro
mpoutro
neutral
remote_mortar_enhanced
remote_mortar_infrared
taser_mine_shock
tvguided_mp
tvguided_sp
defaultweapon_mp
mp7_mp
pdw57_mp
vector_mp
insas_mp
qcw05_mp
evoskorpion_mp
peacekeeper_mp
tar21_mp
type95_mp
sig556_mp
sa58_mp
hk416_mp
scar_mp
saritch_mp
xm8_mp
an94_mp
870mcs_mp
saiga12_mp
ksg_mp
srm1216_mp
mk48_mp
qbb95_mp
lsat_mp
hamr_mp
svu_mp
dsr50_mp
ballista_mp
as50_mp
kard_dw_mp
fnp45_dw_mp
fiveseven_dw_mp
judge_dw_mp
beretta93r_dw_mp
fiveseven_mp
fnp45_mp
beretta93r_mp
judge_mp
kard_mp
m32_mp
smaw_mp
fhj18_mp
usrpg_mp
knife_held_mp
minigun_mp
riotshield_mp
crossbow_mp
knife_ballistic_mp
frag_grenade_mp
concussion_grenade_mp
sticky_grenade_mp
willy_pete_mp
hatchet_mp
sensor_grenade_mp
bouncingbetty_mp
emp_grenade_mp
satchel_charge_mp
proximity_grenade_mp
claymore_mp
pda_hack_mp
flash_grenade_mp
trophy_system_mp
tactical_insertion_mp
destructible_car_mp
explodable_barrel_mp
vcs_controller_mp
knife_mp
dogs_mp
dog_bite_mp
explosive_bolt_mp
scavenger_item_mp
scavenger_item_hack_mp
smoke_center_mp
proximity_grenade_aoe_mp
briefcase_bomb_mp
briefcase_bomb_defuse_mp
cobra_20mm_mp
inventory_supplydrop_mp
supplydrop_mp
ai_tank_drone_rocket_mp
ai_tank_drone_gun_mp
killstreak_ai_tank_mp
inventory_ai_tank_drop_mp
ai_tank_drop_mp
radar_mp
counteruav_mp
radardirection_mp
emp_mp
cobra_20mm_comlink_mp
heli_gunner_rockets_mp
littlebird_guard_minigun_mp
helicopter_comlink_mp
helicopter_guard_mp
helicopter_player_gunner_mp
chopper_minigun_mp
inventory_minigun_mp
inventory_m32_mp
missile_drone_projectile_mp
inventory_missile_drone_mp
missile_drone_mp
missile_swarm_projectile_mp
missile_swarm_mp
planemortar_mp
rc_car_weapon_mp
rcbomb_mp
remote_missile_missile_mp
remote_missile_bomblet_mp
remote_missile_mp
remote_mortar_missile_mp
remote_mortar_mp
qrdrone_turret_mp
killstreak_qrdrone_mp
straferun_gun_mp
straferun_rockets_mp
straferun_mp
auto_gun_turret_mp
microwave_turret_mp
killstreak_remote_turret_mp
autoturret_mp
turret_drop_mp
microwaveturret_mp
microwaveturret_drop_mp
auto_gun_turret_mp
heli_gunner_rockets_mp
straferun_rockets_mp
chopper_minigun_mp
mounted_turret_stand ([COLOR="#FF0000"]Must Be Precached, Works On Turbine[/COLOR])
j_head
j_neck
j_helmet
j_mainroot
j_spine
j_spine4
j_spineupper
j_spinelower
j_elbow_ri
j_elbow_le
j_wrist_ri
j_wrist_le
j_wristtwist_ri
j_wristtwist_le
j_knee_ri
j_knee_le
j_ankle_ri
j_ankle_le
j_clavicle_ri
j_clavicle_le
j_shoulder_ri
j_shoulder_le
j_hip_ri
j_hip_le
j_ball_ri
j_ball_le
tag_origin
tag_eye
tag_weapon
tag_weapon_right
tag_weapon_left
tag_inhand
default
concussion_grenade_mp
tabun_gas_mp
tabun_gas_nokick_mp
proximity_grenade
proximity_grenade_exit
flashbang
frag_grenade_mp
damage_mp
straferun
mp_radiation_high
mp_radiation_med
mp_radiation_low
vcs
ingame_controls
ingame_options
popup_leavegame
scoreboard
spectate
team_marinesopfor
changeclass
initteam_marines
class
initteam_opfor
changeclass_wager
changeclass_custom
changeclass_barebones
sidebet
sidebet_player
endgameupdate
action_seals
faction_pmc
white
black
perk_lightweight
perk_flak_jacket
perk_blind_eye
perk_hardline
perk_ghost
perk_hardwired
perk_scavenger
perk_cold_blooded
perk_fast_hands
perk_warrior
perk_dexterity
perk_hacker
perk_ninja
perk_marathon
perk_tactical_mask
perk_awareness
perk_null
killstreak_null
killstreak_null_drop
hud_ks_rcbomb
hud_ks_rcbomb_drop
hud_ks_u2_spyplane
hud_ks_u2_spyplane_drop
hud_ks_harpy_single
hud_ks_harpy_single_drop
hud_ks_counter_uav
hud_ks_counter_uav_drop
hud_ks_supply_drop
hud_supply_drop_drop
hud_ks_microwave_turret
hud_ks_microwave_turret_drop
hud_ks_predator
hud_ks_predator_drop
hud_ks_planemortar
hud_ks_planemortar_drop
hud_ks_auto_turret
hud_ks_auto_turret_drop
hud_ks_minigun
hud_ks_minigun_drop
hud_ks_m32
hud_ks_m32_drop
hud_ks_qr_drone
hud_ks_qr_drone_drop
hud_ks_talon
hud_ks_talon_drop
hud_ks_ai_helicopter
hud_ks_ai_helicopter_drop
hud_ks_spy_sat
hud_ks_spy_sat_drop
hud_ks_littlebird
hud_ks_littlebird_drop
hud_ks_straferun
hud_ks_straferun_drop
hud_ks_emp
hud_ks_emp_drop
hud_ks_reaper
hud_ks_reaper_drop
hud_ks_heli_gunner
hud_ks_heli_gunner_drop
hud_ks_dogs
hud_ks_dogs_drop
hud_ks_harpy
hud_ks_harpy_drop
hud_ks_player_helicopter
hud_ks_player_helicopter_drop
waypoint_second_chance
rank_pfc
rank_lcpl
rank_cpl
rank_sgt
rank_ssgt
rank_gysgt
rank_msgt
rank_mgysgt
rank_2ndlt
rank_lt
rank_cpt
rank_maj
rank_ltcol
rank_col
rank_bgen
rank_majgen
rank_ltgen
rank_gen
rank_com
rank_prestige01
rank_prestige02
rank_prestige03
rank_prestige04
rank_prestige05
rank_prestige06
rank_prestige07
rank_prestige08
rank_prestige09
rank_prestige10
rank_prestige11
progress_bar_bg
progress_bar_fg
progress_bar_fill
score_bar_bg
mpflag_spectator
hud_scavenger_pickup
gfx_fxt_fx_screen_droplets_02
damage_feedback
damage_feedback_flak
damage_feedback_tac
overlay_low_health
objpoint_default
compass_supply_drop_black
compass_supply_drop_green
compass_supply_drop_red
waypoint_recon_artillery_strike
hud_ks_m202
hud_ks_m202_drop
hud_ammo_refill
hud_ammo_refill_drop
hud_ks_ai_tank_drop
headicon_dead
mech_check_fill
mech_flame_bar
mech_flame_arrow_flipped
mp_hud_cluster_status
mp_hud_armed
mp_hud_deployed
reticle_side_round_big_top
reticle_side_round_big_right
reticle_side_round_big_left
reticle_side_round_big_bottom
hud_remote_missile_target
compass_lodestar
veh_hud_target
veh_hud_target_marked
veh_hud_target_unmarked
compassping_sentry_enemy
compassping_enemy_uav
hud_fofbox_hostile_vehicle
mp_hud_signal_strong
mp_hud_signal_failure
[URL="https://pastebin.com/TVvqC2Kw"]Complete Sound List[/URL]
Copyright © 2024, NextGenUpdate.
All Rights Reserved.