From 8c69f58a974ac5a8fc713bf1e54f00c1327c0fbf Mon Sep 17 00:00:00 2001 From: MH261677 Date: Mon, 28 Nov 2022 23:15:41 +0000 Subject: [PATCH] Updated BP_OPENDIAL, Interaction.cpp Changed the text in the widget and gave it a little animation. Made the Wait timer in interaction changeable in the editor. --- Content/Blueprints/Merchant/Merchant_UI/BP_OPENDIAL.uasset | 4 ++-- Source/the_twilight_abyss/MerchantInteraction/Interaction.cpp | 2 +- Source/the_twilight_abyss/MerchantInteraction/Interaction.h | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Content/Blueprints/Merchant/Merchant_UI/BP_OPENDIAL.uasset b/Content/Blueprints/Merchant/Merchant_UI/BP_OPENDIAL.uasset index cf030cd..b1a1752 100644 --- a/Content/Blueprints/Merchant/Merchant_UI/BP_OPENDIAL.uasset +++ b/Content/Blueprints/Merchant/Merchant_UI/BP_OPENDIAL.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ab4de6dc668c0b8ca8ae692028ad12b8b9f48a63c0bcbd285d0896b77445307 -size 35241 +oid sha256:b00c78b227e5926f654f4ae7c1421f83cc57c4a186be20147347e9b694ffe960 +size 71363 diff --git a/Source/the_twilight_abyss/MerchantInteraction/Interaction.cpp b/Source/the_twilight_abyss/MerchantInteraction/Interaction.cpp index 3f19df3..f295c82 100644 --- a/Source/the_twilight_abyss/MerchantInteraction/Interaction.cpp +++ b/Source/the_twilight_abyss/MerchantInteraction/Interaction.cpp @@ -33,7 +33,7 @@ void AInteraction::OnInteract() CurrentWidget = CreateWidget(GetWorld(), Widget); CurrentWidget->AddToViewport(0); FTimerHandle WidgetTimer; - GetWorldTimerManager().SetTimer(WidgetTimer, this, &AInteraction::RemoveWidget, 5.0f, false); + GetWorldTimerManager().SetTimer(WidgetTimer, this, &AInteraction::RemoveWidget, WaitTimer, false); } void AInteraction::RemoveWidget() diff --git a/Source/the_twilight_abyss/MerchantInteraction/Interaction.h b/Source/the_twilight_abyss/MerchantInteraction/Interaction.h index 3450771..838b8b8 100644 --- a/Source/the_twilight_abyss/MerchantInteraction/Interaction.h +++ b/Source/the_twilight_abyss/MerchantInteraction/Interaction.h @@ -30,5 +30,7 @@ public: virtual void RemoveWidget(); UPROPERTY() UUserWidget* CurrentWidget; + UPROPERTY(EditAnywhere) + float WaitTimer; };