THREAD: [BETA] C++ PS3Lib (CCAPI/TMAPI)
  1. 06-28-2015, 09:37 PM
    425
    Posts
    11,748
    Reputation
    Sep 2012
    NextGenUpdate
    Hi Ngu Smile, so i figured id give ccapi another try, this time i came out allot more successful than last time.
    I have made this library for beginers. it is very easy to use, it works just like IMCSX's ps3lib.
    Tutorial:
    1: Setting the API

    #include "PS3Lib.h"
    void SetCCAPI_API_Example()
    {
    PS3::SetAPI(PS3::API::CCAPI);
    }
    void SetTMAPIAPI_API_Example()
    {
    PS3::SetAPI(PS3::API::TMAPI);
    }

    2. Connecting And Attaching

    //CCAPI
    const char* ip = "192.168.0.0";
    PS3::Connect(ip);
    PS3::Attach();
    //TMAPI
    PS3::Connect(DEFAULT_TMAPI_IP);
    PS3::Attach();

    3. Using functions
    Use EN to access CCAPI function and SN to access TMAPI functions

    //CCAPI
    EC::RingBuzzer(EC::BuzzerMode:Happyouble);
    //TMAPI
    uint example = SN::ProcessID;

    4. memory functions
    to write or read memory use the functions in the PS3 namespace the functions will check to see which api you are using so you dont have to worry about it
    example:

    PS3::WriteString(0x00000,":P");

    5: lastly i coded a very basic library for beginers just access the Lib namespace to use it

    wchar_t* wstr = Lib::CStrToWStr(":P");

    you can get my library here: You must login or register to view this content.
    virus scan: not needed(headers cant be executed)
    and a example project(vs2012) : You must login or register to view this content.
    Notes/Bugs:
    tested in Visual Studio 2012, 2013 U and Qt Creator 5.2.0
    BE SURE TO HAVE CCAPI.dll AND ps3tmapi.dll in you executable directory
    thanks to seb5594 for his small library
    any suggestions or questions contact milky4444 on nextgenupdate
    BUGS:
    1: (CCAPI)SetMemory: writes bytes, but adds a 214 byte header to the normal byte array
    2: (CCAPI)GetMemory: has somewhat the same problem
    3: (CCAPI)Set*********: need to re-create enstones StringToByteArray function

    EXTRA: If you receive multiple errors when building a project in Qt (providing you are using it) then try using this revised edition to solve your problem there: You must login or register to view this content.
    Last edited by Geo ; 06-30-2015 at 08:29 AM.

  2. The Following 12 Users Say Thank You to milky4444 For This Useful Post:

    , , , , , , , , , , ,

  3. 11-28-2015, 06:15 AM
    anxify's Avatar
    anxify
    I am error
    anxify's Avatar
    anxify
    I am error
    70
    Posts
    630
    Reputation
    Nov 2015
    NextGenUpdate
    Thanks for this! Keep up the awesome work! Once again you've helped out many people including myself Smile
  4. 01-06-2016, 06:29 PM
    16
    Posts
    10
    Reputation
    Feb 2015
    NextGenUpdate
    how can we code stats for recovery please ? i use QspinBox under Qt
  5. 01-07-2016, 04:41 AM
    Jim Halpert's Avatar
    Jim Halpert
    Bounty hunter
    Jim Halpert's Avatar
    Jim Halpert
    Bounty hunter
    158
    Posts
    2,384
    Reputation
    Aug 2011
    NextGenUpdate
    Originally Posted by Steganozorus View Post
    how can we code stats for recovery please ? i use QspinBox under Qt


    For MW3

    Here's an example for prestige (Make sure you do #include <sstream>Winky Winky:

    You must login or register to view this content.

    Essentially the values for prestige are 1-20 or 0x01-0x14 in hex. The first function automates hex value generation.
    Last edited by Jim Halpert ; 01-07-2016 at 04:44 AM.

  6. The Following User Thanked Jim Halpert For This Useful Post:


  7. 01-07-2016, 06:08 PM
    16
    Posts
    10
    Reputation
    Feb 2015
    NextGenUpdate
    Originally Posted by arka00 View Post
    For MW3

    Here's an example for prestige (Make sure you do #include <sstream>Winky Winky:

    You must login or register to view this content.

    Essentially the values for prestige are 1-20 or 0x01-0x14 in hex. The first function automates hex value generation.



    I used it with ccapi c++enstone lib like this :

    char toHex(int dec)
    {
    std::stringstream a;
    a << std::hex << dec;
    return a.str().c_str()[0];
    }

    void MainWindow:Gaspn_pushButton_2_clicked()
    {
    ui->prestigeBox->setRange(0, 20);
    ccapi.WriteMemory(0x01c1947c, toHex(ui->prestigeBox->value()));
    }

    but it turns a value 1 in spin box as prestige 49 !! :/
  8. 01-07-2016, 07:31 PM
    Jim Halpert's Avatar
    Jim Halpert
    Bounty hunter
    Jim Halpert's Avatar
    Jim Halpert
    Bounty hunter
    158
    Posts
    2,384
    Reputation
    Aug 2011
    NextGenUpdate
    Originally Posted by Steganozorus View Post
    I used it with ccapi c++enstone lib like this :

    char toHex(int dec)
    {
    std::stringstream a;
    a << std::hex << dec;
    return a.str().c_str()[0];
    }

    void MainWindow:Gaspn_pushButton_2_clicked()
    {
    ui->prestigeBox->setRange(0, 20);
    ccapi.WriteMemory(0x01c1947c, toHex(ui->prestigeBox->value()));
    }

    but it turns a value 1 in spin box as prestige 49 !! :/


    That's really weird.. I don't know what to tell you. Make sure you are using the CCAPI WriteMemory function properly. I have looked through the library and there are multiple different definitions to this function with different parameters.
  9. 03-29-2016, 06:28 PM
    FFM | iMoDzRGFR's Avatar
    FFM | iMoDzRGFR
    Are you high?
    FFM | iMoDzRGFR's Avatar
    FFM | iMoDzRGFR
    Are you high?
    411
    Posts
    2,308
    Reputation
    May 2012
    NextGenUpdate
    You must login or register to view this content. i have a lot of error :/