Quote:
Originally Posted by Jakeyoung999
Hi guys,
Looking to purchase force save but can’t seem to find anyone selling it with a good rep or any reviews.
I would like the actual programme not an account or it being part of an internal separate cheat please
Any help is appreciated! Thanks ❤️
|
Add this namespace on top of your source file, it includes everything that's needed for Force Save.
namespace game
{
ptrdiff_t s_blueprintData = ImageBase + 0x11E15490;
ptrdiff_t s_blueprintsDirty = ImageBase + 0x11E3251C;
enum DDLAccessOp : __int32
{
DDL_ACCESS_READ = 0x0,
DDL_ACCESS_WRITE = 0x1,
};
struct DDLContext
{
void* buff;
int len;
const void* def;
void(__fastcall* accessCB)(const DDLContext*, unsigned int, unsigned int, DDLAccessOp);
void* userData;
bool obfuscated;
unsigned int randomInt;
};
struct DDLState
{
bool isValid;
int offset;
int arrayIndex;
void* member;
const void* ddlDef;
};
enum DDLType : __int32
{
DDL_INVALID_TYPE = -0x1,
DDL_BYTE_TYPE = 0x0,
DDL_SHORT_TYPE = 0x1,
DDL_UINT_TYPE = 0x2,
DDL_INT_TYPE = 0x3,
DDL_UINT64_TYPE = 0x4,
DDL_HASH_TYPE = 0x5,
DDL_FLOAT_TYPE = 0x6,
DDL_FIXEDPOINT_TYPE = 0x7,
DDL_STRING_TYPE = 0x8,
DDL_STRUCT_TYPE = 0x9,
DDL_ENUM_TYPE = 0xA,
DDL_PAD_TYPE = 0xB,
};
union DDLValue
{
float fixedPointValue;
int intValue;
unsigned int uintValue;
unsigned __int64 uint64Value;
float floatValue;
const char* stringPtr;
};
struct StringTable
{
const char* name;
int columnCount;
int rowCount;
int uniqueCellCount;
unsigned __int16* cellIndices;
int* hashes;
const char** strings;
};
void* Com_DDL_LoadAsset(const char* fileName)
{
return ((void* (__fastcall*)(const char*))(ImageBase + 0x336AE30))(fileName);
}
bool Com_DDL_CreateContext(void* buffer, int len, const void* def, DDLContext* const ddlContext, void(__fastcall* accessCB)(const DDLContext*, unsigned int, unsigned int, DDLAccessOp), void* userData)
{
return ((bool(__fastcall*)(void*, int, const void*, DDLContext* const, void(__fastcall*)(const DDLContext*, unsigned int, unsigned int, DDLAccessOp), void*))(ImageBase + 0x336A9C0))(buffer, len, def, ddlContext, accessCB, userData);
}
char NavigateBlueprintDDL(DDLState* state, const char* path)
{
return ((char(__fastcall*)(DDLState*, const char*))(ImageBase + 0x2BA1C00))(state, path);
}
__int64 DDL_GetType(const DDLState* state)
{
return ((__int64(__fastcall*)(const DDLState*))(ImageBase + 0x6B6CB10))(state);
}
DDLState* DDL_GetRootState(DDLState* result, const void* ddlDef)
{
return ((DDLState * (__fastcall*)(DDLState*, const void*))(ImageBase + 0x6B6C890))(result, ddlDef);
}
bool DDL_SetFloat(const DDLState* state, DDLContext* ddlContext, double val)
{
return((bool(__fastcall*)(const DDLState*, DDLContext*, double))(ImageBase + 0x6B6D770))(state, ddlContext, val);
}
bool DDL_SetInt(const DDLState* state, DDLContext* ddlContext, int val)
{
return ((bool(__fastcall*)(const DDLState*, DDLContext*, int))(ImageBase + 0x6B6D790))(state, ddlContext, val);
}
char DDL_SetString(const DDLState* state, DDLContext* ddlContext, const char* val)
{
return ((char(__fastcall*)(const DDLState*, DDLContext*, const char*))(ImageBase + 0x6B6D890))(state, ddlContext, val);
}
bool DDL_SetEnum(const DDLState* state, DDLContext* ddlContext, const char* val)
{
return ((bool(__fastcall*)(const DDLState*, DDLContext*, const char*))(ImageBase + 0x6B6D680))(state, ddlContext, val);
}
void StringTable_GetAsset(const char* filename, const StringTable** tablePtr)
{
((void(__fastcall*)(const char*, const StringTable**))(ImageBase + 0x3991670))(filename, tablePtr);
}
const char* StringTable_GetColumnValueForRow(const StringTable* table, const int row, const int column)
{
return ((const char* (__fastcall*)(const StringTable*, const int, const int))(ImageBase + 0x39916B0))(table, row, column);
}
bool SetBlueprintData(const char* path, DDLValue value)
{
void* v6;
DDLType v9;
DDLState state;
DDLContext ddlContext;
v6 = Com_DDL_LoadAsset("ddl/mp/blueprints.ddl");
if (!Com_DDL_CreateContext((void*)s_blueprintData, 0x1D000, v6, &ddlContext, 0, 0))
return false;
DDL_GetRootState(&state, v6);
if (!NavigateBlueprintDDL(&state, path))
return false;
v9 = (DDLType)DDL_GetType(&state);
switch (v9)
{
case DDL_FLOAT_TYPE:
return DDL_SetFloat(&state, &ddlContext, value.floatValue);
case DDL_STRING_TYPE:
return DDL_SetString(&state, &ddlContext, value.stringPtr);
case DDL_ENUM_TYPE:
return DDL_SetEnum(&state, &ddlContext, value.stringPtr);
}
return DDL_SetInt(&state, &ddlContext, value.intValue);
}
void SetBlueprintName(const char* blueprintName, const char* weaponName, int blueprintIndex)
{
char buff[256];
sprintf_s(buff, xorstr_("000%s"), blueprintName);
DDLValue name;
name.stringPtr = buff;
char buf[CHAR_MAX];
sprintf_s(buf, "blueprints.%s.weaponSetup.%i.blueprintName", weaponName, blueprintIndex);
SetBlueprintData(buf, name);
}
void SetBlueprintCamo(const char* camoName, const char* weaponName, int blueprintIndex)
{
DDLValue camo;
camo.stringPtr = camoName;
char buf[CHAR_MAX];
sprintf_s(buf, "blueprints.%s.weaponSetup.%i.camo", weaponName, blueprintIndex);
SetBlueprintData(buf, camo);
}
void SetBlueprintWeapon(const char* weaponName, int blueprintIndex)
{
DDLValue weapon;
weapon.stringPtr = weaponName;
char buf[CHAR_MAX];
sprintf_s(buf, "blueprints.%s.weaponSetup.%i.weapon", weaponName, blueprintIndex);
SetBlueprintData(buf, weapon);
}
}
After pasting all of that you'd need to loop through all weapon names and set the data you want name and/or camo like so.
This example will save all of your blueprints with the name "Force Save!" in pink and with Vanguard Atomic camo.
const game::StringTable* weapon_ids = nullptr;
game::StringTable_GetAsset("loot/weapon_ids.csv", &weapon_ids);
if (weapon_ids != nullptr)
{
for (int i = 0; i < weapon_ids->rowCount; i++)
{
const char* weaponName = game::StringTable_GetColumnValueForRow(weapon_ids, i, 1);
// Slots go from 0-4 in-game.
game::SetBlueprintName("^6Force Save!", weaponName, 0);
game::SetBlueprintCamo("s4_camo_11c", weaponName, 0);
game::SetBlueprintWeapon(weaponName, 0);
}
*(bool*)game::s_blueprintsDirty = 1;
}