mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 10:52:22 +01:00
nevermind screw v3 im about to release
This commit is contained in:
@@ -323,6 +323,8 @@ void PickLootDropsFromLootPackage(const std::vector<UDataTable*>& LPTables, cons
|
||||
}
|
||||
}
|
||||
|
||||
// #define brudda
|
||||
|
||||
std::vector<LootDrop> PickLootDrops(FName TierGroupName, int ForcedLootTier, bool bPrint, int recursive)
|
||||
{
|
||||
std::vector<LootDrop> LootDrops;
|
||||
@@ -361,6 +363,7 @@ std::vector<LootDrop> PickLootDrops(FName TierGroupName, int ForcedLootTier, boo
|
||||
|
||||
if (LootTierDataSoft.IsValid() && LootPackagesSoft.IsValid())
|
||||
{
|
||||
#ifndef brudda
|
||||
auto LootTierDataStr = LootTierDataSoft.SoftObjectPtr.ObjectID.AssetPathName.ToString();
|
||||
auto LootPackagesStr = LootPackagesSoft.SoftObjectPtr.ObjectID.AssetPathName.ToString();
|
||||
auto LootTierDataTableIsComposite = LootTierDataStr.contains("Composite");
|
||||
@@ -368,6 +371,10 @@ std::vector<LootDrop> PickLootDrops(FName TierGroupName, int ForcedLootTier, boo
|
||||
|
||||
auto StrongLootTierData = LootTierDataSoft.Get(LootTierDataTableIsComposite ? CompositeDataTableClass : UDataTable::StaticClass(), true);
|
||||
auto StrongLootPackage = LootPackagesSoft.Get(LootPackageTableIsComposite ? CompositeDataTableClass : UDataTable::StaticClass(), true);
|
||||
#else
|
||||
auto StrongLootTierData = (UDataTable*)Assets::LoadAsset(LootTierDataSoft.SoftObjectPtr.ObjectID.AssetPathName);
|
||||
auto StrongLootPackage = (UDataTable*)Assets::LoadAsset(LootPackagesSoft.SoftObjectPtr.ObjectID.AssetPathName);
|
||||
#endif
|
||||
|
||||
if (StrongLootTierData && StrongLootPackage)
|
||||
{
|
||||
@@ -381,8 +388,13 @@ std::vector<LootDrop> PickLootDrops(FName TierGroupName, int ForcedLootTier, boo
|
||||
|
||||
if (!bFoundPlaylistTable)
|
||||
{
|
||||
#ifdef brudda
|
||||
LTDTables.push_back((UDataTable*)Assets::LoadAsset(UKismetStringLibrary::Conv_StringToName(L"/Game/Items/Datatables/AthenaLootTierData_Client.AthenaLootTierData_Client")));
|
||||
LPTables.push_back((UDataTable*)Assets::LoadAsset(UKismetStringLibrary::Conv_StringToName(L"/Game/Items/Datatables/AthenaLootPackages_Client.AthenaLootPackages_Client")));
|
||||
#else
|
||||
LTDTables.push_back(LoadObject<UDataTable>(L"/Game/Items/Datatables/AthenaLootTierData_Client.AthenaLootTierData_Client"));
|
||||
LPTables.push_back(LoadObject<UDataTable>(L"/Game/Items/Datatables/AthenaLootPackages_Client.AthenaLootPackages_Client"));
|
||||
#endif
|
||||
}
|
||||
|
||||
// LTDTables.push_back(LoadObject<UDataTable>(L"/Game/Athena/Playlists/Playground/AthenaLootTierData_Client.AthenaLootTierData_Client"));
|
||||
|
||||
@@ -249,6 +249,7 @@
|
||||
<ClCompile Include="Object.cpp" />
|
||||
<ClCompile Include="PlayerController.cpp" />
|
||||
<ClCompile Include="PlayerState.cpp" />
|
||||
<ClCompile Include="reboot.cpp" />
|
||||
<ClCompile Include="SavePackage.cpp" />
|
||||
<ClCompile Include="UnrealMath.cpp" />
|
||||
<ClCompile Include="UnrealNames.cpp" />
|
||||
|
||||
@@ -106,9 +106,6 @@
|
||||
<ClCompile Include="FortPlayerPawn.cpp">
|
||||
<Filter>FortniteGame\Source\FortniteGame\Private\Pawns</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="events.cpp">
|
||||
<Filter>Reboot\Private\Gameplay</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="FortPlayerControllerAthena.cpp">
|
||||
<Filter>FortniteGame\Source\FortniteGame\Private\Player</Filter>
|
||||
</ClCompile>
|
||||
@@ -271,6 +268,12 @@
|
||||
<ClCompile Include="inc.cpp">
|
||||
<Filter>Reboot\Private</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="events.cpp">
|
||||
<Filter>Reboot\Private</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="reboot.cpp">
|
||||
<Filter>Reboot\Private</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="log.h" />
|
||||
@@ -546,9 +549,6 @@
|
||||
<ClInclude Include="commands.h">
|
||||
<Filter>Reboot\Public</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="ai.h">
|
||||
<Filter>Reboot\Public\Gameplay</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Player.h">
|
||||
<Filter>Engine\Source\Runtime\Engine\Classes\Engine</Filter>
|
||||
</ClInclude>
|
||||
@@ -859,6 +859,9 @@
|
||||
<ClInclude Include="inc.h">
|
||||
<Filter>Reboot\Public</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="ai.h">
|
||||
<Filter>Reboot\Public</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Filter Include="Engine">
|
||||
@@ -1011,9 +1014,6 @@
|
||||
<Filter Include="Reboot\Public">
|
||||
<UniqueIdentifier>{ad1c6299-9a6d-4eba-a1f8-66642a8afd21}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Reboot\Public\Gameplay">
|
||||
<UniqueIdentifier>{9923af6f-0a65-43f7-ad58-8a66e83814ba}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="FortniteGame\Source\FortniteGame\Public\Creative">
|
||||
<UniqueIdentifier>{51b57917-fec7-41b7-bdc8-ad284a5385a4}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -1086,9 +1086,6 @@
|
||||
<Filter Include="Reboot\Private">
|
||||
<UniqueIdentifier>{563ca89b-be74-42a6-a995-f87ac7a532e4}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Reboot\Private\Gameplay">
|
||||
<UniqueIdentifier>{52d438db-beaf-44be-bddd-9aeb07c2459f}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="FortniteGame\Source\FortniteGame\Public\Athena\Modifiers">
|
||||
<UniqueIdentifier>{39656a6c-bfe1-4521-8652-aea0146564d6}</UniqueIdentifier>
|
||||
</Filter>
|
||||
|
||||
@@ -291,6 +291,9 @@ void Addresses::FindAll()
|
||||
LOG_INFO(LogDev, "Finding PickSupplyDropLocation");
|
||||
Addresses::PickSupplyDropLocation = FindPickSupplyDropLocation();
|
||||
|
||||
LOG_INFO(LogDev, "Finding LoadAsset");
|
||||
Addresses::LoadAsset = FindLoadAsset();
|
||||
|
||||
LOG_INFO(LogDev, "Finished finding!");
|
||||
}
|
||||
|
||||
@@ -359,6 +362,7 @@ void Addresses::Print()
|
||||
LOG_INFO(LogDev, "CombinePickupLea: 0x{:x}", CombinePickupLea - Base);
|
||||
LOG_INFO(LogDev, "CreateBuildingActorCallForDeco: 0x{:x}", CreateBuildingActorCallForDeco - Base);
|
||||
LOG_INFO(LogDev, "PickSupplyDropLocation: 0x{:x}", PickSupplyDropLocation - Base);
|
||||
LOG_INFO(LogDev, "LoadAsset: 0x{:x}", LoadAsset - Base)
|
||||
}
|
||||
|
||||
void Offsets::FindAll()
|
||||
|
||||
@@ -69,6 +69,7 @@ namespace Addresses
|
||||
extern inline uint64 CombinePickupLea = 0;
|
||||
extern inline uint64 CreateBuildingActorCallForDeco = 0;
|
||||
extern inline uint64 PickSupplyDropLocation = 0;
|
||||
extern inline uint64 LoadAsset = 0;
|
||||
|
||||
void SetupVersion(); // Finds Engine Version
|
||||
void FindAll();
|
||||
|
||||
@@ -92,7 +92,9 @@ static void SetupServerBotManager()
|
||||
static auto CachedGameModeOffset = ServerBotManager->GetOffset("CachedGameMode");
|
||||
ServerBotManager->Get(CachedGameModeOffset) = GameMode;
|
||||
|
||||
static auto CachedGameStateOffset = ServerBotManager->GetOffset("CachedGameState");
|
||||
static auto CachedGameStateOffset = ServerBotManager->GetOffset("CachedGameState", false);
|
||||
|
||||
if (CachedGameStateOffset != -1)
|
||||
ServerBotManager->Get(CachedGameStateOffset) = GameState;
|
||||
|
||||
static auto CachedBotMutatorOffset = ServerBotManager->GetOffset("CachedBotMutator");
|
||||
|
||||
@@ -168,6 +168,22 @@ static inline uint64 FindCreateNetDriver()
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline uint64 FindLoadAsset()
|
||||
{
|
||||
auto Addrr = Memcury::Scanner::FindStringRef(L"Loaded delay-load asset %s").Get();
|
||||
|
||||
for (int i = 0; i < 2000; i++)
|
||||
{
|
||||
if (*(uint8_t*)(uint8_t*)(Addrr - i) == 0x48 && *(uint8_t*)(uint8_t*)(Addrr - i + 1) == 0x89 &&
|
||||
(*(uint8_t*)(uint8_t*)(Addrr - i + 2) == 0x74 || *(uint8_t*)(uint8_t*)(Addrr - i + 2) == 0x6C))
|
||||
{
|
||||
return Addrr - i;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline uint64 FindKickPlayer()
|
||||
{
|
||||
if (Engine_Version == 416)
|
||||
|
||||
29
Project Reboot 3.0/reboot.cpp
Normal file
29
Project Reboot 3.0/reboot.cpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#include "reboot.h"
|
||||
|
||||
#include "SoftObjectPtr.h"
|
||||
|
||||
#include "KismetStringLibrary.h"
|
||||
|
||||
UObject* Assets::LoadAsset(FName Name, bool ShowDelayTimes)
|
||||
{
|
||||
static UObject* (*LoadAssetOriginal)(FName a1, bool a2);
|
||||
|
||||
return LoadAssetOriginal(Name, ShowDelayTimes);
|
||||
}
|
||||
|
||||
UObject* Assets::LoadSoftObject(void* SoftObjectPtr)
|
||||
{
|
||||
if (Engine_Version == 416)
|
||||
{
|
||||
auto tAssetPtr = (TAssetPtr<UObject>*)SoftObjectPtr;
|
||||
// return LoadAsset(tAssetPtr->AssetPtr.ObjectID.AssetLongPathname.);
|
||||
return nullptr; // later
|
||||
}
|
||||
|
||||
auto tSoftObjectPtr = (TSoftObjectPtr<UObject>*)SoftObjectPtr;
|
||||
|
||||
// if (auto WeakObject = tSoftObjectPtr->GetByWeakObject())
|
||||
// return WeakObject;
|
||||
|
||||
return Assets::LoadAsset(tSoftObjectPtr->SoftObjectPtr.ObjectID.AssetPathName);
|
||||
}
|
||||
@@ -384,6 +384,13 @@ static void CopyStruct(void* Dest, void* Src, size_t Size, UStruct* Struct = nul
|
||||
}
|
||||
}
|
||||
|
||||
class Assets
|
||||
{
|
||||
public:
|
||||
static UObject* LoadAsset(FName Name, bool ShowDelayTimes = false);
|
||||
static UObject* LoadSoftObject(void* SoftObjectPtr);
|
||||
};
|
||||
|
||||
template <typename T = __int64>
|
||||
static T* Alloc(size_t Size = sizeof(T), bool bUseFMemoryRealloc = false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user