Results 1 to 10 of 26

Thread: [RELEASE] PS3Lib v3.1


  1. iMCSx's Avatar

    iMCSx French Modding Team

    Join Date Oct 2010

    Posts 440

    Membership Former Staff

    Reputation: 42203

    06-19-2013 05:42 PM #1 [RELEASE] PS3Lib v3.1

    PS3 Library .NET


    This will allow you to communicate with your PS3 Developers easily.
    Connection with targets , read/write memory and more...

    V4 Released : http://www.nextgenupdate.com/forums/...4-dex-cex.html

    This project is on CodePlex , you can download the project compiled (.DLL) or see the source [Only registered and activated users can see links. ]


    New Features :

    *Automatic ps3tmapi_net.dll (You don't need to add as reference this dll , PS3Lib do it!)
    *Connect a Target By Name
    *Get a Target Name
    *Reset To XMB
    *PS3IO Extension (XboxDevelopmentExtender Converted)
    *Extension Memory (CraigChrist XDevkit Extension Converted)


    UPDATE v3.1 CHANGESET:


    Some guys get a message "ps3tmapi_net.dll not found" when you try to connect to target, you must just add this in your Program.cs / Form_Load / Or just before ConnectDebug :

    Code:
    PS3Lib.GetPs3Api.PS3TMAPI_NET();

    What change in the v3.1 ?:

    *Added a simple project with C# source with note for help all beginners (picture in below)
    *Fixed GetStatus Method
    *Fixed Extensions Writer
    *Fixed Some Errors...





    SOURCE IN THE PACKAGE, DOWNLOAD IN BELOW.


    How to use :

    First , as i've said for the update v3.1 , don't forget to add this somewhere in your app :

    Code:
    PS3Lib.GetPs3Api.PS3TMAPI_NET();
    Add the dll as reference , and add it to your project :

    Code:
    using PS3Lib;
    You must create an instance , example just after the partial class , then like this :

    Code:
    PS3API DEX = new PS3API();
    PS3IO PS3IO = new PS3IO();
    You can change these words "DEX" and "PS3IO" (Not in bold) by what you want.
    You don't need to create an instance for IO , if you don't want use it , don't create an instance it's not important.

    You can now call a method , example in the event Form_Load :

    Code:
    DEX.ConnectDebug("iMCSxDev");
    Like you can see , we can now connect a target by his name , so you can add much target in Target Manager is not a problem.

    But , you can always use the old way (Connect By Default) , because i use 2 methods with the same name , but not the same parameters example :

    Code:
    DEX.ConnectDebug(); // This Connect the Target by default (0)
    
    OR
    
    DEX.ConnectDebug(5); This Connect the target 5.
    I done this only if someone get problems , but it should work perfectly. I have added some others useful commands , first the command PS3TMAPI_NET(); This is included in the function connected , when you will connect your target with the PS3Lib (in your app) the dll will load automatically the ps3tmapi_net , then you DON'T need to add the ps3tmapi_net.dll into your project now... But if you want use a special command from the ps3tmapi_net.dll , you must just add it as reference but without include it in the same folder of your app if you release your app. How work this method ? :

    Code:
            internal static Assembly LoadApi;
            public static Assembly PS3TMAPI_NET()
            {
                AppDomain.CurrentDomain.AssemblyResolve += (s, e) =>
                {
                    var filename = new AssemblyName(e.Name).Name;
                    var x = string.Format(@"C:\Program Files\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    var x64 = string.Format(@"C:\Program Files (x64)\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    var x86 = string.Format(@"C:\Program Files (x86)\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    if (System.IO.File.Exists(x))
                        LoadApi = Assembly.LoadFile(x);
                    else
                    {
                        if (System.IO.File.Exists(x64))
                            LoadApi = Assembly.LoadFile(x64);
    
    
                        else
                        {
                            if (System.IO.File.Exists(x86))
                                LoadApi = Assembly.LoadFile(x86);
                            else
                            {
                                MessageBox.Show("Target Manager API cannot be founded to:\r\n\r\n" + x86, "Error with PS3 API!", MessageBoxButtons.OK, MessageBoxIcon.Error);
                            }
                        }
                    }
                    return LoadApi;
                };
                return LoadApi;
            }
    As you can see , this method Load the dll but return too the assembly , then you can make the same things in your project with this return... I have just enter all popular path for this API my PS3 Attach Games run with this and it work for everyone...


    PS3 Extensions & SCE Properties :

    I have add some methods , but they are only available by their properties , easy to use but i'll write 2 example :

    Code:
    // Extension Propertie
    float Jump = DEX.Extension.ReadFloat(0x0019780); // MW3 Offset , "Jump" has now the value 78. (If default)
    string HostName = DEX.Extension.ReadString(0x01BBBC2C); // This will read your PSN for MW3...
    
    // Extension SCE
    uint CurrentProcess = DEX.SCE.ProcessID(); // Get the latest process attached...
    I have just converted the XDevKit++ from CraigChrist into PS3. I have removed his Extension methods it was not needed for the dll , i have also added and edited some function , example the string is read in memory to the next null byte.


    PS3IO (EndianIO) :

    We can now use EndianIO for ps3... This allow to be free with the language. It's a bit like the extension , but different this read and write quickly your bytes and much methods are available , some example how to use :

    Code:
    using PS3Lib.IO;
    
    // You must create an instance too , already said before...
    
                // Put this into a function , this will set the noclip for MW3.
                EndianIO IO = new EndianIO(PS3IO.StreamPS3(DEX), PS3Lib.IO.EndianType.BigEndian);
                IO.Open();
                IO.In.BaseStream.Position = 0x0110A280 + 0x35fc;
                IO.Out.Write(0x00000001);
                
                // Other Example , write noclip + redboxes
                EndianIO IO = new EndianIO(PS3IO.StreamPS3(DEX), PS3Lib.IO.EndianType.BigEndian);
                IO.Open();
                IO.In.BaseStream.Position = 0x0110a280 + 0x35fc;
                IO.Out.Write(0x00000001);
                IO.In.BaseStream.Position = 0x0110a280 + 0x13;
                IO.Out.Write((byte)0x10);
    You can choose the Endian Type , and read/write memory , use just IO.Out. or IO.In. .

    There are not only these methods , i have just write some examples , you will see every methods available if you explore it from your project.

    I'm done with this thread , i know its a bit long for only a dll , but i would explain this perfectly , like this everyone understand how to work this.

    I hope this will help you to develop some applications...

    Thanks to Buc-ShoTz for the first PS3Lib released , CraigChrist for his XDevKit base , and the creator of the XboxDevExtander.


    [Only registered and activated users can see links. ]


    Have fun
    Attached Images Attached Images
    Last edited by iMCSx; 11-24-2013 at 11:48 PM.

    -----------------------------------------------
    > [Only registered and activated users can see links. ] <
    > [Only registered and activated users can see links. ] <
    -----------------------------------------------
    Spoiler:


  2. FM|T xDevOpS's Avatar

    FM|T xDevOpS Save Point

    Join Date Feb 2012

    Posts 7

    Membership Standard

    Reputation: 10

    06-19-2013 05:43 PM #2

    Nice work

  3. Chxii's Avatar

    Chxii Do a barrel roll!

    Join Date Jun 2012

    Posts 126

    Membership Standard

    Reputation: 522

    06-19-2013 05:56 PM #3

    Nice man like always

  4. iMaesh4x Banned

    Join Date Aug 2012

    Posts 28

    Membership Banned

    Reputation: 346

    06-19-2013 06:02 PM #4

    Sexual Release

  5. Ace's Avatar

    Ace Former Staff Member

    Join Date Jan 2013

    Posts 814

    Membership Former Staff

    Reputation: 19281

    06-19-2013 06:16 PM #5

    Great Release, I think alot have been waiting for this
    Guess who's back?

  6. KrElZo's Avatar

    KrElZo Do a barrel roll!

    Join Date Dec 2010

    Posts 125

    Membership Standard

    Reputation: 311

    06-19-2013 09:30 PM #6

    Great release as always

  7. DexModderFTW's Avatar

    DexModderFTW NextGenUpdate Elite

    Join Date Dec 2012

    Posts 261

    Membership Elite

    NextGenUpdate Elite Member

    Reputation: 8216

    06-19-2013 11:40 PM #7

    Good Job

  8. 0xX0R's Avatar

    0xX0R Save Point

    Join Date Dec 2012

    Posts 9

    Membership Standard

    Reputation: -65

    06-20-2013 05:02 AM #8

    Good Job

  9. Join Date Apr 2013

    Posts 35

    Membership Standard

    Reputation: 72

    06-20-2013 06:35 AM #9

    What i am Waiting For Is A LAN for OUR ps3s Would Be Awesome
    what does this do NOOBS GUYS

  10. JemEO's Avatar

    JemEO NextGenUpdate Elite

    Join Date Sep 2010

    Posts 67

    Membership Elite

    NextGenUpdate Elite Member

    Reputation: 190

    06-21-2013 06:17 AM #10

    Quote Originally Posted by FM|T iMCSx View Post
    PS3 Library v3.0 For .NET


    This will allow you to communicate with your PS3 Developers easily.
    Connection with targets , read/write memory and more...

    This project is on CodePlex , you can download the project compiled (.DLL) or see the source [Only registered and activated users can see links. ]


    New Features :

    *Automatic ps3tmapi_net.dll (You don't need to add as reference this dll , PS3Lib do it!)
    *Connect a Target By Name
    *Get a Target Name
    *Reset To XMB
    *PS3IO Extension (XboxDevelopmentExtender Converted)
    *Extension Memory (CraigChrist XDevkit Extension Converted)


    How to use :

    Add the dll as reference , and add it to your project :

    Code:
    using PS3Lib;
    You must create an instance , example just after the partial class , then like this :

    Code:
    PS3API DEX = new PS3API();
    PS3IO PS3IO = new PS3IO();
    You can change these words "DEX" and "PS3IO" (Not in bold) by what you want.
    You don't need to create an instance for IO , if you don't want use it , don't create an instance it's not important.

    You can now call a method , example in the event Form_Load :

    Code:
    DEX.ConnectDebug("iMCSxDev");
    Like you can see , we can now connect a target by his name , so you can add much target in Target Manager is not a problem.

    But , you can always use the old way (Connect By Default) , because i use 2 methods with the same name , but not the same parameters example :

    Code:
    DEX.ConnectDebug(); // This Connect the Target by default (0)
    
    OR
    
    DEX.ConnectDebug(5); This Connect the target 5.
    I done this only if someone get problems , but it should work perfectly. I have added some others useful commands , first the command PS3TMAPI_NET(); This is included in the function connected , when you will connect your target with the PS3Lib (in your app) the dll will load automatically the ps3tmapi_net , then you DON'T need to add the ps3tmapi_net.dll into your project now... But if you want use a special command from the ps3tmapi_net.dll , you must just add it as reference but without include it in the same folder of your app if you release your app. How work this method ? :

    Code:
            internal static Assembly LoadApi;
            public static Assembly PS3TMAPI_NET()
            {
                AppDomain.CurrentDomain.AssemblyResolve += (s, e) =>
                {
                    var filename = new AssemblyName(e.Name).Name;
                    var x = string.Format(@"C:\Program Files\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    var x64 = string.Format(@"C:\Program Files (x64)\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    var x86 = string.Format(@"C:\Program Files (x86)\SN Systems\PS3\bin\ps3tmapi_net.dll", filename);
                    if (System.IO.File.Exists(x))
                        LoadApi = Assembly.LoadFile(x);
                    else
                    {
                        if (System.IO.File.Exists(x64))
                            LoadApi = Assembly.LoadFile(x64);
    
    
                        else
                        {
                            if (System.IO.File.Exists(x86))
                                LoadApi = Assembly.LoadFile(x86);
                            else
                            {
                                MessageBox.Show("Target Manager API cannot be founded to:\r\n\r\n" + x86, "Error with PS3 API!", MessageBoxButtons.OK, MessageBoxIcon.Error);
                            }
                        }
                    }
                    return LoadApi;
                };
                return LoadApi;
            }
    As you can see , this method Load the dll but return too the assembly , then you can make the same things in your project with this return... I have just enter all popular path for this API my PS3 Attach Games run with this and it work for everyone...


    PS3 Extensions & SCE Properties :

    I have add some methods , but they are only available by their properties , easy to use but i'll write 2 example :

    Code:
    // Extension Propertie
    float Jump = DEX.Extension.ReadFloat(0x0019780); // MW3 Offset , "Jump" has now the value 78. (If default)
    string HostName = DEX.Extension.ReadString(0x01BBBC2C); // This will read your PSN for MW3...
    
    // Extension SCE
    uint CurrentProcess = DEX.SCE.ProcessID(); // Get the latest process attached...
    I have just converted the XDevKit++ from CraigChrist into PS3. I have removed his Extension methods it was not needed for the dll , i have also added and edited some function , example the string is read in memory to the next null byte.


    PS3IO (EndianIO) :

    We can now use EndianIO for ps3... This allow to be free with the language. It's a bit like the extension , but different this read and write quickly your bytes and much methods are available , some example how to use :

    Code:
    using PS3Lib.IO;
    
    // You must create an instance too , already said before...
    
                // Put this into a function , this will set the noclip for MW3.
                EndianIO IO = new EndianIO(PS3IO.StreamPS3(DEX), PS3Lib.IO.EndianType.BigEndian);
                IO.Open();
                IO.In.BaseStream.Position = 0x0110A280 + 0x35fc;
                IO.Out.Write(0x00000001);
                
                // Other Example , write noclip + redboxes
                EndianIO IO = new EndianIO(PS3IO.StreamPS3(DEX), PS3Lib.IO.EndianType.BigEndian);
                IO.Open();
                IO.In.BaseStream.Position = 0x0110a280 + 0x35fc;
                IO.Out.Write(0x00000001);
                IO.In.BaseStream.Position = 0x0110a280 + 0x13;
                IO.Out.Write((byte)0x10);
    You can choose the Endian Type , and read/write memory , use just IO.Out. or IO.In. .

    There are not only these methods , i have just write some examples , you will see every methods available if you explore it from your project.

    I'm done with this thread , i know its a bit long for only a dll , but i would explain this perfectly , like this everyone understand how to work this.

    I hope this will help you to develop some applications...

    Thanks to Buc-ShoTz for the first PS3Lib released , CraigChrist for his XDevKit base , and the creator of the XboxDevExtander.


    [Only registered and activated users can see links. ]


    Have fun
    How do I use DEX.SCE.GetStatus(); and DEX.SCE.ProcessID(); ? I've tried different ways but cant figure out how to use those two. Amazing release by the way
    Last edited by JemEO; 06-21-2013 at 06:19 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •