Compare commits

..

1 Commits

Author SHA1 Message Date
e6d878aeef Fixed bIsMassStart assign On NextFocus 2025-07-13 18:07:14 +02:00
2 changed files with 5 additions and 7 deletions

View File

@ -38,7 +38,7 @@ void UDTFluxPursuitManager::InitPursuit(const TArray<int> InContestIds, const in
} }
} }
void UDTFluxPursuitManager::SetPursuitInfoIsMassStart(FDTFluxPursuitGroup NextFocusGroup) void UDTFluxPursuitManager::SetPursuitInfoIsMassStart(FDTFluxPursuitGroup& NextFocusGroup)
{ {
for (auto& Pursuit : NextFocusGroup.PursuitGroup) for (auto& Pursuit : NextFocusGroup.PursuitGroup)
{ {
@ -139,8 +139,7 @@ void UDTFluxPursuitManager::GetPursuit(TArray<FDTFluxPursuitInfo>& OutPursuitFoc
*FocusGroup.StartTimeGlobal.ToString(), *FocusGroup.StartTimeGlobal.ToString(),
FocusGroup.PursuitGroup.Num()); FocusGroup.PursuitGroup.Num());
// === ÉTAPE 2: NEXT = GROUPES SUIVANTS (SANS les supprimer) === int32 TargetNextCount = MaxSimultaneousPursuit - 1;
int32 TargetNextCount = MaxSimultaneousPursuit - 1; // -1 pour le focus
int32 AddedNextCount = 0; int32 AddedNextCount = 0;
UE_LOG(logDTFluxCoreSubsystem, Warning, TEXT("Target Next Count: %d"), TargetNextCount); UE_LOG(logDTFluxCoreSubsystem, Warning, TEXT("Target Next Count: %d"), TargetNextCount);
@ -149,11 +148,11 @@ void UDTFluxPursuitManager::GetPursuit(TArray<FDTFluxPursuitInfo>& OutPursuitFoc
GroupIndex < GroupedPursuit.Num() && AddedNextCount < TargetNextCount; GroupIndex < GroupedPursuit.Num() && AddedNextCount < TargetNextCount;
GroupIndex++) GroupIndex++)
{ {
FDTFluxPursuitGroup& NextGroup = GroupedPursuit[GroupIndex]; // Référence (pour SetPursuitInfoIsMassStart) FDTFluxPursuitGroup& NextGroup = GroupedPursuit[GroupIndex];
if (NextGroup.PursuitGroup.Num() == 0) if (NextGroup.PursuitGroup.Num() == 0)
{ {
continue; // Groupe vide continue;
} }
int32 AvailableInGroup = NextGroup.PursuitGroup.Num(); int32 AvailableInGroup = NextGroup.PursuitGroup.Num();
@ -170,7 +169,6 @@ void UDTFluxPursuitManager::GetPursuit(TArray<FDTFluxPursuitInfo>& OutPursuitFoc
{ {
FDTFluxPursuitInfo NextParticipant = NextGroup.PursuitGroup[ParticipantIndex]; // Copie FDTFluxPursuitInfo NextParticipant = NextGroup.PursuitGroup[ParticipantIndex]; // Copie
// Appliquer MassStart
NextParticipant.bIsMassStart = NextParticipant.StartTime >= MassStartTime; NextParticipant.bIsMassStart = NextParticipant.StartTime >= MassStartTime;
OutPursuitNext.Add(NextParticipant); OutPursuitNext.Add(NextParticipant);

View File

@ -123,7 +123,7 @@ private:
UPROPERTY() UPROPERTY()
bool bIsRankingBounded = false; bool bIsRankingBounded = false;
UFUNCTION() UFUNCTION()
void SetPursuitInfoIsMassStart(FDTFluxPursuitGroup NextFocusGroup); void SetPursuitInfoIsMassStart(FDTFluxPursuitGroup& NextFocusGroup);
UFUNCTION() UFUNCTION()
bool LaunchPursuitSequence(); bool LaunchPursuitSequence();
}; };