LevelMod Extension c++ lib

Release mod tools/source code to the tools here.
Forum rules
Its preferred you release the source code, but if not its ok, but if its found you stole/borrowed source code from another tool/program and violated its license it will be removed.
Post Reply
Vadru
VIP
Posts: 42
Joined: Wed Jul 07, 2010 2:39 pm

LevelMod Extension c++ lib

Post by Vadru »

http://www.mediafire.com/file/byiiephpk ... n.rar/file

I was supposed to release this years ago, but got too busy to rewrite the code to be able to export the functions and make it easier to understand how it works etc.

Current features:
-Call ingame collision raytracing functions
-Add new values/functions that you can access/call from QB
-Call QB functions from your program
-Modify QB values and arrays
-D3D8 presenthook
-And some more


To add your own functions to QB use this code:

Code: Select all

CompiledScript scripts[] = { {"ScriptName",         CFunctionName}, etc... };

for (int i = 0; i < sizeof(scripts) / sizeof(CompiledScript); i++)
{
    QBKeyHeader* header = AddQBKeyHeader(Checksum(scripts[i].name), 1);
    if (header)
    {
        header->type = QBKeyHeader::COMPILED_FUNCTION;
        header->pFunction = scripts[i].pFunction;
    }
    else
        MessageBox(0, "couldn't add script", scripts[i].name, 0);
}
To get pointer to game class use this codes:

Code: Select all

Skater* skater = Skater::GetSkater();

Vadru
VIP
Posts: 42
Joined: Wed Jul 07, 2010 2:39 pm

Re: LevelMod Extension c++ lib

Post by Vadru »

I have now made a github for this project.

https://github.com/Vadru93/THPS3-QB-Extension

Post Reply