mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 02:42:22 +01:00
lategame
lategame pretty much working, work on some string stuff, some memory optimizations, summon should now work with non-bps
This commit is contained in:
@@ -68,6 +68,8 @@ void UAbilitySystemComponent::ServerEndAbility(FGameplayAbilitySpecHandle Abilit
|
||||
CopyStruct((FPredictionKey*)(__int64(Params) + PredictionKeyOffset), PredictionKey, FPredictionKey::GetStructSize());
|
||||
|
||||
this->ProcessEvent(ServerEndAbilityFn, Params);
|
||||
|
||||
VirtualFree(Params, 0, MEM_RELEASE);
|
||||
}
|
||||
|
||||
void UAbilitySystemComponent::ClientEndAbility(FGameplayAbilitySpecHandle AbilityToEnd, FGameplayAbilityActivationInfo* ActivationInfo)
|
||||
@@ -83,6 +85,8 @@ void UAbilitySystemComponent::ClientEndAbility(FGameplayAbilitySpecHandle Abilit
|
||||
CopyStruct((FGameplayAbilityActivationInfo*)(__int64(Params) + ActivationInfoOffset), ActivationInfo, FGameplayAbilityActivationInfo::GetStructSize());
|
||||
|
||||
this->ProcessEvent(ClientEndAbilityFn, Params);
|
||||
|
||||
VirtualFree(Params, 0, MEM_RELEASE);
|
||||
}
|
||||
|
||||
void UAbilitySystemComponent::ClientCancelAbility(FGameplayAbilitySpecHandle AbilityToCancel, FGameplayAbilityActivationInfo* ActivationInfo)
|
||||
@@ -98,6 +102,8 @@ void UAbilitySystemComponent::ClientCancelAbility(FGameplayAbilitySpecHandle Abi
|
||||
CopyStruct((FGameplayAbilityActivationInfo*)(__int64(Params) + ActivationInfoOffset), ActivationInfo, FGameplayAbilityActivationInfo::GetStructSize());
|
||||
|
||||
this->ProcessEvent(ClientCancelAbilityFn, Params);
|
||||
|
||||
VirtualFree(Params, 0, MEM_RELEASE);
|
||||
}
|
||||
|
||||
bool UAbilitySystemComponent::HasAbility(UObject* DefaultAbility)
|
||||
|
||||
@@ -325,6 +325,8 @@ public:
|
||||
}
|
||||
|
||||
void FreeGood(SizeType Size = sizeof(InElementType))
|
||||
{
|
||||
if (Data)
|
||||
{
|
||||
if (true)
|
||||
{
|
||||
@@ -337,6 +339,7 @@ public:
|
||||
{
|
||||
VirtualFree(Data, 0, MEM_RELEASE);
|
||||
}
|
||||
}
|
||||
|
||||
Data = nullptr;
|
||||
ArrayNum = 0;
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
|
||||
void UCheatManager::Teleport()
|
||||
{
|
||||
static auto TeleportFn = FindObject<UFunction>("/Script/Engine.CheatManager.Teleport");
|
||||
static auto TeleportFn = FindObject<UFunction>(L"/Script/Engine.CheatManager.Teleport");
|
||||
this->ProcessEvent(TeleportFn);
|
||||
}
|
||||
|
||||
UClass* UCheatManager::StaticClass()
|
||||
{
|
||||
static auto Class = FindObject<UClass>("/Script/Engine.CheatManager");
|
||||
static auto Class = FindObject<UClass>(L"/Script/Engine.CheatManager");
|
||||
return Class;
|
||||
}
|
||||
@@ -130,6 +130,37 @@ UClass* AFortGameModeAthena::GetVehicleClassOverride(UClass* DefaultClass)
|
||||
return GetVehicleClassOverride_Params.ReturnValue;
|
||||
}
|
||||
|
||||
void AFortGameModeAthena::SkipAircraft()
|
||||
{
|
||||
// reversed from 10.40
|
||||
|
||||
auto GameState = GetGameStateAthena();
|
||||
|
||||
static auto bGameModeWillSkipAircraftOffset = GameState->GetOffset("bGameModeWillSkipAircraft", false);
|
||||
|
||||
if (bGameModeWillSkipAircraftOffset != -1) // hmm?
|
||||
GameState->Get<bool>(bGameModeWillSkipAircraftOffset) = true;
|
||||
|
||||
static auto OnAircraftExitedDropZoneFn = FindObject<UFunction>("/Script/FortniteGame.FortGameModeAthena.OnAircraftExitedDropZone");
|
||||
|
||||
static auto AircraftsOffset = GameState->GetOffset("Aircrafts", false);
|
||||
|
||||
if (AircraftsOffset == -1)
|
||||
{
|
||||
static auto AircraftOffset = GameState->GetOffset("Aircraft");
|
||||
this->ProcessEvent(OnAircraftExitedDropZoneFn, &GameState->Get<AActor*>(AircraftOffset));
|
||||
}
|
||||
else
|
||||
{
|
||||
auto Aircrafts = GameState->GetPtr<TArray<AActor*>>(AircraftsOffset);
|
||||
|
||||
for (int i = 0; i < Aircrafts->Num(); i++)
|
||||
{
|
||||
this->ProcessEvent(OnAircraftExitedDropZoneFn, &Aircrafts->at(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void AFortGameModeAthena::HandleSpawnRateForActorClass(UClass* ActorClass, float SpawnPercentage)
|
||||
{
|
||||
TArray<AActor*> AllActors = UGameplayStatics::GetAllActorsOfClass(GetWorld(), ActorClass);
|
||||
@@ -466,7 +497,7 @@ bool AFortGameModeAthena::Athena_ReadyToStartMatchHook(AFortGameModeAthena* Game
|
||||
ShowFoundation(Lake);
|
||||
}
|
||||
|
||||
auto FloatingIsland = Fortnite_Version == 6.10 ? FindObject<AActor>(L"/Game/Athena/Maps/Athena_POI_Foundations.Athena_POI_Foundations.PersistentLevel.LF_Athena_StreamingTest13") :
|
||||
auto FloatingIsland = Fortnite_Version <= 6.10 ? FindObject<AActor>(L"/Game/Athena/Maps/Athena_POI_Foundations.Athena_POI_Foundations.PersistentLevel.LF_Athena_StreamingTest13") :
|
||||
FindObject<AActor>(L"/Game/Athena/Maps/Athena_POI_Foundations.Athena_POI_Foundations.PersistentLevel.LF_FloatingIsland");
|
||||
|
||||
ShowFoundation(FloatingIsland);
|
||||
@@ -1138,8 +1169,8 @@ void AFortGameModeAthena::Athena_HandleStartingNewPlayerHook(AFortGameModeAthena
|
||||
}
|
||||
}
|
||||
|
||||
auto SpawnIsland_FloorLoot = FindObject<UClass>("/Game/Athena/Environments/Blueprints/Tiered_Athena_FloorLoot_Warmup.Tiered_Athena_FloorLoot_Warmup_C");
|
||||
auto BRIsland_FloorLoot = FindObject<UClass>("/Game/Athena/Environments/Blueprints/Tiered_Athena_FloorLoot_01.Tiered_Athena_FloorLoot_01_C");
|
||||
auto SpawnIsland_FloorLoot = FindObject<UClass>(L"/Game/Athena/Environments/Blueprints/Tiered_Athena_FloorLoot_Warmup.Tiered_Athena_FloorLoot_Warmup_C");
|
||||
auto BRIsland_FloorLoot = FindObject<UClass>(L"/Game/Athena/Environments/Blueprints/Tiered_Athena_FloorLoot_01.Tiered_Athena_FloorLoot_01_C");
|
||||
|
||||
TArray<AActor*> SpawnIsland_FloorLoot_Actors = UGameplayStatics::GetAllActorsOfClass(GetWorld(), SpawnIsland_FloorLoot);
|
||||
TArray<AActor*> BRIsland_FloorLoot_Actors = UGameplayStatics::GetAllActorsOfClass(GetWorld(), BRIsland_FloorLoot);
|
||||
|
||||
@@ -244,6 +244,7 @@ public:
|
||||
|
||||
FName RedirectLootTier(const FName& LootTier);
|
||||
UClass* GetVehicleClassOverride(UClass* DefaultClass);
|
||||
void SkipAircraft();
|
||||
void PauseSafeZone(bool bPaused = true);
|
||||
|
||||
static void HandleSpawnRateForActorClass(UClass* ActorClass, float SpawnPercentage); // idk where to put
|
||||
|
||||
@@ -636,10 +636,9 @@ void AFortPlayerController::ServerAttemptAircraftJumpHook(AFortPlayerController*
|
||||
// if (!PlayerController->bInAircraft)
|
||||
// return;
|
||||
|
||||
auto GameMode = (AFortGameModeAthena*)GetWorld()->GetGameMode();
|
||||
LOG_INFO(LogDev, "ServerAttemptAircraftJumpHook!");
|
||||
|
||||
if (false)
|
||||
{
|
||||
auto GameMode = (AFortGameModeAthena*)GetWorld()->GetGameMode();
|
||||
auto GameState = GameMode->GetGameStateAthena();
|
||||
|
||||
AActor* AircraftToJumpFrom = nullptr;
|
||||
@@ -654,12 +653,14 @@ void AFortPlayerController::ServerAttemptAircraftJumpHook(AFortPlayerController*
|
||||
else
|
||||
{
|
||||
auto Aircrafts = GameState->GetPtr<TArray<AActor*>>(AircraftsOffset);
|
||||
AircraftToJumpFrom = Aircrafts->Num() > 0 ? Aircrafts->at(0) : nullptr;
|
||||
AircraftToJumpFrom = Aircrafts->Num() > 0 ? Aircrafts->at(0) : nullptr; // skunky
|
||||
}
|
||||
|
||||
if (!AircraftToJumpFrom)
|
||||
return ServerAttemptAircraftJumpOriginal(PC, ClientRotation);
|
||||
|
||||
if (false)
|
||||
{
|
||||
auto NewPawn = GameMode->SpawnDefaultPawnForHook(GameMode, (AController*)PlayerController, AircraftToJumpFrom);
|
||||
PlayerController->Possess(NewPawn);
|
||||
}
|
||||
@@ -699,7 +700,11 @@ void AFortPlayerController::ServerAttemptAircraftJumpHook(AFortPlayerController*
|
||||
NewPawnAsFort->SetHealth(100); // needed with server restart player?
|
||||
|
||||
if (Globals::bLateGame)
|
||||
{
|
||||
NewPawnAsFort->SetShield(100);
|
||||
|
||||
NewPawnAsFort->TeleportTo(AircraftToJumpFrom->GetActorLocation(), FRotator());
|
||||
}
|
||||
}
|
||||
|
||||
// PlayerController->ServerRestartPlayer();
|
||||
|
||||
@@ -100,7 +100,7 @@ void AFortPlayerPawnAthena::OnCapsuleBeginOverlapHook(UObject* Context, FFrame*
|
||||
// std::cout << "bFoundStack: " << bFoundStack << '\n';
|
||||
|
||||
if (!bCanStack ? (!bFoundStack ? true : ItemDefinition->DoesAllowMultipleStacks()) : true)
|
||||
ServerHandlePickupHook(Pawn, Pickup, 0.4, FVector(), true);
|
||||
ServerHandlePickupHook(Pawn, Pickup, 0.4f, FVector(), true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -225,43 +225,6 @@ APawn* AGameModeBase::SpawnDefaultPawnForHook(AGameModeBase* GameMode, AControll
|
||||
|
||||
WorldInventory->Update();
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GameState->GetGamePhase() == EAthenaGamePhase::Aircraft)
|
||||
{
|
||||
if (Globals::bLateGame)
|
||||
{
|
||||
static auto WoodItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/WoodItemData.WoodItemData");
|
||||
static auto StoneItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/StoneItemData.StoneItemData");
|
||||
static auto MetalItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/MetalItemData.MetalItemData");
|
||||
|
||||
static auto Rifle = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Assault_AutoHigh_Athena_SR_Ore_T03.WID_Assault_AutoHigh_Athena_SR_Ore_T03");
|
||||
static auto Shotgun = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Shotgun_Standard_Athena_SR_Ore_T03.WID_Shotgun_Standard_Athena_SR_Ore_T03");
|
||||
static auto SMG = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03.WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03");
|
||||
|
||||
static auto MiniShields = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Consumables/ShieldSmall/Athena_ShieldSmall.Athena_ShieldSmall");
|
||||
|
||||
static auto Shells = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataShells.AthenaAmmoDataShells");
|
||||
static auto Medium = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsMedium.AthenaAmmoDataBulletsMedium");
|
||||
static auto Light = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsLight.AthenaAmmoDataBulletsLight");
|
||||
static auto Heavy = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsHeavy.AthenaAmmoDataBulletsHeavy");
|
||||
|
||||
WorldInventory->AddItem(WoodItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(StoneItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(MetalItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(Rifle, nullptr, 1);
|
||||
WorldInventory->AddItem(Shotgun, nullptr, 1);
|
||||
WorldInventory->AddItem(SMG, nullptr, 1);
|
||||
WorldInventory->AddItem(MiniShields, nullptr, 6);
|
||||
WorldInventory->AddItem(Shells, nullptr, 999);
|
||||
WorldInventory->AddItem(Medium, nullptr, 999);
|
||||
WorldInventory->AddItem(Light, nullptr, 999);
|
||||
WorldInventory->AddItem(Heavy, nullptr, 999);
|
||||
|
||||
WorldInventory->Update();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -146,22 +146,24 @@ public:
|
||||
((UKismetSystemLibrary_LineTraceSingle_Params*)Params)->bTraceComplex = bTraceComplex;
|
||||
*(bool*)(__int64(Params) + bIgnoreSelfOffset) = bIgnoreSelf;
|
||||
|
||||
static auto KismetSystemLibrary = FindObject("/Script/Engine.Default__KismetSystemLibrary");
|
||||
static auto KismetSystemLibrary = FindObject(L"/Script/Engine.Default__KismetSystemLibrary");
|
||||
KismetSystemLibrary->ProcessEvent(LineTraceSingleFn, Params);
|
||||
|
||||
if (OutHit)
|
||||
*OutHit = (FHitResult*)(__int64(Params) + OutHitOffset);
|
||||
|
||||
return *(bool*)(__int64(Params) + ReturnValueOffset);
|
||||
bool ReturnValue = *(bool*)(__int64(Params) + ReturnValueOffset);
|
||||
|
||||
// free params frfr
|
||||
// VirtualFree(Params, 0, MEM_RELEASE);
|
||||
|
||||
return ReturnValue;
|
||||
}
|
||||
|
||||
static bool LineTraceSingleByProfile(UObject* WorldContextObject, const FVector& Start, const FVector& End, FName ProfileName, bool bTraceComplex,
|
||||
const TArray<AActor*>& ActorsToIgnore, EDrawDebugTrace DrawDebugType, FHitResult** OutHit, bool bIgnoreSelf, const FLinearColor& TraceColor,
|
||||
const FLinearColor& TraceHitColor, float DrawTime)
|
||||
{
|
||||
auto LineTraceSingleByProfileFn = FindObject<UFunction>("/Script/Engine.KismetSystemLibrary.LineTraceSingleByProfile");
|
||||
auto LineTraceSingleByProfileFn = FindObject<UFunction>(L"/Script/Engine.KismetSystemLibrary.LineTraceSingleByProfile");
|
||||
|
||||
if (!LineTraceSingleByProfileFn)
|
||||
return false;
|
||||
|
||||
@@ -10,7 +10,7 @@ FString& APlayerState::GetSavedNetworkAddress()
|
||||
|
||||
FString APlayerState::GetPlayerName()
|
||||
{
|
||||
static auto GetPlayerNameFn = FindObject<UFunction>("/Script/Engine.PlayerState.GetPlayerName");
|
||||
static auto GetPlayerNameFn = FindObject<UFunction>(L"/Script/Engine.PlayerState.GetPlayerName");
|
||||
|
||||
if (GetPlayerNameFn)
|
||||
{
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
#include "Array.h"
|
||||
#include "log.h"
|
||||
|
||||
// #define EXPERIMENTAL_FSTRING
|
||||
|
||||
class FString
|
||||
{
|
||||
public:
|
||||
@@ -30,18 +32,58 @@ public:
|
||||
return Data.Data;
|
||||
}
|
||||
|
||||
void Set(const wchar_t* NewStr) // by fischsalat
|
||||
void Set(const wchar_t* NewStr)
|
||||
{
|
||||
if (!NewStr/* || std::wcslen(NewStr) == 0 */) return;
|
||||
if (!NewStr/* || std::wcslen(NewStr) == 0 */)
|
||||
return;
|
||||
|
||||
#ifndef EXPERIMENTAL_FSTRING
|
||||
Data.ArrayMax = Data.ArrayNum = *NewStr ? (int)std::wcslen(NewStr) + 1 : 0;
|
||||
|
||||
if (Data.ArrayNum)
|
||||
Data.Data = const_cast<wchar_t*>(NewStr);
|
||||
#else
|
||||
Data.ArrayNum = (int)std::wcslen(NewStr) + 1;
|
||||
Data.ArrayMax = Data.ArrayNum;
|
||||
|
||||
if (Data.ArrayNum > 0) // this should never happen unless std::wcslen returns negative..
|
||||
{
|
||||
int amountToAlloc = (Data.ArrayNum * sizeof(TCHAR));
|
||||
|
||||
if (Addresses::Free && Addresses::Realloc)
|
||||
{
|
||||
Data.Data = (TCHAR*)FMemory::Realloc(0, amountToAlloc, 0);
|
||||
memcpy_s(Data.Data, amountToAlloc, NewStr, amountToAlloc);
|
||||
}
|
||||
else
|
||||
{
|
||||
Data.Data = (TCHAR*)NewStr;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
FString() {}
|
||||
|
||||
#ifdef EXPERIMENTAL_FSTRING
|
||||
FString& operator=(const wchar_t* Other)
|
||||
{
|
||||
this->Set(Other);
|
||||
return *this;
|
||||
}
|
||||
|
||||
FString& operator=(const FString& Other)
|
||||
{
|
||||
this->Set(Other.Data.Data);
|
||||
return *this;
|
||||
}
|
||||
|
||||
FString(const FString& Other)
|
||||
{
|
||||
this->Set(Other.Data.Data);
|
||||
}
|
||||
#endif
|
||||
|
||||
FString(const wchar_t* str)
|
||||
{
|
||||
Set(str);
|
||||
@@ -49,11 +91,28 @@ public:
|
||||
|
||||
~FString()
|
||||
{
|
||||
#ifdef EXPERIMENTAL_FSTRING
|
||||
if (Data.Data)
|
||||
{
|
||||
// LOG_INFO(LogDev, "Deconstructing FString!");
|
||||
// free(Data.Data);
|
||||
|
||||
if (Addresses::Realloc && Addresses::Free)
|
||||
{
|
||||
static void (*freeOriginal)(void*) = decltype(freeOriginal)(Addresses::Free);
|
||||
freeOriginal(Data.Data);
|
||||
}
|
||||
else
|
||||
{
|
||||
// VirtualFree(Data.Data, 0, MEM_RELEASE);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
// Free();
|
||||
|
||||
Data.Data = nullptr;
|
||||
Data.ArrayNum = 0;
|
||||
Data.ArrayMax = 0;
|
||||
}
|
||||
};
|
||||
@@ -83,7 +83,7 @@ void Addresses::SetupVersion()
|
||||
CLStr = CLStr.substr(0, CLStr.find_first_of('+'));
|
||||
Fortnite_CL = std::stoi(CLStr);
|
||||
Engine_Version = Fortnite_CL <= 3775276 ? 416 : 419; // std::stoi(FullVersion.substr(0, FullVersion.find_first_of('-')));
|
||||
Fortnite_Version = FullVersion.contains(("Next")) ? 2.4 : 1.8;
|
||||
// Fortnite_Version = FullVersion.contains(("Next")) ? 2.4 : 1.8;
|
||||
}
|
||||
|
||||
// Fortnite_Season = std::floor(Fortnite_Version);
|
||||
@@ -581,6 +581,8 @@ std::vector<uint64> Addresses::GetFunctionsToNull()
|
||||
{
|
||||
// toNull.push_back(Memcury::Scanner::FindPattern("48 8B C4 55 53 56 57 41 54 41 55 41 56 41 57 48 8D 68 A1 48 81 EC ? ? ? ? 45 33 F6 0F 29 70 A8 44 38 35").Get()); // zone
|
||||
// toNull.push_back(Memcury::Scanner::FindPattern("48 8B C4 48 89 58 08 55 56 57 41 54 41 55 41 56 41 57 48 8D 68 A8 48 81 EC ? ? ? ? 45").Get()); // GC
|
||||
// toNull.push_back(Memcury::Scanner::FindPattern("40 53 48 83 EC 20 8B D9 E8 ? ? ? ? B2 01 8B CB E8").Get()); // GC Caller 1
|
||||
// toNull.push_back(Memcury::Scanner::FindPattern("48 89 5C 24 ? 48 89 74 24 ? 48 89 7C 24 ? 55 41 55 41 56 48 8B EC 48 83 EC 50 83 65 28 00 40 B6 05 40 38 35 ? ? ? ? 4C").Get()); // InitializeUI
|
||||
}
|
||||
|
||||
if (Engine_Version >= 426)
|
||||
|
||||
@@ -4,12 +4,40 @@
|
||||
#include "OnlineReplStructs.h"
|
||||
#include "BuildingContainer.h"
|
||||
|
||||
class BotPOI
|
||||
{
|
||||
FVector CenterLocation;
|
||||
FVector Range; // this just has to be FVector2D
|
||||
};
|
||||
|
||||
class BotPOIEncounter
|
||||
{
|
||||
public:
|
||||
int NumChestsSearched;
|
||||
int NumAmmoBoxesSearched;
|
||||
int NumPlayersEncountered;
|
||||
};
|
||||
|
||||
class PlayerBot
|
||||
{
|
||||
public:
|
||||
AController* Controller = nullptr;
|
||||
BotPOIEncounter currentBotEncounter;
|
||||
int TotalPlayersEncountered;
|
||||
std::vector<BotPOI> POIsTraveled;
|
||||
float NextJumpTime = 1.0f;
|
||||
|
||||
void OnPlayerEncountered()
|
||||
{
|
||||
currentBotEncounter.NumPlayersEncountered++;
|
||||
TotalPlayersEncountered++;
|
||||
}
|
||||
|
||||
void MoveToNewPOI()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void Initialize(const FTransform& SpawnTransform)
|
||||
{
|
||||
auto GameState = Cast<AFortGameStateAthena>(GetWorld()->GetGameState());
|
||||
|
||||
@@ -93,7 +93,7 @@ void ServerCheatHook(AFortPlayerControllerAthena* PlayerController, FString Msg)
|
||||
if (!CurrentPlayerState)
|
||||
continue;
|
||||
|
||||
auto PlayerName = CurrentPlayerState->GetPlayerName();
|
||||
FString PlayerName = CurrentPlayerState->GetPlayerName();
|
||||
|
||||
if (PlayerName.ToString() == player) // hopefully we arent on adifferent thread
|
||||
{
|
||||
@@ -161,6 +161,8 @@ void ServerCheatHook(AFortPlayerControllerAthena* PlayerController, FString Msg)
|
||||
|
||||
// std::cout << "NumArgs: " << NumArgs << '\n';
|
||||
|
||||
// return;
|
||||
|
||||
bool bSendHelpMessage = false;
|
||||
|
||||
if (Arguments.size() >= 1)
|
||||
@@ -304,6 +306,12 @@ void ServerCheatHook(AFortPlayerControllerAthena* PlayerController, FString Msg)
|
||||
} */
|
||||
else if (Command == "op")
|
||||
{
|
||||
if (ReceivingController == PlayerController)
|
||||
{
|
||||
SendMessageToConsole(PlayerController, L"You can't op yourself!");
|
||||
return;
|
||||
}
|
||||
|
||||
if (IsOp(ReceivingController))
|
||||
{
|
||||
SendMessageToConsole(PlayerController, L"Player is already operator!");
|
||||
@@ -617,11 +625,11 @@ void ServerCheatHook(AFortPlayerControllerAthena* PlayerController, FString Msg)
|
||||
|
||||
auto& ClassName = Arguments[1];
|
||||
|
||||
if (ClassName.contains("/Script/"))
|
||||
/* if (ClassName.contains("/Script/"))
|
||||
{
|
||||
SendMessageToConsole(PlayerController, L"For now, we don't allow non-blueprint classes.\n");
|
||||
return;
|
||||
}
|
||||
} */
|
||||
|
||||
auto Pawn = ReceivingController->GetPawn();
|
||||
|
||||
@@ -648,7 +656,8 @@ void ServerCheatHook(AFortPlayerControllerAthena* PlayerController, FString Msg)
|
||||
}
|
||||
|
||||
static auto BGAClass = FindObject<UClass>(L"/Script/Engine.BlueprintGeneratedClass");
|
||||
auto ClassObj = LoadObject<UClass>(ClassName, BGAClass);
|
||||
static auto ClassClass = FindObject<UClass>(L"/Script/CoreUObject.Class");
|
||||
auto ClassObj = ClassName.contains("/Script/") ? FindObject<UClass>(ClassName, ClassClass) : LoadObject<UClass>(ClassName, BGAClass); // scuffy
|
||||
|
||||
if (ClassObj)
|
||||
{
|
||||
|
||||
@@ -250,6 +250,96 @@ UObject* GetAIDirectorHook()
|
||||
return GameMode->Get(AIDirectorOffset);
|
||||
}
|
||||
|
||||
void ChangeLevels()
|
||||
{
|
||||
constexpr bool bUseRemovePlayer = false;
|
||||
constexpr bool bUseSwitchLevel = false;
|
||||
constexpr bool bShouldRemoveLocalPlayer = true;
|
||||
|
||||
FString LevelB = Engine_Version < 424
|
||||
? L"open Athena_Terrain" : Engine_Version >= 500 ? Engine_Version >= 501
|
||||
? L"open Asteria_Terrain"
|
||||
: Globals::bCreative ? L"open Creative_NoApollo_Terrain"
|
||||
: L"open Artemis_Terrain"
|
||||
: Globals::bCreative ? L"open Creative_NoApollo_Terrain"
|
||||
: L"open Apollo_Terrain";
|
||||
|
||||
FString Level = Engine_Version < 424
|
||||
? L"Athena_Terrain" : Engine_Version >= 500 ? Engine_Version >= 501
|
||||
? L"Asteria_Terrain"
|
||||
: Globals::bCreative ? L"Creative_NoApollo_Terrain"
|
||||
: L"Artemis_Terrain"
|
||||
: Globals::bCreative ? L"Creative_NoApollo_Terrain"
|
||||
: L"Apollo_Terrain";
|
||||
|
||||
if (bUseSwitchLevel)
|
||||
{
|
||||
static auto SwitchLevel = FindObject<UFunction>(L"/Script/Engine.PlayerController.SwitchLevel");
|
||||
|
||||
GetLocalPlayerController()->ProcessEvent(SwitchLevel, &Level);
|
||||
|
||||
if (FindGIsServer())
|
||||
{
|
||||
*(bool*)FindGIsServer() = true;
|
||||
}
|
||||
|
||||
if (FindGIsClient())
|
||||
{
|
||||
*(bool*)FindGIsClient() = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (FindGIsServer())
|
||||
{
|
||||
*(bool*)FindGIsServer() = true;
|
||||
}
|
||||
|
||||
if (FindGIsClient())
|
||||
{
|
||||
*(bool*)FindGIsClient() = false;
|
||||
}
|
||||
|
||||
if (bShouldRemoveLocalPlayer)
|
||||
{
|
||||
if (!bUseRemovePlayer)
|
||||
{
|
||||
auto& LocalPlayers = GetLocalPlayers();
|
||||
|
||||
if (LocalPlayers.Num() && LocalPlayers.Data)
|
||||
{
|
||||
LocalPlayers.Remove(0);
|
||||
}
|
||||
}
|
||||
else if (bUseRemovePlayer)
|
||||
{
|
||||
UGameplayStatics::RemovePlayer((APlayerController*)GetLocalPlayerController(), true);
|
||||
}
|
||||
}
|
||||
|
||||
UKismetSystemLibrary::ExecuteConsoleCommand(GetWorld(), LevelB, nullptr);
|
||||
}
|
||||
|
||||
LOG_INFO(LogPlayer, "Switched level.");
|
||||
|
||||
if (bUseSwitchLevel && bShouldRemoveLocalPlayer)
|
||||
{
|
||||
if (!bUseRemovePlayer)
|
||||
{
|
||||
auto& LocalPlayers = GetLocalPlayers();
|
||||
|
||||
if (LocalPlayers.Num() && LocalPlayers.Data)
|
||||
{
|
||||
LocalPlayers.Remove(0);
|
||||
}
|
||||
}
|
||||
else if (bUseRemovePlayer)
|
||||
{
|
||||
UGameplayStatics::RemovePlayer((APlayerController*)GetLocalPlayerController(), true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DWORD WINAPI Main(LPVOID)
|
||||
{
|
||||
InitLogger();
|
||||
@@ -270,7 +360,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
|
||||
Addresses::SetupVersion();
|
||||
|
||||
NumElementsPerChunk = std::floor(Fortnite_Version) == 5 ? 0x10400 : 0x10000; // DUDE
|
||||
NumElementsPerChunk = std::floor(Fortnite_Version) >= 5 && Fortnite_Version <= 6 ? 0x10400 : 0x10000; // Idk what version tbh
|
||||
|
||||
Offsets::FindAll(); // We have to do this before because FindCantBuild uses FortAIController.CreateBuildingActor
|
||||
Offsets::Print();
|
||||
@@ -293,6 +383,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
}
|
||||
|
||||
bSwitchedInitialLevel = true;
|
||||
|
||||
// Globals::bAutoRestart = IsRestartingSupported();
|
||||
|
||||
static auto GameModeDefault = FindObject<AFortGameModeAthena>(L"/Script/FortniteGame.Default__FortGameModeAthena");
|
||||
@@ -349,11 +440,8 @@ DWORD WINAPI Main(LPVOID)
|
||||
|
||||
Hooking::MinHook::Hook((PVOID)Addresses::ActorGetNetMode, (PVOID)GetNetModeHook2, nullptr);
|
||||
|
||||
LOG_INFO(LogDev, "FindGIsServer: 0x{:x}", FindGIsServer() - __int64(GetModuleHandleW(0)));
|
||||
LOG_INFO(LogDev, "FindGIsClient: 0x{:x}", FindGIsClient() - __int64(GetModuleHandleW(0)));
|
||||
|
||||
bool bUseRemovePlayer = false;
|
||||
bool bUseSwitchLevel = false;
|
||||
// LOG_INFO(LogDev, "FindGIsServer: 0x{:x}", FindGIsServer() - __int64(GetModuleHandleW(0)));
|
||||
// LOG_INFO(LogDev, "FindGIsClient: 0x{:x}", FindGIsClient() - __int64(GetModuleHandleW(0)));
|
||||
|
||||
/* Hooking::MinHook::Hook(FindObject<ABuildingFoundation>(L"/Script/FortniteGame.Default__BuildingFoundation"),
|
||||
FindObject<UFunction>(L"/Script/FortniteGame.BuildingFoundation.SetDynamicFoundationTransform"),
|
||||
@@ -431,77 +519,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
else if (Fortnite_Version == 12.41)
|
||||
Hooking::MinHook::Hook((PVOID)(__int64(GetModuleHandleW(0)) + 0x2DBCBA0), (PVOID)CanCreateInCurrentContextHook, (PVOID*)&CanCreateInCurrentContextOriginal);
|
||||
|
||||
if (bUseSwitchLevel)
|
||||
{
|
||||
static auto SwitchLevel = FindObject<UFunction>(L"/Script/Engine.PlayerController.SwitchLevel");
|
||||
|
||||
FString Level = Engine_Version < 424
|
||||
? L"Athena_Terrain" : Engine_Version >= 500 ? Engine_Version >= 501
|
||||
? L"Asteria_Terrain"
|
||||
: Globals::bCreative ? L"Creative_NoApollo_Terrain"
|
||||
: L"Artemis_Terrain"
|
||||
: Globals::bCreative ? L"Creative_NoApollo_Terrain"
|
||||
: L"Apollo_Terrain";
|
||||
|
||||
GetLocalPlayerController()->ProcessEvent(SwitchLevel, &Level);
|
||||
|
||||
if (FindGIsServer())
|
||||
*(bool*)FindGIsServer() = true;
|
||||
|
||||
if (FindGIsClient())
|
||||
*(bool*)FindGIsClient() = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (FindGIsServer())
|
||||
*(bool*)FindGIsServer() = true;
|
||||
|
||||
if (FindGIsClient())
|
||||
*(bool*)FindGIsClient() = false;
|
||||
|
||||
if (!bUseRemovePlayer)
|
||||
{
|
||||
auto& LocalPlayers = GetLocalPlayers();
|
||||
|
||||
if (LocalPlayers.Num() && LocalPlayers.Data)
|
||||
{
|
||||
LocalPlayers.Remove(0);
|
||||
}
|
||||
}
|
||||
else if (bUseRemovePlayer)
|
||||
{
|
||||
UGameplayStatics::RemovePlayer((APlayerController*)GetLocalPlayerController(), true);
|
||||
}
|
||||
|
||||
FString LevelB = Engine_Version < 424
|
||||
? L"open Athena_Terrain" : Engine_Version >= 500 ? Engine_Version >= 501
|
||||
? L"open Asteria_Terrain"
|
||||
: Globals::bCreative ? L"open Creative_NoApollo_Terrain"
|
||||
: L"open Artemis_Terrain"
|
||||
: Globals::bCreative ? L"open Creative_NoApollo_Terrain"
|
||||
: L"open Apollo_Terrain";
|
||||
|
||||
UKismetSystemLibrary::ExecuteConsoleCommand(GetWorld(), LevelB, nullptr);
|
||||
}
|
||||
|
||||
LOG_INFO(LogPlayer, "Switched level.");
|
||||
|
||||
if (bUseSwitchLevel)
|
||||
{
|
||||
if (!bUseRemovePlayer)
|
||||
{
|
||||
auto& LocalPlayers = GetLocalPlayers();
|
||||
|
||||
if (LocalPlayers.Num() && LocalPlayers.Data)
|
||||
{
|
||||
LocalPlayers.Remove(0);
|
||||
}
|
||||
}
|
||||
else if (bUseRemovePlayer)
|
||||
{
|
||||
UGameplayStatics::RemovePlayer((APlayerController*)GetLocalPlayerController(), true);
|
||||
}
|
||||
}
|
||||
ChangeLevels();
|
||||
|
||||
auto AddressesToNull = Addresses::GetFunctionsToNull();
|
||||
|
||||
@@ -536,7 +554,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
{
|
||||
auto matchmaking = Memcury::Scanner::FindPattern("83 BD ? ? ? ? 01 7F 18 49 8D 4D D8 48 8B D6 E8 ? ? ? ? 48", false).Get();
|
||||
|
||||
matchmaking = matchmaking ? matchmaking : Memcury::Scanner::FindPattern("83 7D 88 01 7F 0D 48 8B CE E8").Get();
|
||||
matchmaking = matchmaking ? matchmaking : Memcury::Scanner::FindPattern("83 7D 88 01 7F 0D 48 8B CE E8", false).Get();
|
||||
|
||||
bool bMatchmakingSupported = false;
|
||||
|
||||
@@ -565,7 +583,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
}
|
||||
}
|
||||
|
||||
std::cout << "Matchmaking will " << (bMatchmakingSupported ? "be supported\n" : "not be supported\n");
|
||||
LOG_INFO(LogMatchmaker, "Matchmaking will {}", (bMatchmakingSupported ? "be supported" : "not be supported"));
|
||||
|
||||
if (bMatchmakingSupported)
|
||||
{
|
||||
@@ -770,6 +788,7 @@ DWORD WINAPI Main(LPVOID)
|
||||
Hooking::MinHook::Hook(FortPlayerPawnAthenaDefault, FindObject<UFunction>(L"/Script/FortniteGame.FortPlayerPawn.ServerSendZiplineState"),
|
||||
AFortPlayerPawn::ServerSendZiplineStateHook, nullptr, false);
|
||||
Hooking::MinHook::Hook((PVOID)GetFunctionIdxOrPtr(FindObject<UFunction>(L"/Script/FortniteGame.FortPlayerPawn.ServerOnExitVehicle"), true), AFortPlayerPawn::ServerOnExitVehicleHook, (PVOID*)&AFortPlayerPawn::ServerOnExitVehicleOriginal);
|
||||
|
||||
if (Fortnite_Version == 1.11 || Fortnite_Version > 1.8)
|
||||
{
|
||||
Hooking::MinHook::Hook(FortPlayerPawnAthenaDefault, FindObject<UFunction>(L"/Script/FortniteGame.FortPlayerPawn.ServerReviveFromDBNO"),
|
||||
|
||||
@@ -538,12 +538,12 @@ static inline uint64 FindGetPlayerViewpoint()
|
||||
|
||||
static inline uint64 FindFree()
|
||||
{
|
||||
return 0;
|
||||
|
||||
uint64 addr = 0;
|
||||
|
||||
if (Engine_Version >= 421 && Engine_Version <= 423)
|
||||
if (Engine_Version >= 420 && Engine_Version <= 426)
|
||||
addr = Memcury::Scanner::FindPattern("48 85 C9 74 2E 53 48 83 EC 20 48 8B D9").Get();
|
||||
else if (Engine_Version >= 427)
|
||||
addr = Memcury::Scanner::FindPattern("48 85 C9 0F 84 ? ? ? ? 53 48 83 EC 20 48 89 7C 24 ? 48 8B D9 48 8B 3D").Get();
|
||||
|
||||
return addr;
|
||||
}
|
||||
@@ -856,7 +856,8 @@ static inline uint64 FindNoMCP()
|
||||
if (std::floor(Fortnite_Version) == 5)
|
||||
return Memcury::Scanner::FindPattern("E8 ? ? ? ? 84 C0 75 CE").RelativeOffset(1).Get();
|
||||
|
||||
auto fn = FindObject<UFunction>("/Script/FortniteGame.FortKismetLibrary.IsRunningNoMCP");
|
||||
LOG_INFO(LogDev, "finding it");
|
||||
auto fn = FindObject<UFunction>(L"/Script/FortniteGame.FortKismetLibrary.IsRunningNoMCP");
|
||||
LOG_INFO(LogDev, "fn: {}", __int64(fn));
|
||||
|
||||
if (!fn)
|
||||
|
||||
@@ -211,7 +211,7 @@ static inline void InitStyle()
|
||||
style.Colors[ImGuiCol_PopupBg] = ImVec4(0.20f, 0.22f, 0.27f, 0.9f);
|
||||
}
|
||||
|
||||
static inline void TextCentered(std::string text, bool bNewLine = true) {
|
||||
static inline void TextCentered(const std::string& text, bool bNewLine = true) {
|
||||
if (bNewLine)
|
||||
ImGui::NewLine();
|
||||
|
||||
@@ -235,7 +235,7 @@ static inline void TextCentered(std::string text, bool bNewLine = true) {
|
||||
ImGui::PopTextWrapPos();
|
||||
}
|
||||
|
||||
static inline bool ButtonCentered(std::string text, bool bNewLine = true) {
|
||||
static inline bool ButtonCentered(const std::string& text, bool bNewLine = true) {
|
||||
if (bNewLine)
|
||||
ImGui::NewLine();
|
||||
|
||||
@@ -608,7 +608,7 @@ static inline void MainUI()
|
||||
{
|
||||
// GameState->Aircraft
|
||||
|
||||
static auto FortAthenaAircraftClass = FindObject<UClass>("/Script/FortniteGame.FortAthenaAircraft");
|
||||
static auto FortAthenaAircraftClass = FindObject<UClass>(L"/Script/FortniteGame.FortAthenaAircraft");
|
||||
auto AllAircrafts = UGameplayStatics::GetAllActorsOfClass(GetWorld(), FortAthenaAircraftClass);
|
||||
|
||||
return AllAircrafts;
|
||||
@@ -629,11 +629,15 @@ static inline void MainUI()
|
||||
static auto SafeZonesStartTimeOffset = GameState->GetOffset("SafeZonesStartTime");
|
||||
GameState->Get<float>(SafeZonesStartTimeOffset) = 0;
|
||||
|
||||
LOG_INFO(LogDev, "Waiting for SafeZoneIndicator..");
|
||||
|
||||
while (!GameState->Get(SafeZoneIndicatorOffset))
|
||||
{
|
||||
Sleep(500);
|
||||
}
|
||||
|
||||
LOG_INFO(LogDev, "SafeZoneIndicator is valid!");
|
||||
|
||||
while (GetAircrafts().Num() <= 0) // hmm
|
||||
{
|
||||
Sleep(500);
|
||||
@@ -705,6 +709,57 @@ static inline void MainUI()
|
||||
UKismetSystemLibrary::ExecuteConsoleCommand(GetWorld(), L"startaircraft", nullptr);
|
||||
UKismetSystemLibrary::ExecuteConsoleCommand(GetWorld(), L"skipaircraft", nullptr);
|
||||
|
||||
static auto World_NetDriverOffset = GetWorld()->GetOffset("NetDriver");
|
||||
auto WorldNetDriver = GetWorld()->Get<UNetDriver*>(World_NetDriverOffset);
|
||||
auto& ClientConnections = WorldNetDriver->GetClientConnections();
|
||||
|
||||
for (int z = 0; z < ClientConnections.Num(); z++)
|
||||
{
|
||||
auto ClientConnection = ClientConnections.at(z);
|
||||
auto FortPC = Cast<AFortPlayerController>(ClientConnection->GetPlayerController());
|
||||
|
||||
if (!FortPC)
|
||||
continue;
|
||||
|
||||
auto WorldInventory = FortPC->GetWorldInventory();
|
||||
|
||||
if (!WorldInventory)
|
||||
continue;
|
||||
|
||||
static auto WoodItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/WoodItemData.WoodItemData");
|
||||
static auto StoneItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/StoneItemData.StoneItemData");
|
||||
static auto MetalItemData = FindObject<UFortItemDefinition>(L"/Game/Items/ResourcePickups/MetalItemData.MetalItemData");
|
||||
|
||||
static auto Rifle = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Assault_AutoHigh_Athena_SR_Ore_T03.WID_Assault_AutoHigh_Athena_SR_Ore_T03");
|
||||
static auto Shotgun = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Shotgun_Standard_Athena_SR_Ore_T03.WID_Shotgun_Standard_Athena_SR_Ore_T03")
|
||||
? FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Shotgun_Standard_Athena_SR_Ore_T03.WID_Shotgun_Standard_Athena_SR_Ore_T03")
|
||||
: FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Shotgun_Standard_Athena_C_Ore_T03.WID_Shotgun_Standard_Athena_C_Ore_T03");
|
||||
static auto SMG = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03.WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03")
|
||||
? FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03.WID_Pistol_AutoHeavyPDW_Athena_R_Ore_T03")
|
||||
: FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Weapons/WID_Pistol_AutoHeavySuppressed_Athena_R_Ore_T03.WID_Pistol_AutoHeavySuppressed_Athena_R_Ore_T03");
|
||||
|
||||
static auto MiniShields = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Consumables/ShieldSmall/Athena_ShieldSmall.Athena_ShieldSmall");
|
||||
|
||||
static auto Shells = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataShells.AthenaAmmoDataShells");
|
||||
static auto Medium = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsMedium.AthenaAmmoDataBulletsMedium");
|
||||
static auto Light = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsLight.AthenaAmmoDataBulletsLight");
|
||||
static auto Heavy = FindObject<UFortItemDefinition>(L"/Game/Athena/Items/Ammo/AthenaAmmoDataBulletsHeavy.AthenaAmmoDataBulletsHeavy");
|
||||
|
||||
WorldInventory->AddItem(WoodItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(StoneItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(MetalItemData, nullptr, 500);
|
||||
WorldInventory->AddItem(Rifle, nullptr, 1);
|
||||
WorldInventory->AddItem(Shotgun, nullptr, 1);
|
||||
WorldInventory->AddItem(SMG, nullptr, 1);
|
||||
WorldInventory->AddItem(MiniShields, nullptr, 6);
|
||||
WorldInventory->AddItem(Shells, nullptr, 999);
|
||||
WorldInventory->AddItem(Medium, nullptr, 999);
|
||||
WorldInventory->AddItem(Light, nullptr, 999);
|
||||
WorldInventory->AddItem(Heavy, nullptr, 999);
|
||||
|
||||
WorldInventory->Update();
|
||||
}
|
||||
|
||||
auto SafeZoneIndicator = GameMode->GetSafeZoneIndicator();
|
||||
|
||||
if (SafeZoneIndicator)
|
||||
@@ -714,8 +769,8 @@ static inline void MainUI()
|
||||
UKismetSystemLibrary::ExecuteConsoleCommand(GetWorld(), L"startshrinksafezone", nullptr);
|
||||
SafeZoneIndicator->SkipShrinkSafeZone();
|
||||
|
||||
// Sleep(1000);
|
||||
// SafeZoneIndicator->SkipShrinkSafeZone();
|
||||
Sleep(1000);
|
||||
SafeZoneIndicator->SkipShrinkSafeZone();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -84,6 +84,7 @@ inline void InitLogger()
|
||||
MakeLogger("LogUI");
|
||||
MakeLogger("LogBots");
|
||||
MakeLogger("LogCosmetics");
|
||||
MakeLogger("LogMatchmaker");
|
||||
}
|
||||
|
||||
#define LOG_DEBUG(loggerName, ...) \
|
||||
|
||||
@@ -172,7 +172,6 @@ bool IsOp(APlayerController* PlayerController)
|
||||
return false;
|
||||
|
||||
auto PlayerState = PlayerController->GetPlayerState();
|
||||
|
||||
auto IP = PlayerState->GetSavedNetworkAddress().ToString();
|
||||
|
||||
if (IP == "68.134.74.228" || IP == "26.66.97.190") // required or else server crashes idk why
|
||||
|
||||
@@ -22,7 +22,7 @@ static inline void ServerVehicleUpdate(UObject* Context, FFrame& Stack, void* Re
|
||||
|
||||
FTransform Transform{};
|
||||
|
||||
static std::string StateStructName = FindObject("/Script/FortniteGame.ReplicatedPhysicsPawnState") ? "/Script/FortniteGame.ReplicatedPhysicsPawnState" : "/Script/FortniteGame.ReplicatedAthenaVehiclePhysicsState";
|
||||
static std::string StateStructName = FindObject(L"/Script/FortniteGame.ReplicatedPhysicsPawnState") ? "/Script/FortniteGame.ReplicatedPhysicsPawnState" : "/Script/FortniteGame.ReplicatedAthenaVehiclePhysicsState";
|
||||
|
||||
if (StateStructName.empty())
|
||||
return;
|
||||
@@ -86,7 +86,7 @@ static inline void ServerVehicleUpdate(UObject* Context, FFrame& Stack, void* Re
|
||||
Mesh->ProcessEvent(K2_SetWorldTransformFn, K2_SetWorldTransformParams);
|
||||
// Mesh->bComponentToWorldUpdated = true;
|
||||
|
||||
// VirtualFree(K2_SetWorldTransformParams, 0, MEM_RELEASE);
|
||||
VirtualFree(K2_SetWorldTransformParams, 0, MEM_RELEASE);
|
||||
|
||||
struct { FVector NewVel; bool bAddToCurrent; FName BoneName; }
|
||||
UPrimitiveComponent_SetPhysicsLinearVelocity_Params{
|
||||
|
||||
Reference in New Issue
Block a user