Post: [RELEASE] Black Ops 2 - Buttons Monitoring All Clients
04-10-2013, 07:12 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Hello!

Today i decide to share my stuff about the buttons monitoring for all clients in game.

This will allow you to create methods and send them for all clients in game.

I'll share this little source code , i wrote a different code here because he is a bit extended and better for learn.

So i have used the g_entity for get the pointers to g_client and for all client.

You could also directly use the g_client but this way it's better to understand.

i release today this code for Black Ops 2 ( 1.08 ) & Modern Warfare 3 ( 1.23 ) because he is already released on Se7ensins by Im A Hooker (MW2).

I use this way a while ago on xbox , and since 2 months on PS3 (You must login or register to view this content.)

I will maybe release something for Elite Members soon , but it's a project yet.

I hope some guys will use this method for create some new funny mods Smile

Easy to update for the next title update , just found the new offset for the g_entity.


    
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace Buttons_Monitoring_All_Clients
{

// Made by iMCSx for Playstation 3.
// Credit to : Im A Hooker (Se7enSins) , for his Xbox Mw2 Release.
// Youtube.com/iMCSx - Nextgenupdate.com - www.FrenchModdingTeam.com

public partial class Form1 : Form
{
// Define Custom Timer (I don't like use this, i use a custom hard way)
// It is ok for test and use for fun
private Timer StartiMCSxButtons = new Timer();

public Form1()
{
InitializeComponent();
}

private void Form1_Load(object sender, EventArgs e)
{

}

public class Buttons
{
// Define Buttons For Black Ops II
public static uint
X = 8192,
O = 16384,
Square = 4,
L3 = 1088,
R3 = 32,
L2 = 256,
R2 = 512,
L1 = 2147487744,
R1 = 128,
Crouch = 16384,
Prone = 32768;
}

public class PS3Types
{
// Create Connect Types
public static int StartButton;
public static byte[] BIND = new byte[4];
public static uint[] processIDs;
public static uint ProcessID;
}

public void ConnectAttach()
{
try
{
PS3TMAPI.InitTargetComms();
PS3TMAPI.Connect(0, null);
PS3TMAPI.GetProcessList(0, out PS3Types.processIDs);
ulong uProcess = PS3Types.processIDs[0];
PS3Types.ProcessID = Convert.ToUInt32(uProcess);
PS3TMAPI.ProcessAttach(0, PS3TMAPI.UnitType.PPU, PS3Types.ProcessID);
PS3TMAPI.ProcessContinue(0, PS3Types.ProcessID);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}

private uint getPlayerState(int clientIndex)
{
// Get the playerState from entities.
byte[] iMCSxDest = new byte[4];
PS3TMAPI.ProcessGetMemory(0, PS3TMAPI.UnitType.PPU, PS3Types.ProcessID, 0, 0x01692dbc + ((uint)clientIndex * 0x31C) + 0x154, ref iMCSxDest);
Array.Reverse(iMCSxDest);
uint Next = BitConverter.ToUInt32(iMCSxDest, 0);
return Next;
}

private uint UseButtonMonitoring(int client)
{
// Get buttons value.
return (getPlayerState(client) + 0x569C);
}

private uint DetectButton(int clientID)
{
// Reverse Byte[] to UInt32 and detect them.
PS3TMAPI.ProcessGetMemory(0, PS3TMAPI.UnitType.PPU, PS3Types.ProcessID, 0, UseButtonMonitoring(clientID), ref PS3Types.BIND);
return System.BitConverter.ToUInt32(PS3Types.BIND, 0);
}

private void button1_Click(object sender, EventArgs e)
{
ConnectAttach(); // Connect First your debug.
StartiMCSxButtons.Interval = 300;
StartiMCSxButtons.Enabled = true;
StartiMCSxButtons.Tick += StartiMCSxButtons_Tick;
StartiMCSxButtons.Start(); // Start Event.
}

private void button2_Click(object sender, EventArgs e)
{
StartiMCSxButtons.Enabled = false;
StartiMCSxButtons.Stop(); // Stop Event.
}

void StartiMCSxButtons_Tick(object sender, EventArgs e)
{
uint client0 = DetectButton(0); // Must be in a loop.
uint client1 = DetectButton(1); // Example Other Client

if (client0 == Buttons.X)
MessageBox.Show("Client 0 Press the buttons X !");
if (client0 == Buttons.R1 + Buttons.L1) // Example 2 Buttons Pressed in the same moment.
MessageBox.Show("Client 0 Press the buttons R1 + L1 !");
if (client1 == Buttons.X)
MessageBox.Show("Client 1 Press the buttons X !");
}
}
}



Credit : Im A Hooker (Se7ensins) , for his release xbox mw2 method.

You can see in this code some // i explain here why i wrote here some code. Like i said , i don't like use a timer , i use it here because he is better for understand and easy for use. I use a while() customized in my project.

I use here the ps3tmapi_net.dll commands , and you could always use this code with your custom code , i don't want share my custom ps3 library yet (soon).

Have fun.
(adsbygoogle = window.adsbygoogle || []).push({});

The following 18 users say thank you to iMCSx for this useful post:

BadChoicesZ, BaSs_HaXoR, BuC-ShoTz, ErasedDev, FAKA_ELITE, FM|T Enstone, FM|T xDevOpS, Gendjisan, ImPiffHD, Lopez., Mango_Knife, SC58, UGz-, Whos Your Host, zGooNzLobbies, Ziad1997, zMarcusHD
04-14-2013, 12:18 PM #11
C123
Do a barrel roll!
Originally posted by primetime43 View Post
Yea cause your some little kid on this site that thinks he is cool and has never even done anything to help out this community. So piss off and go back to ttg u fuckin pussy.

i just said that you should be happy that he released this and now you get mad, lets re-think which one of us is the little kid here or then "retarded grown-up man who can control his anger".
08-03-2013, 03:36 PM #12
Originally posted by FM
Where ? I don't have saw , and nah i don't care , i would just share it because i have it since some months and it's already released on se7ensins , it's not private , it's just my custom code updated on ps3 + explaination , when i release something i try to explain to people , if not it's stupid.


Thank you, you're benefiting the modding community be releasing your stuff.
There may be some people that hate on you but it's only because they are jealous.
Keep up all of your work! You make really good things.
P.S. waiting for button monitoring for MW2 Winky Winky

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo