PS3TMAPI.InitTargetComms();
PS3TMAPI.Connect(0, null);
PS3TMAPI.GetProcessList(0, out processIDs);
ulong uProcess = processIDs[0];
ProcessID = Convert.ToUInt32(uProcess);
PS3TMAPI.ProcessAttach(0, PS3TMAPI.UnitType.PPU, ProcessID);
PS3TMAPI.ProcessContinue(0, ProcessID);
PS3TMAPI.ProcessSetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, Address, bytes);
byte[] iMCSx = new byte[] { 0x69, 0x4D, 0x43, 0x53, 0x78, 0x00 };
PS3TMAPI.ProcessSetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, 0x01BBBC2C, iMCSx);
byte[] iMCSx = new byte[0x20];
PS3TMAPI.ProcessGetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, Address, ref iMCSx);
PS3TMAPI.InitTargetComms()
PS3TMAPI.Connect(0, vbNullString)
Try
PS3TMAPI.GetProcessList(0, processIDs)
Dim uProcess As ULong = processIDs(0)
ProcessID = Convert.ToUInt32(uProcess)
PS3TMAPI.ProcessAttach(0, PS3TMAPI.UnitType.PPU, ProcessID)
PS3TMAPI.ProcessContinue(0, ProcessID)
Dim Info As String = "The Process 0x" & ProcessID.ToString("X8") & " Has Been Attached !"
MessageBox.Show(Info, "Process Ready!", MessageBoxButtons.OK, MessageBoxIcon.Asterisk)
Catch Ex As Exception
MessageBox.Show(Ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.[Error])
End Try
Private processIDs As UInteger()
Private ProcessID As UInteger
Dim Test As Byte() = New Byte() {&H5} // it's 0x05 in byte C#
PS3TMAPI.ProcessSetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, Address (Example &H00FCA280, iMCSx)
Private Function MW3ClientState(clientNum As UInteger) As UInteger
Return (&H110A280 + (clientNum * &H3980))
End Function
PS3.SetMemory(Address, Byte)
const WCHAR * dllName = L"ps3tmapi.dll";
HINSTANCE hlib = LoadLibrary(dllName);
typedef int (__cdecl *InitTargetCommsFunction)(void);
typedef int (__cdecl *ConnectFunction)(int,LPWSTR);
typedef int (__cdecl *ProcessListFunction)(int, UINT32*, UINT32*);
typedef int (__cdecl *ProcessAttachFunction)(int, UINT32 ,UINT32);
typedef int (__cdecl *ProcessContinueFunction) (int, UINT32);
typedef int (__cdecl *ProcessInfoFunction)(int, UINT32 ,UINT32*,SNPS3PROCESSINFO*);
typedef int (__cdecl *ProcessSetMemoryFunction)(int, UINT32 ,UINT32 ,UINT64 , UINT64, int, BYTE*);
typedef int (__cdecl *ProcessGetMemoryFunction)(int, UINT32 ,UINT32 ,UINT64 , UINT64, int, BYTE*);
InitTargetCommsFunction InitTargetComms = (InitTargetCommsFunction) GetProcAddress(hlib, "SNPS3InitTargetComms");
ConnectFunction Connect = (ConnectFunction) GetProcAddress(hlib, "SNPS3Connect");
DisconnectFunction Disconnect = (DisconnectFunction) GetProcAddress(hlib, "SNPS3Disconnect");
ProcessListFunction ProcessList = (ProcessListFunction) GetProcAddress(hlib, "SNPS3ProcessList");
ProcessAttachFunction ProcessAttach = (ProcessAttachFunction) GetProcAddress(hlib, "SNPS3ProcessAttach");
ProcessContinueFunction ProcessContinue = (ProcessContinueFunction) GetProcAddress(hlib,"SNPS3ProcessContinue");
ProcessInfoFunction ProcessInfo = (ProcessInfoFunction) GetProcAddress(hlib, "SNPS3ProcessInfo");
ProcessGetMemoryFunction GetMemory = (ProcessGetMemoryFunction) GetProcAddress(hlib, "SNPS3ProcessGetMemory");
ProcessSetMemoryFunction SetMemory = (ProcessSetMemoryFunction) GetProcAddress(hlib, "SNPS3ProcessSetMemory");
//Connection////////////////////////////
int target=0xfffffffe; //target default
InitTargetComms();
Connect(target,NULL);
//Attach/////////////////////////////////
ProcessList(target,&puCount,puProcessID);
ProcProcessAttach(target, 0,*puProcessID);
ProcProcessContinue(target, *puProcessID);
ProcProcessInfo(target,*puProcessID,&puBufferSize,pProcessInfo);
//Get/SetMemory/////////////////////////
GetMemory(target,0,*puProcessID,(pProcessInfo->ThreadIDs)[0],uAddress,nCount,pBuffer);
SetMemory(target,0,*puProcessID,(pProcessInfo->ThreadIDs)[0],uAddress,nCount,pBuffer);
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
// Copyright © iMCSProduction 2013.
// Thanks to BuC-ShoTz to have contributed to this.
// Visit www.NextGenUpdate.com if you're English.
// Visit www.FrenchModdingTeam.com if you're French.
// Follow me www.Twitter.com/iMCSx - www.Youtube.com/iMCSx
namespace PS3Lib
{
public class PS3
{
public static uint ProcessID;
public static uint[] processIDs;
public static string snresult;
private static string usage;
public static string Info;
public static PS3TMAPI.ConnectStatus connectStatus;
public static string Status;
public static string MemStatus;
public static void ConnectDebug()
{
PS3TMAPI.InitTargetComms();
PS3TMAPI.Connect(0, null);
}
public static void GetStatus()
{
Status = Convert.ToString(PS3TMAPI.GetConnectStatus(0, out connectStatus, out usage));
}
public static void ProcessAttach()
{
PS3TMAPI.GetProcessList(0, out processIDs);
ulong uProcess = processIDs[0];
ProcessID = Convert.ToUInt32(uProcess);
PS3TMAPI.ProcessAttach(0, PS3TMAPI.UnitType.PPU, ProcessID);
PS3TMAPI.ProcessContinue(0, ProcessID);
Info = "The Process 0x" + ProcessID.ToString("X8") + " Has Been Attached !";
}
public static void SetMemory(uint Address, byte[] Bytes)
{
PS3TMAPI.ProcessSetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, Address, Bytes);
}
public static void GetMemory(uint Address, byte[] Bytes)
{
PS3TMAPI.ProcessGetMemory(0, PS3TMAPI.UnitType.PPU, ProcessID, 0, Address, ref Bytes);
}
}
}
Copyright © 2024, NextGenUpdate.
All Rights Reserved.