Post: [1.09] All Client Dpad Monitoring
03-05-2014, 12:24 AM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Since 1.09 came out today, I thought I would update my button monitoring for it.

It's really simple, just add this coding to your source.

Also, I DO NOT allow this script to be on any other website

Coding:

    
public class Buttonz
{
public static int
DpadUp = 13617,
DpadDown = 14129,
DpadLeft = 14641,
DpadRight = 12594,
Cross = 13618,
Square = 12593,
Circle = 13106,
R2 = 53,
R1 = 49,
L2 = 55,
L1 = 13105,
L3 = 57,
R3 = 14130;
}
public static bool ButtonPressed(int client, int Button)
{
if (BitConverter.ToInt16(PS3.Extension.GetBytes(0x38A81A52 + ((uint)client * 0x6FA00), 2), 0) == Button || BitConverter.ToInt16(PS3.Extension.GetBytes(0x38F91A52 + ((uint)client * 0x6FA00), 2), 0) == Button)
return true;
else return false;
}


This script will monitor all clients buttons both in online (Private Match, Public Match) and offline (Lan, Splitscreen).

If you do not have a definition of ReadMemory(uint, int); Please use PS3Lib by iMcsx, it's really helpful :p.

Anyways, have fun with this!

How to use in a timer/backgroundworker
    
if(ButtonPressed(0, Buttonz.DpadUp))
MessageBox.Show("Client 0 is pressing up");
else if(ButtonPressed(3, Buttonz.DpadDown))
MessageBox.Show("Client 3, is pressing dpad down");


If you have any questions ask me!


Update: For those who are having trouble with button monitoring, try this version using G_Client

    
public class Buttons
{
public static Int32
L1 = 526336,
R1 = 16777216,
L2 = 8388608,
R2 = 4194304,
L3 = 35651584,
R3 = 67108868,
Cross = 262144,
Crouch = 131072,
Square = 805306368,
Start = 32768;
}
public bool ButtonPressed(int client, Int32 Button)
{
if (BitConverter.ToInt32(Debug.GetBytes(0xF46E30 + ((uint)client * 0x3700), Cool Man (aka Tustin), 0) == Button)
return true;
else return false;
}


How to use: In a timer or backgroundworker

    
private void timer1_Tick(object sender, EventArgs e)
{
if (ButtonPressed(0, Buttons.L1 + Buttons.R1))
textBox1.Text = "C0 L1 R1";
else if (ButtonPressed(0, Buttons.L1 + Buttons.R1 + Buttons.L2 + Buttons.R2))
textBox1.Text = " C0 L1 R1 L2 R2";
else textBox1.Text = "None";
}


Credits:

    
SC58 - Original Dword for client_s on 1.06
Imcsx - PS3Lib
RatchetBooy - for helping me test earlier even though we couldn't find it at the time (I didn't have my ps3 at that time)
Me - Script
(adsbygoogle = window.adsbygoogle || []).push({});

The following 12 users say thank you to Black Panther for this useful post:

-SuperMan, Akaipwn, br0wniiez, FusionIsDaName, Jannik007, M-alShammary, Mango_Knife, Marco_Legend, Notorious, xProvXKiller, RatchetBooty, Raz0rMind
03-16-2014, 07:45 PM #20
Originally posted by B1TW153 View Post
Lmfao, you do know he is hated on se7ensins. He got a new asshole ripped because he claims to be so smart, and gets called out.

Your comments are not necessary. Who cares if he is hated on that shitty website anyways? He proved time and time again to be a contributing member of this community so once again, please leave. Smile

The following user thanked Black Panther for this useful post:

SC58
03-16-2014, 08:21 PM #21
Mango_Knife
In my man cave
Originally posted by AlmightySo View Post
Since 1.09 came out today, I thought I would update my button monitoring for it.

It's really simple, just add this coding to your source.

Also, I DO NOT allow this script to be on any other website

Coding:

    
public class Buttonz
{
public static int
DpadUp = 13617,
DpadDown = 14129,
DpadLeft = 14641,
DpadRight = 12594,
Cross = 13618,
Square = 12593,
Circle = 13106,
R2 = 53,
R1 = 49,
L2 = 55,
L1 = 13105,
L3 = 57,
R3 = 14130;
}
public static bool ButtonPressed(int client, int Button)
{
if (BitConverter.ToInt16(PS3.Extension.GetBytes(0x38A81A52 + ((uint)client * 0x6FA00), 2), 0) == Button || BitConverter.ToInt16(PS3.Extension.GetBytes(0x38F91A52 + ((uint)client * 0x6FA00), 2), 0) == Button)
return true;
else return false;
}


This script will monitor all clients buttons both in online (Private Match, Public Match) and offline (Lan, Splitscreen).

If you do not have a definition of ReadMemory(uint, int); Please use PS3Lib by iMcsx, it's really helpful :p.

Anyways, have fun with this!

How to use in a timer/backgroundworker
    
if(ButtonPressed(0, Buttonz.DpadUp))
MessageBox.Show("Client 0 is pressing up");
else if(ButtonPressed(3, Buttonz.DpadDown))
MessageBox.Show("Client 3, is pressing dpad down");


If you have any questions ask me!

Credits:

    
SC58 - Original Dword for client_s on 1.06
Imcsx - PS3Lib
RatchetBooy - for helping me test earlier even though we couldn't find it at the time (I didn't have my ps3 at that time)
Me - Script


Almighty
This is sick
But could you do like an exmple
If player is (chorch or prone whatever) - so this mod...
?

Or like to do L3 + R1 = something?
03-16-2014, 08:30 PM #22
Originally posted by Knife View Post
Almighty
This is sick
But could you do like an exmple
If player is (chorch or prone whatever) - so this mod...
?

Or like to do L3 + R1 = something?


I don't believe so, sorry :(
03-16-2014, 09:05 PM #23
Updated with G_Client version of button handling. Look in the OP for the script. I'll make it all into one script in a few.
03-16-2014, 10:25 PM #24
Mango_Knife
In my man cave
Originally posted by AlmightySo View Post
I don't believe so, sorry :(


mm ok that's cool man.
03-16-2014, 10:26 PM #25
Originally posted by Knife View Post
mm ok that's cool man.


I updated the thread with a version of button handling that supports that.
03-16-2014, 11:59 PM #26
Originally posted by Knife View Post
Almighty
This is sick
But could you do like an exmple
If player is (chorch or prone whatever) - so this mod...
?

Or like to do L3 + R1 = something?


Ofcource you can, but you would have to press them simultaneously.
    
if(ButtonPressed(0,Buttons.L3) && ButtonPressed(0,Button.R1))
//dohax
03-17-2014, 02:08 AM #27
Originally posted by B1TW153 View Post
Ofcource you can, but you would have to press them simultaneously.
    
if(ButtonPressed(0,Buttons.L3) && ButtonPressed(0,Button.R1))
//dohax


That doesn't work with client_s. But with g_client it does
03-17-2014, 02:11 AM #28
Originally posted by AlmightySo View Post
That doesn't work with client_s. But with g_client it does


How would it not work? It's just checking if 2 buttons where pressed at the same time. It works fine on xbox. Also, I am not sure there even is a structure labeled g_client? I know there is gclient_s, but I guess it's just you mis-labeling things.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo