5#include "Blueprint/WidgetTree.h"
6#include "Components/TextBlock.h"
7#include "GameFramework/GameModeBase.h"
9#include "Kismet/GameplayStatics.h"
12void UButtonWidget::PostEditChangeChainProperty(FPropertyChangedChainEvent& PropertyChangedEvent)
14 Super::PostEditChangeChainProperty(PropertyChangedEvent);
22 Super::NativeOnInitialized();
34 if (GameModeBase->GetClass()->ImplementsInterface(UPixoCoreInterface::StaticClass()))
37 IPixoCoreInterface::Execute_GetManagerRef(GameModeBase, UHintManager::StaticClass()));
44 IPixoCoreInterface::Execute_GetManagerRef(GameModeBase, UStoryManager::StaticClass()));
56 UE_LOG(LogTemp, Error, TEXT(
"GameModeBase doesn't implement IPixoCoreInterface"));
69 Super::NativePreConstruct();
107 FSlateFontInfo FontInfo =
BtnName->Font;
139void UButtonWidget::OnHintActivated_Implementation(
bool Activate)
179 UWorld* ThisWorld = GetWorld();
180 if (
SelectSound && ThisWorld && ThisWorld->bAllowAudioPlayback && !ThisWorld->IsNetMode(NM_DedicatedServer))
182 UGameplayStatics::PlaySound2D(ThisWorld,
SelectSound);
190 UWorld* ThisWorld = GetWorld();
191 if (
HoverSound && ThisWorld && ThisWorld->bAllowAudioPlayback && !ThisWorld->IsNetMode(NM_DedicatedServer))
193 UGameplayStatics::PlaySound2D(ThisWorld,
HoverSound);
217 bool StepFound =
false;
218 bool SubStepFound =
false;
262 bool StepFound =
false;
263 bool SubStepFound =
false;
FOnHintActivated OnHintActivated
Event delegate for hint activation.
FOnNewStep OnNewStep
UPROPERTY(BlueprintAssignable, Category = "Story Delegate")
FStoryStep CurrentSubStep
UPROPERTY(BlueprintReadWrite, Replicated)
FOnStoryLoaded OnStoryLoaded
UPROPERTY(BlueprintAssignable, Category = "Story Delegate")
FOnNewSubStep OnNewSubStep
UPROPERTY(BlueprintAssignable, Category = "Story Delegate")
FStoryStep CurrentStep
UPROPERTY(BlueprintReadWrite, Replicated)
FText StepName
UPROPERTY(BlueprintReadWrite, EditAnywhere)