diff --git a/EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset b/EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset index 3f7b61b7..1c2b2dfc 100644 --- a/EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset +++ b/EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:28d4447ff98f89b089289d67bcc3b9cf911d9ebe56b4b8e80561340073c7ad19 -size 806638 +oid sha256:8e3683ec5d7106ad74a95eca5910654b88dd2afd80e4024f9aaa46af55499a18 +size 804499 diff --git a/EndlessVendetta/Content/FirstPerson/Blueprints/BP_MainCharacter.uasset b/EndlessVendetta/Content/FirstPerson/Blueprints/BP_MainCharacter.uasset index c2cc378e..28c63b98 100644 --- a/EndlessVendetta/Content/FirstPerson/Blueprints/BP_MainCharacter.uasset +++ b/EndlessVendetta/Content/FirstPerson/Blueprints/BP_MainCharacter.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b1938c560f8b136dda042d50930f00dff52f5c205974ef5ca4153d0658cfe05 -size 1469253 +oid sha256:4c61bf8f8a9a3378e025556487f0bd86d25be1eef1d450f5da8e7f4d76795358 +size 1525435 diff --git a/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.png b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.png new file mode 100644 index 00000000..6d7135f5 --- /dev/null +++ b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50d6fd70920b407054096171e19e74a8decf98ef51ed66a8a59a92193d0720cb +size 180840 diff --git a/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.uasset b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.uasset new file mode 100644 index 00000000..fb783b37 --- /dev/null +++ b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenBG.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f5fef3833c6d4e041f2f8dc6b0164917705b477bfff8b7646371a5be88a16864 +size 145432 diff --git a/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.png b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.png new file mode 100644 index 00000000..d2c1e225 --- /dev/null +++ b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8a4f7a31570ebf618c22941d8b5a2f1f58b4b32e3ad0ca16f27a3d7453423745 +size 239498 diff --git a/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.uasset b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.uasset new file mode 100644 index 00000000..ca75c05e --- /dev/null +++ b/EndlessVendetta/Content/FirstPerson/DeathScreen/DeathScreenText.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:70e5b87a79518bc292f16e43d921d79ab0365333ec9620f0a9a048056dc1882b +size 217886 diff --git a/EndlessVendetta/Content/FirstPerson/DeathScreen/WBP_DeathScreen.uasset b/EndlessVendetta/Content/FirstPerson/DeathScreen/WBP_DeathScreen.uasset new file mode 100644 index 00000000..5f5d1334 --- /dev/null +++ b/EndlessVendetta/Content/FirstPerson/DeathScreen/WBP_DeathScreen.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d51dad89e04472b811ae1150be3e20dc5bd0f8271a0bf74a6f1f844295e8b16f +size 66821 diff --git a/EndlessVendetta/Content/Levels/Apartment_hit.umap b/EndlessVendetta/Content/Levels/Apartment_hit.umap index cd11afe8..000d7bde 100644 --- a/EndlessVendetta/Content/Levels/Apartment_hit.umap +++ b/EndlessVendetta/Content/Levels/Apartment_hit.umap @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d8174773472453e8d92eaa8d5984fadd4542bd8e181402aa55ac8d95fbefd032 +oid sha256:0cae384479ed9a01ca6f37421b573971efa8e75ec721a9ce461c34d202b15a9d size 868721 diff --git a/EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset b/EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset index c2a34afc..b051bb96 100644 --- a/EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset +++ b/EndlessVendetta/Content/StarterContent/Architecture/Floor_400x400.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4c0ecf0ac0702cc2bd355ec050232a61c49e10f102448efbeb735a51824adef6 -size 14948 +oid sha256:243803779b8be210fa7fc066476ef4389f57bf466874604427427d61da11a627 +size 14831 diff --git a/EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset b/EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset index c980d17b..c5c3b84e 100644 --- a/EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset +++ b/EndlessVendetta/Content/StarterContent/Blueprints/Blueprint_CeilingLight.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3283a43aeadedeed1d88b9a78899833a2f2acf544e82d4883589cce8095c5487 -size 43745 +oid sha256:4a60a29ad596546d481e43dfb8698842a78cc07f4a4b1000fa397cfba4e72331 +size 158206 diff --git a/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.cpp b/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.cpp index d10d3074..b7fd03dc 100644 --- a/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.cpp +++ b/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.cpp @@ -311,19 +311,20 @@ float AEndlessVendettaCharacter::TakeDamage(const float DamageAmount, FDamageEve { GetWorld()->GetTimerManager().ClearTimer(RegenHealthTimerHandle); } - UE_LOG(LogTemp, Warning, TEXT("Player is dead")); - - TArray FoundActors; - UGameplayStatics::GetAllActorsWithTag(GetWorld(), FName(TEXT("Respawn")), FoundActors); - if (FoundActors.Num() > 0) - { - const AActor* RespawnPoint = FoundActors[0]; - SetActorLocationAndRotation(RespawnPoint->GetActorLocation(), RespawnPoint->GetActorRotation()); - CurrentHealth = MaxHealth; - return Super::TakeDamage(DamageAmount, DamageEvent, EventInstigator, DamageCauser); - } - - UGameplayStatics::OpenLevel(this, FName(*GetWorld()->GetName()), false); + // UE_LOG(LogTemp, Warning, TEXT("Player is dead")); + // + // TArray FoundActors; + // UGameplayStatics::GetAllActorsWithTag(GetWorld(), FName(TEXT("Respawn")), FoundActors); + // if (FoundActors.Num() > 0) + // { + // const AActor* RespawnPoint = FoundActors[0]; + // SetActorLocationAndRotation(RespawnPoint->GetActorLocation(), RespawnPoint->GetActorRotation()); + // CurrentHealth = MaxHealth; + // return Super::TakeDamage(DamageAmount, DamageEvent, EventInstigator, DamageCauser); + // } + // + // UGameplayStatics::OpenLevel(this, FName(*GetWorld()->GetName()), false); + RunDeathSequence(); return Super::TakeDamage(DamageAmount, DamageEvent, EventInstigator, DamageCauser); } TookDamage.Broadcast(); diff --git a/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.h b/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.h index 8a5aeedf..d4c83ae9 100644 --- a/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.h +++ b/EndlessVendetta/Source/EndlessVendetta/EndlessVendettaCharacter.h @@ -292,6 +292,9 @@ protected: UFUNCTION(BlueprintImplementableEvent) void StoppedHoldingInteract(); + UFUNCTION(BlueprintImplementableEvent) + void RunDeathSequence(); + // APawn interface virtual void SetupPlayerInputComponent(UInputComponent* InputComponent) override; // End of APawn interface