Merge branch 'head-bobbing' into dev

# Conflicts:
#	EndlessVendetta/Content/FirstPerson/Blueprints/BP_FirstPersonCharacter.uasset
#	EndlessVendetta/Content/FirstPerson/Blueprints/BaseWeapons/BP_BaseWeapon.uasset
#	EndlessVendetta/Content/Levels/TrainingFacility.umap
This commit is contained in:
Rafal Swierczek 2024-01-19 15:55:14 +00:00
commit d5f98d5d39
7 changed files with 16 additions and 8 deletions

View File

@ -98,7 +98,6 @@ void AEndlessVendettaCharacter::Tick(float DeltaTime)
}
else if (MoveGroundSpeed <= 0)
{
this->GetFirstPersonCameraComponent()->SetFieldOfView(90);
bIsPlayerMoving = false;
}
if (bPressedJump)
@ -117,7 +116,6 @@ void AEndlessVendettaCharacter::Tick(float DeltaTime)
if (CurrentStamina <= 0.0f)
{
bIsPlayerSprinting = false;
this->GetFirstPersonCameraComponent()->SetFieldOfView(90);
CurrentStamina = 0.0f;
CharacterMovement->MaxWalkSpeed = OriginalWalkSpeed;
}
@ -584,7 +582,6 @@ void AEndlessVendettaCharacter::Sprint()
if (MoveGroundSpeed > 0)
{
CharacterMovement->MaxWalkSpeed = SprintSpeed;
this->GetFirstPersonCameraComponent()->SetFieldOfView(100);
}
}
}
@ -596,7 +593,6 @@ void AEndlessVendettaCharacter::StopSprint()
{
UE_LOG(LogTemp, Display, TEXT("Player stopped sprinting"));
CharacterMovement->MaxWalkSpeed = OriginalWalkSpeed;
this->GetFirstPersonCameraComponent()->SetFieldOfView(90);
}
}
@ -620,7 +616,6 @@ void AEndlessVendettaCharacter::Jumping()
void AEndlessVendettaCharacter::StopJump()
{
Super::StopJumping();
UE_LOG(LogTemp, Display, TEXT("Player has stopped jumping"));
bHasPlayerJumped = false;
}

View File

@ -136,7 +136,7 @@ public:
bool bIsPlayerMoving = false;
UPROPERTY(VisibleAnywhere)
UPROPERTY(VisibleAnywhere, BlueprintReadWrite)
bool bIsPlayerSprinting = false;
double MoveGroundSpeed;
@ -188,6 +188,7 @@ public:
void Jumping();
void StopJump();
UPROPERTY(BlueprintReadWrite)
bool bHasPlayerJumped = false;
UArrowComponent* ScopedLocationArrow;