Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static class PrivateMatch
- {
- //Set Bullets Type Black Ops 2 - 1.17
- #region Set BulletType
- public static class SetBullet
- {
- public static uint Offset_1 = 0x178136F;
- public static uint Offset_2 = Offset_1 - 0xC;
- public static uint Offset_3 = Offset_1 - 0x4;
- public static uint Offset_4 = Offset_1 - 0x170;
- public static uint Offset_5 = Offset_1 - 0x18C;
- public static uint Offset_6 = Offset_1 - 0xD;
- public static PS3API PS3 = new PS3API();
- public static void SetMemoryClient(UInt32 Offset, Byte[] bytesm, UInt32 clientIndex)
- {
- PS3.SetMemory(Offset + (clientIndex * 0x5808), bytesm);
- }
- public static void GetMemoryClient(UInt32 Offset, byte[] buffer, UInt32 clientIndex)
- {
- PS3.GetMemory(Offset + (clientIndex * 0x5808), buffer);
- }
- public static byte[] GetBytes(string str)
- {
- byte[] bytes = new byte[str.Length * sizeof(char)];
- System.Buffer.BlockCopy(str.ToCharArray(), 0, bytes, 0, bytes.Length);
- return bytes;
- }
- public static void removenades(uint ClientIndex)
- {
- byte[] sky = new byte[] { 0x00 };
- PS3.SetMemory((Offset_1) + (ClientIndex * 0x5808), sky);
- byte[] sky1 = new byte[] { 0x00 };
- PS3.SetMemory((Offset_2) + (ClientIndex * 0x5808), sky1);
- }
- public static void removenades1(uint ClientIndex)
- {
- byte[] sky = new byte[] { 0x00 };
- PS3.SetMemory((Offset_3) + (ClientIndex * 0x5808), sky);
- }
- public static void BulletType(int clientIndex, String BulletType)
- {
- removenades((uint)clientIndex);
- removenades1((uint)clientIndex);
- Byte[] OldWeap = new Byte[1];
- if (BulletType == "None")
- SetMemoryClient(Offset_4, OldWeap, (UInt32)clientIndex);
- if (BulletType != "None" && count1 == 0)
- {
- GetMemoryClient(Offset_4, OldWeap, (UInt32)clientIndex);
- count1++;
- }
- byte[] Bullet;
- SetMemoryClient(Offset_4, new Byte[1], (UInt32)clientIndex);
- Thread.Sleep(20);
- switch (BulletType)
- {
- case "AGR Gun":
- Bullet = new Byte[] { 0x7A };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Test":
- Bullet = new Byte[] { 0xC3 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "AGR Rocket":
- Bullet = new Byte[] { 0x7B };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Dragonfire":
- Bullet = new Byte[] { 0x99 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Escortdrone":
- Bullet = new Byte[] { 0x77 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Guardian":
- Bullet = new Byte[] { 0x9F };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Hellstorm":
- Bullet = new Byte[] { 0x95 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Hunter Killer":
- Bullet = new Byte[] { 0x8C };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Loadster":
- Bullet = new Byte[] { 0x97 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Sentry Gun":
- Bullet = new Byte[] { 0x9E };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Stealth Chopper":
- Bullet = new Byte[] { 0x83 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Swarm":
- Bullet = new Byte[] { 0x8F };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "VTOL Bullet":
- Bullet = new Byte[] { 0x89 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "VTOL Rocket":
- Bullet = new Byte[] { 0x84 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Warthog Bullet":
- Bullet = new Byte[] { 0x9B };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Warthog Rocket":
- Bullet = new Byte[] { 0x9C };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Disable":
- Bullet = new Byte[] { 0x00 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- }
- }
- public static void SetBulletType(int clientIndex, Byte[] Bullet)
- {
- SetMemoryClient(Offset_5, Bullet, (UInt32)clientIndex);
- SetMemoryClient(Offset_6, new Byte[] { 0xFF }, (UInt32)clientIndex);
- }
- }
- }
- public static class Online
- {
- #region Set BulletType
- public static class SetBullet
- {
- public static uint Offset_1 = 0x0178136b;
- public static uint Offset_2 = Offset_1 - 0xC;
- public static uint Offset_3 = Offset_1 - 0x4;
- public static uint Offset_4 = Offset_1 - 0x170;
- public static uint Offset_5 = Offset_1 - 0x18C;
- public static uint Offset_6 = Offset_1 - 0xD;
- public static PS3API PS3 = new PS3API();
- public static void SetMemoryClient(UInt32 Offset, Byte[] bytesm, UInt32 clientIndex)
- {
- PS3.SetMemory(Offset + (clientIndex * 0x5808), bytesm);
- }
- public static void GetMemoryClient(UInt32 Offset, byte[] buffer, UInt32 clientIndex)
- {
- PS3.GetMemory(Offset + (clientIndex * 0x5808), buffer);
- }
- public static byte[] GetBytes(string str)
- {
- byte[] bytes = new byte[str.Length * sizeof(char)];
- System.Buffer.BlockCopy(str.ToCharArray(), 0, bytes, 0, bytes.Length);
- return bytes;
- }
- public static void removenades(uint ClientIndex)
- {
- byte[] sky = new byte[] { 0x00 };
- PS3.SetMemory((Offset_1) + (ClientIndex * 0x5808), sky);
- byte[] sky1 = new byte[] { 0x00 };
- PS3.SetMemory((Offset_2) + (ClientIndex * 0x5808), sky1);
- }
- public static void removenades1(uint ClientIndex)
- {
- byte[] sky = new byte[] { 0x00 };
- PS3.SetMemory((Offset_3) + (ClientIndex * 0x5808), sky);
- }
- public static void BulletType(int clientIndex, String BulletType)
- {
- removenades((uint)clientIndex);
- removenades1((uint)clientIndex);
- Byte[] OldWeap = new Byte[1];
- if (BulletType == "None")
- SetMemoryClient(Offset_4, OldWeap, (UInt32)clientIndex);
- if (BulletType != "None" && count1 == 0)
- {
- GetMemoryClient(Offset_4, OldWeap, (UInt32)clientIndex);
- count1++;
- }
- byte[] Bullet;
- SetMemoryClient(Offset_4, new Byte[1], (UInt32)clientIndex);
- Thread.Sleep(20);
- switch (BulletType)
- {
- case "AGR Gun":
- Bullet = new Byte[] { 0x7A };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Test":
- Bullet = new Byte[] { 0xC3 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "AGR Rocket":
- Bullet = new Byte[] { 0x7B };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Dragonfire":
- Bullet = new Byte[] { 0x99 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Escortdrone":
- Bullet = new Byte[] { 0x77 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Guardian":
- Bullet = new Byte[] { 0x9F };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Hellstorm":
- Bullet = new Byte[] { 0x95 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Hunter Killer":
- Bullet = new Byte[] { 0x8C };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Loadster":
- Bullet = new Byte[] { 0x97 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Sentry Gun":
- Bullet = new Byte[] { 0x9E };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Stealth Chopper":
- Bullet = new Byte[] { 0x83 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Swarm":
- Bullet = new Byte[] { 0x8F };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "VTOL Bullet":
- Bullet = new Byte[] { 0x89 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "VTOL Rocket":
- Bullet = new Byte[] { 0x84 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Warthog Bullet":
- Bullet = new Byte[] { 0x9B };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Warthog Rocket":
- Bullet = new Byte[] { 0x9C };
- SetBulletType((int)clientIndex, Bullet);
- break;
- case "Disable":
- Bullet = new Byte[] { 0x00 };
- SetBulletType((int)clientIndex, Bullet);
- break;
- }
- }
- public static void SetBulletType(int clientIndex, Byte[] Bullet)
- {
- SetMemoryClient(Offset_5, Bullet, (UInt32)clientIndex);
- SetMemoryClient(Offset_6, new Byte[] { 0xFF }, (UInt32)clientIndex);
- }
- }
- }
- #endregion
- //How to spawn?
- //BulletType(dataGridView1.CurrentRow.Index, "VTOL Bullet"); //- To Spawn VTOL Bullet
- //Exmple in numericUpDown = BulletType((int)numericUpDown1.Value, "VTOL Bullet");
- //Dont use "Test" ,its freeze the ps3.
- //Have Fun ;)
- //Thanks to Shark - Function, Unknuawn - Big thanks to him :-)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement