Updated Checkpoint Tips to Perma Stay on the Screen with a New Animation
This commit is contained in:
parent
39ed880d6b
commit
9cf6884335
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset
(Stored with Git LFS)
Binary file not shown.
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/WBP_CheckpointCompleted.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/WBP_CheckpointCompleted.uasset
(Stored with Git LFS)
Binary file not shown.
BIN
EndlessVendetta/Content/Levels/TrainingFacility.umap
(Stored with Git LFS)
BIN
EndlessVendetta/Content/Levels/TrainingFacility.umap
(Stored with Git LFS)
Binary file not shown.
@ -70,7 +70,6 @@ void ABountyClass::IncrementBountyCheckpoint()
|
||||
BountyCheckpoints[0]->Destroy();
|
||||
BountyCheckpoints.RemoveAt(0);
|
||||
UE_LOG(LogTemp, Warning, TEXT(" You've Completed the Bounty!! Well done"));
|
||||
Cast<AEndlessVendettaCharacter>(GetWorld()->GetFirstPlayerController()->GetPawn())->CheckpointCompletedUI(FString(""));
|
||||
return;
|
||||
}
|
||||
|
||||
@ -90,9 +89,6 @@ void ABountyClass::IncrementBountyCheckpoint()
|
||||
BountyCheckpoints[0]->SpawnWaypoint(BountyTitle);
|
||||
BountyCheckpoints[0]->CheckpointActivated();
|
||||
BountyCheckpoints[0]->CompletedCheckpoint.AddDynamic(this, &ABountyClass::IncrementBountyCheckpoint);
|
||||
|
||||
Cast<AEndlessVendettaCharacter>(GetWorld()->GetFirstPlayerController()->GetPawn())->CheckpointCompletedUI(BountyCheckpoints[0]->GetCheckpointTip());
|
||||
|
||||
}
|
||||
|
||||
void ABountyClass::CollectRewards_Implementation()
|
||||
|
@ -100,16 +100,7 @@ public:
|
||||
|
||||
return BountyCheckpoints[0]->GetWaypointIcon();
|
||||
}
|
||||
|
||||
FString GetCheckpointDescription()
|
||||
{
|
||||
if (BountyCheckpoints.IsEmpty() || BountyCheckpoints[0] == nullptr)
|
||||
{
|
||||
return FString("No more Bounty checkpoints, check BountyClass.h GetCheckpointDescription()");
|
||||
}
|
||||
|
||||
return BountyCheckpoints[0]->GetCheckpointDesc();
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------
|
||||
|
||||
// Sets default values for this actor's properties
|
||||
|
@ -20,8 +20,6 @@ class ENDLESSVENDETTA_API ACheckpointClass : public AActor
|
||||
|
||||
// ------ Properties set from Editor ------
|
||||
UPROPERTY(EditDefaultsOnly, Category = "Checkpoint")
|
||||
FString CheckpointDescription;
|
||||
UPROPERTY(EditDefaultsOnly, Category = "Checkpoint")
|
||||
FString CheckpointTip;
|
||||
UPROPERTY(EditDefaultsOnly, Category = "Checkpoint")
|
||||
FVector WaypointLoc;
|
||||
@ -61,10 +59,6 @@ public:
|
||||
void CheckpointActivated();
|
||||
|
||||
// ------ Getters for CP Properties ------
|
||||
FString GetCheckpointDesc()
|
||||
{
|
||||
return CheckpointDescription;
|
||||
}
|
||||
|
||||
FString GetCheckpointTip()
|
||||
{
|
||||
|
@ -3,6 +3,15 @@
|
||||
|
||||
#include "MainBountyClass.h"
|
||||
|
||||
void AMainBountyClass::IncrementBountyCheckpoint()
|
||||
{
|
||||
Super::IncrementBountyCheckpoint();
|
||||
FString TipToDisplay = "";
|
||||
if (!Completed) TipToDisplay = BountyCheckpoints[0]->GetCheckpointTip();
|
||||
Cast<AEndlessVendettaCharacter>(GetWorld()->GetFirstPlayerController()->GetPawn())->CheckpointCompletedUI(TipToDisplay, Completed);
|
||||
}
|
||||
|
||||
|
||||
void AMainBountyClass::SpawnAmmoDrops()
|
||||
{
|
||||
UE_LOG(LogTemp, Display, TEXT("Bought Ammo Drops, but its not implemented yet"));
|
||||
|
@ -15,6 +15,8 @@ class ENDLESSVENDETTA_API AMainBountyClass : public ABountyClass
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
void IncrementBountyCheckpoint() override;
|
||||
|
||||
protected:
|
||||
UPROPERTY(EditDefaultsOnly, Category = "Bounty")
|
||||
TArray<TSubclassOf<ASideBountyClass>> SideBountiesToSpawn;
|
||||
|
@ -228,7 +228,7 @@ public:
|
||||
void WeaponSwitcher(AActor* Outhit);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void CheckpointCompletedUI(const FString& CheckpointDesc);
|
||||
void CheckpointCompletedUI(const FString& CheckpointDesc, bool CompletedBounty = false);
|
||||
|
||||
// Returns true if successfully changed to a new gadget, can fail if the target gadget to replace is being used
|
||||
bool UpdateGadgetType(TSubclassOf<AGadgetBase> NewGadgetClass);
|
||||
|
Loading…
Reference in New Issue
Block a user