ALERT!
Click here to register with a few steps and explore all our cool stuff we have to offer!
Home
Upgrade
Credits
Help
Search
Awards
Achievements
 507

RPF Loading (addRockstarPackFile) with correct structure

by WalkingPrinter - 09-13-2025 - 02:45 PM
#1
the scene may be dead, but i keep posting shit anyway
Enjoy :D
 
Code:
struct DataFile {
            char m_filename[128];
            DWORD m_fileType;
            s32 m_handle;
            bool m_locked;
            bool m_enforceLsnSorting;
            bool m_loadCompletely;
            bool m_disabled;
            bool m_persistent;
            bool m_overlay;
            bool m_patchFile;
            DWORD m_contents;  // treat as int if needed
            DWORD m_installPartition;  // treat as int if needed
        };

        void RegisterRPF(std::string Path) {
            DataFile rpfData = {};

            strncpy(rpfData.m_filename, Path.c_str(), sizeof(rpfData.m_filename) - 1);

            rpfData.m_fileType = 4;
            rpfData.m_handle = static_cast<s32>(0x8324A88C);

            rpfData.m_locked = true;
            rpfData.m_enforceLsnSorting = false;
            rpfData.m_loadCompletely = true;
            rpfData.m_disabled = false;
            rpfData.m_persistent = true;
            rpfData.m_overlay = false;
            rpfData.m_patchFile = true;

            const char* updateCrcString = reinterpret_cast<const char*>(0x82001B80);

            rpfData.m_contents = 0xFFFFFFFF;
            rpfData.m_installPartition = 0;

            niggerware::utils::call::invoke<void>(0x827F83C8, &rpfData);
        }
DISCORD: xexghosted
Reply

Users browsing: 1 Guest(s)