mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 02:42:22 +01:00
a lot
fix 1.11 replication, fix some ltm specific stuff, start on shadow stones, fix some events not having foundations, fix s4-s6 gadgets, fix clear inventory on some versions
This commit is contained in:
@@ -4,6 +4,26 @@
|
||||
#include "FortPlayerState.h"
|
||||
#include "FortPlaylist.h"
|
||||
#include "BuildingStructuralSupportSystem.h"
|
||||
#include "ScriptInterface.h"
|
||||
#include "Interface.h"
|
||||
|
||||
enum class EAthenaGamePhaseStep : uint8_t // idk if this changes
|
||||
{
|
||||
None = 0,
|
||||
Setup = 1,
|
||||
Warmup = 2,
|
||||
GetReady = 3,
|
||||
BusLocked = 4,
|
||||
BusFlying = 5,
|
||||
StormForming = 6,
|
||||
StormHolding = 7,
|
||||
StormShrinking = 8,
|
||||
Countdown = 9,
|
||||
FinalCountdown = 10,
|
||||
EndGame = 11,
|
||||
Count = 12,
|
||||
EAthenaGamePhaseStep_MAX = 13
|
||||
};
|
||||
|
||||
enum class EAthenaGamePhase : uint8_t
|
||||
{
|
||||
@@ -17,6 +37,16 @@ enum class EAthenaGamePhase : uint8_t
|
||||
EAthenaGamePhase_MAX = 7
|
||||
};
|
||||
|
||||
class UFortSafeZoneInterface : public UInterface
|
||||
{
|
||||
public:
|
||||
static UClass* StaticClass()
|
||||
{
|
||||
static auto Struct = FindObject<UClass>("/Script/FortniteGame.FortSafeZoneInterface");
|
||||
return Struct;
|
||||
}
|
||||
};
|
||||
|
||||
struct FPlayerBuildableClassContainer
|
||||
{
|
||||
TArray<UClass*> BuildingClasses; // 0x0000(0x0010) (ZeroConstructor, Transient, UObjectWrapper, NativeAccessSpecifierPublic)
|
||||
@@ -50,6 +80,7 @@ public:
|
||||
}
|
||||
|
||||
UFortPlaylist*& GetCurrentPlaylist();
|
||||
TScriptInterface<UFortSafeZoneInterface> GetSafeZoneInterface();
|
||||
|
||||
// void AddPlayerStateToGameMemberInfo(class AFortPlayerStateAthena* PlayerState);
|
||||
|
||||
@@ -58,4 +89,36 @@ public:
|
||||
bool IsPlayerBuildableClass(UClass* Class);
|
||||
void OnRep_GamePhase();
|
||||
void OnRep_CurrentPlaylistInfo();
|
||||
};
|
||||
};
|
||||
|
||||
static void* ConstructOnGamePhaseStepChangedParams(EAthenaGamePhaseStep GamePhaseStep)
|
||||
{
|
||||
struct AFortAthenaAIBotController_OnGamePhaseStepChanged_Params
|
||||
{
|
||||
TScriptInterface<UFortSafeZoneInterface> SafeZoneInterface; // (ConstParm, Parm, OutParm, ZeroConstructor, ReferenceParm, IsPlainOldData, NoDestructor, UObjectWrapper, NativeAccessSpecifierPublic)
|
||||
EAthenaGamePhaseStep GamePhaseStep; // (ConstParm, Parm, ZeroConstructor, IsPlainOldData, NoDestructor, HasGetValueTypeHash, NativeAccessSpecifierPublic)
|
||||
};
|
||||
|
||||
bool bHasSafeZoneInterfaceParam = Fortnite_Version >= 10; // idk what version
|
||||
|
||||
AFortAthenaAIBotController_OnGamePhaseStepChanged_Params* Params = Alloc<AFortAthenaAIBotController_OnGamePhaseStepChanged_Params>();
|
||||
|
||||
if (bHasSafeZoneInterfaceParam)
|
||||
{
|
||||
auto GameState = (AFortGameStateAthena*)GetWorld()->GetGameState();
|
||||
|
||||
auto Interface = GameState->GetSafeZoneInterface();
|
||||
|
||||
if (!Interface.ObjectPointer)
|
||||
return nullptr;
|
||||
|
||||
Params->SafeZoneInterface = Interface;
|
||||
Params->GamePhaseStep = GamePhaseStep;
|
||||
}
|
||||
else
|
||||
{
|
||||
*(EAthenaGamePhaseStep*)(__int64(Params) + 0) = GamePhaseStep;
|
||||
}
|
||||
|
||||
return Params;
|
||||
}
|
||||
Reference in New Issue
Block a user