Reworked and Reimplemented Checkpoint Tips
This commit is contained in:
parent
9a2a365528
commit
d46bc7e45f
@ -9,12 +9,16 @@
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="dfa3053d-1d51-4dad-9270-4c17e086f627" name="Changes" comment="">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Content/StarterContent/HDRI/HDRI_Epic_Courtyard_Daylight.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/StarterContent/HDRI/HDRI_Epic_Courtyard_Daylight.uasset" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/MainBountyClass.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/MainBountyClass.cpp" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Content/Levels/MainMenuLevel.umap" beforeDir="false" afterPath="$PROJECT_DIR$/Content/Levels/MainMenuLevel.umap" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Content/StarterContent/Architecture/Floor_400x400.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/StarterContent/Architecture/Floor_400x400.uasset" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/BountyClass.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/BountyClass.cpp" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/BountyClass.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/BountyClass.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/CheckpointClass.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/CheckpointClass.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/MainBountyClass.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/BountySystem/MainBountyClass.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/Characters/BountyHunterCharacter.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/Characters/BountyHunterCharacter.cpp" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/Characters/BountyHunterCharacter.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/Characters/BountyHunterCharacter.h" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/MainSaveGameClass.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/MainSaveGameClass.h" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
@ -146,7 +150,8 @@
|
||||
<workItem from="1708180486567" duration="2641000" />
|
||||
<workItem from="1708269543495" duration="2914000" />
|
||||
<workItem from="1708434176965" duration="6053000" />
|
||||
<workItem from="1708607826264" duration="9842000" />
|
||||
<workItem from="1708607826264" duration="10102000" />
|
||||
<workItem from="1708654928143" duration="5419000" />
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
|
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay.png
(Stored with Git LFS)
Normal file
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay.uasset
(Stored with Git LFS)
Normal file
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay.uasset
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay2.png
(Stored with Git LFS)
Normal file
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay2.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay2.uasset
(Stored with Git LFS)
Normal file
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/TipDisplay2.uasset
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/WBP_CheckpointTip.uasset
(Stored with Git LFS)
Normal file
BIN
EndlessVendetta/Content/BountySystem/CheckpointTips/WBP_CheckpointTip.uasset
(Stored with Git LFS)
Normal file
Binary file not shown.
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.
@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:fa952eb25972ab6e6dca1d46cf254f62d1684ba665ee45a7c3d6a8e3527ffac1
|
||||
oid sha256:ce714c1367e0d2d8ef9fce14d5f34b7544d6b549f014dc1059dd51a3375ee080
|
||||
size 308710
|
||||
|
BIN
EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset
(Stored with Git LFS)
Binary file not shown.
BIN
EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset
(Stored with Git LFS)
Binary file not shown.
@ -17,6 +17,7 @@ void ABountyClass::ActivateFirstCheckpoint()
|
||||
|
||||
BountyCheckpoints[0]->Active = true;
|
||||
BountyCheckpoints[0]->CompletedCheckpoint.AddDynamic(this, &ABountyClass::IncrementBountyCheckpoint);
|
||||
CheckpointActivated.Broadcast(BountyCheckpoints[0]->GetCheckpointTip());
|
||||
}
|
||||
|
||||
void ABountyClass::DeActivateFirstCheckpoint()
|
||||
|
@ -9,6 +9,7 @@
|
||||
|
||||
DECLARE_DYNAMIC_MULTICAST_DELEGATE(FCompletedFirstCheckpoint);
|
||||
DECLARE_DYNAMIC_MULTICAST_DELEGATE(FCompletedACheckpoint);
|
||||
DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FCheckpointActivated, const FString&, CheckpointTip);
|
||||
|
||||
UCLASS()
|
||||
class ENDLESSVENDETTA_API ABountyClass : public AActor
|
||||
@ -32,6 +33,8 @@ protected:
|
||||
public:
|
||||
FCompletedACheckpoint CompletedACheckpoint;
|
||||
|
||||
FCheckpointActivated CheckpointActivated;
|
||||
|
||||
// Gets the Reward Money for Completing this Bounty, used by Players Character
|
||||
int GetRewardMoney()
|
||||
{
|
||||
|
@ -76,7 +76,11 @@ public:
|
||||
if (WaypointActor) WaypointActor->Destroy();
|
||||
}
|
||||
|
||||
|
||||
// Used by Bounty Class to broadcast checkpoint tip for current checkpoint
|
||||
FString GetCheckpointTip()
|
||||
{
|
||||
return CheckpointTip;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -90,10 +94,7 @@ public:
|
||||
|
||||
// ------ Getters for CP Properties ------
|
||||
|
||||
FString GetCheckpointTip()
|
||||
{
|
||||
return CheckpointTip;
|
||||
}
|
||||
|
||||
|
||||
FVector GetWaypointLoc()
|
||||
{
|
||||
|
@ -94,6 +94,12 @@ public:
|
||||
// Overrides to Desapwn Waypoint from OpenWorld Checkpoint
|
||||
void DeActivateFirstCheckpoint() override;
|
||||
|
||||
// Returns open world checkpoints tip
|
||||
FString GetOpenWorldCheckpointTip()
|
||||
{
|
||||
return OpenWorldcheckpoint->GetCheckpointTip();
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ------------------- LEGACY CODE TO BE REWORKED ---------------------------------
|
||||
|
@ -20,13 +20,15 @@ void ABountyHunterCharacter::SpawnMainBounty(UEVGameInstance* GI)
|
||||
CurrentMainBounty = GetWorld()->SpawnActor<AMainBountyClass>(MainBountyClasses[CurrentMainBountyIndex]);
|
||||
const FAttachmentTransformRules AttachmentTransformRules(EAttachmentRule::SnapToTarget, true);
|
||||
CurrentMainBounty->AttachToComponent(GetRootComponent(), AttachmentTransformRules);
|
||||
CurrentMainBounty->CheckpointActivated.AddDynamic(this, &ABountyHunterCharacter::DisplayCheckpointTip);
|
||||
MainBountyStruct = CurrentMainBounty->MainBountyStruct;
|
||||
if (UGameplayStatics::GetCurrentLevelName(GetWorld()) != OpenWorldLevelName)
|
||||
{
|
||||
CurrentMainBounty->SpawnCheckpoints();
|
||||
return;
|
||||
}
|
||||
CurrentMainBounty->SpawnOpenWorldCheckpoint();
|
||||
CurrentMainBounty->SpawnOpenWorldCheckpoint();
|
||||
TrackMainBounty();
|
||||
}
|
||||
|
||||
void ABountyHunterCharacter::SpawnSideBounties(UEVGameInstance* GI)
|
||||
@ -39,6 +41,7 @@ void ABountyHunterCharacter::SpawnSideBounties(UEVGameInstance* GI)
|
||||
SpawnedSideBounty->AttachToComponent(GetRootComponent(), AttachmentTransformRules);
|
||||
SpawnedSideBounty->SpawnCheckpoints();
|
||||
CurrentSideBounties.Add(SpawnedSideBounty);
|
||||
SpawnedSideBounty->CheckpointActivated.AddDynamic(this, &ABountyHunterCharacter::DisplayCheckpointTip);
|
||||
}
|
||||
|
||||
SideBountyStructs.Empty();
|
||||
@ -47,6 +50,8 @@ void ABountyHunterCharacter::SpawnSideBounties(UEVGameInstance* GI)
|
||||
SideBountyStructs.Add(SideBounty->SideBountyStruct);
|
||||
SideBounty->CompletedSideBounty.AddDynamic(this, &ABountyHunterCharacter::CompletedASideBounty);
|
||||
}
|
||||
|
||||
if (!IsValid(CurrentMainBounty)) DisplayCheckpointTip("SELECT A NEW BOUNTY IN PAUSE MENU");
|
||||
}
|
||||
|
||||
void ABountyHunterCharacter::CompleteCurrentMainBounty(UEVGameInstance* GI)
|
||||
@ -81,6 +86,7 @@ void ABountyHunterCharacter::CompletedASideBounty(int CompletedSideBountiesUID)
|
||||
TitleOfSideBountyToRemove = SideBountyStructs[i].BountyTitle;
|
||||
SideBountyStructs.RemoveAt(i);
|
||||
UpdateBountyTabInfo();
|
||||
DisplayCheckpointTip("SELECT A NEW BOUNTY IN PAUSE MENU");
|
||||
break;
|
||||
}
|
||||
|
||||
@ -107,6 +113,7 @@ void ABountyHunterCharacter::SavePlayerMoneyAndFavours()
|
||||
|
||||
void ABountyHunterCharacter::BeginPlay()
|
||||
{
|
||||
Super::BeginPlay();
|
||||
UEVGameInstance* GI = Cast<UEVGameInstance>(GetGameInstance());
|
||||
if (IsValid(GI->MainSaveGameInstanceRef))
|
||||
{
|
||||
@ -122,7 +129,6 @@ void ABountyHunterCharacter::BeginPlay()
|
||||
}
|
||||
}
|
||||
CreatePauseMenuTabs();
|
||||
Super::BeginPlay();
|
||||
}
|
||||
|
||||
void ABountyHunterCharacter::SetupPlayerInputComponent(UInputComponent* PlayerInputComponent)
|
||||
|
@ -84,6 +84,9 @@ protected:
|
||||
// Called When Player Spawns
|
||||
virtual void BeginPlay() override;
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void DisplayCheckpointTip(const FString& NewCheckpointTip);
|
||||
|
||||
// Overridden to Setup up Pause Menu Inputs
|
||||
virtual void SetupPlayerInputComponent(UInputComponent* PlayerInputComponent) override;
|
||||
|
||||
@ -271,6 +274,7 @@ private:
|
||||
{
|
||||
DeActivateAllBounties();
|
||||
CurrentMainBounty->ActivateFirstCheckpoint();
|
||||
DisplayCheckpointTip(CurrentMainBounty->GetOpenWorldCheckpointTip());
|
||||
}
|
||||
|
||||
UFUNCTION()
|
||||
|
Loading…
x
Reference in New Issue
Block a user