머지 완료

This commit is contained in:
2023-11-14 02:44:53 +09:00
parent 24932cdd2b
commit 598a21efc3
8 changed files with 37 additions and 12 deletions

Binary file not shown.

Binary file not shown.

BIN
Content/Character/Allium/BP_Allium.uasset (Stored with Git LFS)

Binary file not shown.

BIN
Content/Maps/DevMap.umap (Stored with Git LFS)

Binary file not shown.

View File

@@ -133,7 +133,7 @@ FString ADeathmatch::InitNewPlayer(APlayerController* NewPlayerController, const
//DebugPerpose
if (Type == CharacterType::Lukriel)
{
Type = CharacterType::Lb;
Type = CharacterType::Allium;
}
if (Team == TeamType::Null)
{

View File

@@ -248,6 +248,11 @@ void ADefaultPlayerController::SetupInputComponent()
void ADefaultPlayerController::Skill1()
{
if (!GetWorld())
return;
if (GetWorld()->GetUnpausedTimeSeconds() - GetPlayerState<ADefaultPlayerState>()->CooldownDuration[(uint8)CooldownType::Skill1]
<= GetPlayerState<ADefaultPlayerState>()->MaxCooldownDuration[(uint8)CooldownType::Skill1])
return;
if (GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skillusable] == 1)
return;
if (!(GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Mana] >= GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skill1Cost]))
@@ -277,6 +282,11 @@ void ADefaultPlayerController::Skill1()
void ADefaultPlayerController::Skill2()
{
if (!GetWorld())
return;
if (GetWorld()->GetUnpausedTimeSeconds() - GetPlayerState<ADefaultPlayerState>()->CooldownDuration[(uint8)CooldownType::Skill2]
<= GetPlayerState<ADefaultPlayerState>()->MaxCooldownDuration[(uint8)CooldownType::Skill2])
return;
if (GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skillusable] == 1)
return;
if (!(GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Mana] >= GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skill2Cost]))
@@ -304,6 +314,11 @@ void ADefaultPlayerController::Skill2()
void ADefaultPlayerController::Skill3()
{
if (!GetWorld())
return;
if (GetWorld()->GetUnpausedTimeSeconds() - GetPlayerState<ADefaultPlayerState>()->CooldownDuration[(uint8)CooldownType::Skill3]
<= GetPlayerState<ADefaultPlayerState>()->MaxCooldownDuration[(uint8)CooldownType::Skill3])
return;
if (GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skillusable] == 1)
return;
if (!(GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Mana] >= GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skill3Cost]))
@@ -334,6 +349,11 @@ void ADefaultPlayerController::Skill4Triggered()
if (!GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::charging] == 0)//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> true<75><65> <20>ƴ<EFBFBD> <20><>
{
if (!GetWorld())
return;
if (GetWorld()->GetUnpausedTimeSeconds() - GetPlayerState<ADefaultPlayerState>()->CooldownDuration[(uint8)CooldownType::Skill4Triggered]
<= GetPlayerState<ADefaultPlayerState>()->MaxCooldownDuration[(uint8)CooldownType::Skill4Triggered])
return;
if (!GetPlayerState<ADefaultPlayerState>()->Stats[(uint8)EStats::Skillusable] == 0) {
GetPlayerState<ADefaultPlayerState>()->SetState(ECharacterState::Idle);
return;

View File

@@ -18,6 +18,7 @@ void ADefaultPlayerState::GetLifetimeReplicatedProps(TArray<FLifetimeProperty>&
DOREPLIFETIME(ADefaultPlayerState, Team);
DOREPLIFETIME(ADefaultPlayerState, CooldownDuration);
DOREPLIFETIME(ADefaultPlayerState, MaxCooldownDuration);
DOREPLIFETIME(ADefaultPlayerState, Stats);
DOREPLIFETIME(ADefaultPlayerState, MaxStats);
@@ -35,7 +36,11 @@ void ADefaultPlayerState::InitPlayerStats_Implementation(const TArray<float>& St
MaxStats.Append(StatsValue);
Stats.Append(StatsValue);
CooldownDuration.Append(CooldownDurationValue);
MaxCooldownDuration.Append(CooldownDurationValue);
for (float Value : CooldownDurationValue)
{
MaxCooldownDuration.Add(0.0f);
}
for (float Value : StatsValue)
{

View File

@@ -85,9 +85,9 @@ public:
UPROPERTY(Replicated, Transient, EditAnywhere, BlueprintReadWrite)
TArray<float> MaxStats;
UPROPERTY(Replicated, Transient, BlueprintReadWrite)
UPROPERTY(Replicated, Transient, EditAnywhere, BlueprintReadWrite)
TArray<float> CooldownDuration;
UPROPERTY(Replicated, Transient, BlueprintReadWrite)
UPROPERTY(Replicated, Transient, EditAnywhere, BlueprintReadWrite)
TArray<float> MaxCooldownDuration;