Implemented Vaulting Animation States and Started Resolving Vaulting not Activating

This commit is contained in:
Rafal Swierczek 2024-01-11 07:49:58 +00:00
parent f2b31cb496
commit 5afd4bfe31
49 changed files with 262 additions and 97 deletions

View File

@ -1,13 +0,0 @@
# Default ignored files
/shelf/
/workspace.xml
# Rider ignored files
/.idea.EndlessVendetta.iml
/contentModel.xml
/modules.xml
/projectSettingsUpdater.xml
# Editor-based HTTP Client requests
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DiscordIJSettingProjectState">
<option name="fileStateFormat" value="Editing: %fileName%" />
<option name="projectStateFormat" value="Project: %projectName%" />
</component>
</project>

View File

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Encoding" addBOMForNewFiles="with BOM under Windows, with no BOM otherwise" />
</project>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="UserContentModel">
<attachedFolders />
<explicitIncludes />
<explicitExcludes />
</component>
</project>

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DiscordProjectSettings">
<option name="show" value="ASK" />
<option name="description" value="" />
</component>
</project>

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/.." vcs="Git" />
</component>
</project>

View File

@ -1,13 +0,0 @@
# Default ignored files
/shelf/
/workspace.xml
# Rider ignored files
/projectSettingsUpdater.xml
/contentModel.xml
/.idea.EndlessVendetta.iml
/modules.xml
# Editor-based HTTP Client requests
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

View File

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Encoding" addBOMForNewFiles="with BOM under Windows, with no BOM otherwise" />
</project>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="UserContentModel">
<attachedFolders />
<explicitIncludes />
<explicitExcludes />
</component>
</project>

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/.." vcs="Git" />
</component>
</project>

View File

@ -0,0 +1,156 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="AutoGeneratedRunConfigurationManager">
<projectFile>Intermediate/ProjectFiles/EndlessVendetta.vcxproj</projectFile>
</component>
<component name="AutoImportSettings">
<option name="autoReloadType" value="SELECTIVE" />
</component>
<component name="ChangeListManager">
<list default="true" id="d360942f-2e59-47ef-8164-c79fbf7dd251" name="Changes" comment="">
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/.gitignore" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/discord-ij.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/encodings.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/indexLayout.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/misc.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta.dir/.idea/vcs.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/.gitignore" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/encodings.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/indexLayout.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/.idea.EndlessVendetta/.idea/vcs.xml" beforeDir="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/FirstPerson/GunMechanicWorld.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/FirstPerson/GunMechanicWorld.uasset" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Content/FirstPersonArms/Animations/FirstPerson_AnimBP.uasset" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Content/FirstPersonArms/Character/Mesh/SK_Mannequin_Arms_Skeleton.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/FirstPersonArms/Character/Mesh/SK_Mannequin_Arms_Skeleton.uasset" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Content/Levels/TrainingFacility.umap" beforeDir="false" afterPath="$PROJECT_DIR$/Content/Levels/TrainingFacility.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/Particles/P_Ambient_Dust.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Content/StarterContent/Particles/P_Ambient_Dust.uasset" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Plugins/VaultIt/Content/Anims/AnimsVaultFP/CR_VaultIt_FP_BothHands.uasset" beforeDir="false" afterPath="$PROJECT_DIR$/Plugins/VaultIt/Content/Anims/AnimsVaultFP/CR_VaultIt_FP_BothHands.uasset" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/EndlessVendettaCharacter.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/EndlessVendettaCharacter.cpp" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterAbilityBase.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterAbilityBase.cpp" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterBase.cpp" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterBase.cpp" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterBase.h" beforeDir="false" afterPath="$PROJECT_DIR$/Source/EndlessVendetta/MyVICharacterBase.h" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
<option name="LAST_RESOLUTION" value="IGNORE" />
</component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$/.." />
</component>
<component name="MarkdownSettingsMigration">
<option name="stateVersion" value="1" />
</component>
<component name="ProjectColorInfo"><![CDATA[{
"customColor": "",
"associatedIndex": 2
}]]></component>
<component name="ProjectId" id="2anGr7EBwnf66ySbAuSjb4RMO0p" />
<component name="ProjectViewState">
<option name="hideEmptyMiddlePackages" value="true" />
<option name="showLibraryContents" value="true" />
</component>
<component name="PropertiesComponent"><![CDATA[{
"keyToString": {
"C++ Project.EndlessVendetta.executor": "Run",
"RunOnceActivity.OpenProjectViewOnStart": "true",
"RunOnceActivity.ShowReadmeOnStart": "true",
"git-widget-placeholder": "GunRange-2.0",
"node.js.detected.package.eslint": "true",
"node.js.detected.package.tslint": "true",
"node.js.selected.package.eslint": "(autodetect)",
"node.js.selected.package.tslint": "(autodetect)",
"nodejs_package_manager_path": "npm",
"vue.rearranger.settings.migration": "true"
},
"keyToStringList": {
"rider.external.source.directories": [
"C:\\Users\\Rafal\\AppData\\Roaming\\JetBrains\\Rider2023.3\\resharper-host\\DecompilerCache",
"C:\\Users\\Rafal\\AppData\\Roaming\\JetBrains\\Rider2023.3\\resharper-host\\SourcesCache",
"C:\\Users\\Rafal\\AppData\\Local\\Symbols\\src"
]
}
}]]></component>
<component name="RunManager">
<configuration name="EndlessVendetta" type="CppProject" factoryName="C++ Project">
<configuration_1>
<option name="CONFIGURATION" value="DebugGame Editor" />
<option name="PLATFORM" value="Win64" />
<option name="PROJECT_FILE_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<option name="CURRENT_LAUNCH_PROFILE" value="Local" />
<option name="EXE_PATH" value="$(LocalDebuggerCommand)" />
<option name="PROGRAM_PARAMETERS" value="$(LocalDebuggerCommandArguments)" />
<option name="WORKING_DIRECTORY" value="$(LocalDebuggerWorkingDirectory)" />
<option name="PASS_PARENT_ENVS" value="1" />
<option name="USE_EXTERNAL_CONSOLE" value="0" />
</configuration_1>
<configuration_2>
<option name="CONFIGURATION" value="Shipping" />
<option name="PLATFORM" value="Win64" />
<option name="PROJECT_FILE_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<option name="CURRENT_LAUNCH_PROFILE" value="Local" />
<option name="EXE_PATH" value="$(LocalDebuggerCommand)" />
<option name="PROGRAM_PARAMETERS" value="$(LocalDebuggerCommandArguments)" />
<option name="WORKING_DIRECTORY" value="$(LocalDebuggerWorkingDirectory)" />
<option name="PASS_PARENT_ENVS" value="1" />
<option name="USE_EXTERNAL_CONSOLE" value="0" />
</configuration_2>
<configuration_3>
<option name="CONFIGURATION" value="DebugGame" />
<option name="PLATFORM" value="Win64" />
<option name="PROJECT_FILE_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<option name="CURRENT_LAUNCH_PROFILE" value="Local" />
<option name="EXE_PATH" value="$(LocalDebuggerCommand)" />
<option name="PROGRAM_PARAMETERS" value="$(LocalDebuggerCommandArguments)" />
<option name="WORKING_DIRECTORY" value="$(LocalDebuggerWorkingDirectory)" />
<option name="PASS_PARENT_ENVS" value="1" />
<option name="USE_EXTERNAL_CONSOLE" value="0" />
</configuration_3>
<configuration_4>
<option name="CONFIGURATION" value="Development Editor" />
<option name="PLATFORM" value="Win64" />
<option name="PROJECT_FILE_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<option name="CURRENT_LAUNCH_PROFILE" value="Local" />
<option name="EXE_PATH" value="$(LocalDebuggerCommand)" />
<option name="PROGRAM_PARAMETERS" value="$(LocalDebuggerCommandArguments)" />
<option name="WORKING_DIRECTORY" value="$(LocalDebuggerWorkingDirectory)" />
<option name="PASS_PARENT_ENVS" value="1" />
<option name="USE_EXTERNAL_CONSOLE" value="0" />
</configuration_4>
<configuration_5>
<option name="CONFIGURATION" value="Development" />
<option name="PLATFORM" value="Win64" />
<option name="PROJECT_FILE_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<option name="CURRENT_LAUNCH_PROFILE" value="Local" />
<option name="EXE_PATH" value="$(LocalDebuggerCommand)" />
<option name="PROGRAM_PARAMETERS" value="$(LocalDebuggerCommandArguments)" />
<option name="WORKING_DIRECTORY" value="$(LocalDebuggerWorkingDirectory)" />
<option name="PASS_PARENT_ENVS" value="1" />
<option name="USE_EXTERNAL_CONSOLE" value="0" />
</configuration_5>
<option name="DEFAULT_PROJECT_PATH" value="$PROJECT_DIR$/Intermediate/ProjectFiles/EndlessVendetta.vcxproj" />
<method v="2">
<option name="Build" />
</method>
</configuration>
</component>
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
<component name="TaskManager">
<task active="true" id="Default" summary="Default task">
<changelist id="d360942f-2e59-47ef-8164-c79fbf7dd251" name="Changes" comment="" />
<created>1704947128241</created>
<option name="number" value="Default" />
<option name="presentableId" value="Default" />
<updated>1704947128241</updated>
<workItem from="1704947131131" duration="5567000" />
</task>
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
<option name="version" value="3" />
</component>
<component name="VcsManagerConfiguration">
<option name="CLEAR_INITIAL_COMMIT_MESSAGE" value="true" />
</component>
</project>

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4ac919274afd8257d1933029fde8e41ecade3a87c3136e65980f9d6175fb06a1
size 65928
oid sha256:06d7c8221d10354ec1e9be8f31b4d84447688c99f651d8e702849bac8846c4e8
size 79266

Binary file not shown.

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:140293d5379e6f921760d290e4c078d0e2168f88b400901e5f9edb3433b8a359
size 966483

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:928263e4929943c3bca1c28ad56a4a5530a5a7e2318a11275415abcb276a0e15
oid sha256:7db21551a3a56def353e10eb4a8429d0980049797fd36509f2096a18a79c6f39
size 679253

View File

@ -162,8 +162,8 @@ void AEndlessVendettaCharacter::SetupPlayerInputComponent(class UInputComponent*
if (UEnhancedInputComponent* EnhancedInputComponent = CastChecked<UEnhancedInputComponent>(PlayerInputComponent))
{
//Jumping
EnhancedInputComponent->BindAction(JumpAction, ETriggerEvent::Started, this, &AEndlessVendettaCharacter::Jumping);
EnhancedInputComponent->BindAction(JumpAction, ETriggerEvent::Completed, this, &AEndlessVendettaCharacter::StopJump);
EnhancedInputComponent->BindAction(JumpAction, ETriggerEvent::Started, this, &ACharacter::Jump);
EnhancedInputComponent->BindAction(JumpAction, ETriggerEvent::Completed, this, &ACharacter::StopJumping);
//Moving
EnhancedInputComponent->BindAction(MoveAction, ETriggerEvent::Triggered, this, &AEndlessVendettaCharacter::Move);

View File

@ -1,8 +1,6 @@
// Copyright (c) 2019-2022 Drowning Dragons Limited. All Rights Reserved.
#include "MyVICharacterAbilityBase.h"
#include "Pawn/VICharacterAbilityBase.h"
#include "GAS/VIAbilitySystemComponent.h"
AMyVICharacterAbilityBase::AMyVICharacterAbilityBase(const FObjectInitializer& OI)

View File

@ -73,6 +73,7 @@ void AMyVICharacterBase::Jump()
// If missing critical components then jump and exit
if (!VaultComponent || !GetCharacterMovement())
{
UE_LOG(LogTemp, Warning, TEXT("no vault comp or character movement"));
Super::Jump();
return;
}
@ -80,11 +81,13 @@ void AMyVICharacterBase::Jump()
// Either jump or vault, determined by VaultComponent::EVIJumpKeyPriority
if (VaultComponent->Jump(GetCharacterMovement()->GetGravityZ(), CanJump(), GetCharacterMovement()->IsFalling()))
{
UE_LOG(LogTemp, Warning, TEXT("gravity Z: %f"), GetCharacterMovement()->GetGravityZ());
// Jump normally
Super::Jump();
}
else
{
UE_LOG(LogTemp, Warning, TEXT("try to vault"));
// Jump key essentially presses the vault input
VaultComponent->Vault();
}
@ -196,24 +199,28 @@ bool AMyVICharacterBase::CanVault_Implementation() const
// Vaulting must finish before starting another vault attempt
if (IsVaulting())
{
UE_LOG(LogTemp, Warning, TEXT("is already vaulting"));
return false;
}
// Invalid components
if (!VaultComponent || !GetCharacterMovement())
{
UE_LOG(LogTemp, Warning, TEXT("invalid componets for vaulting"));
return false;
}
// Animation instance is required to play vault montage
if (!GetMesh() || !GetMesh()->GetAnimInstance())
{
UE_LOG(LogTemp, Warning, TEXT("Animation instance is required to play vault montage"));
return false;
}
// Authority not initialized (this isn't set on clients)
if (HasAuthority() && !VaultComponent->bVaultAbilityInitialized)
{
UE_LOG(LogTemp, Warning, TEXT("Authority not initialized (this isn't set on clients), hence cant vault"));
return false;
}
@ -222,30 +229,36 @@ bool AMyVICharacterBase::CanVault_Implementation() const
{
if (GetCharacterMovement()->IsMovingOnGround() && !VaultComponent->bCanVaultFromGround)
{
UE_LOG(LogTemp, Warning, TEXT("cant vault cuz on the ground and cant vault from ground"));
return false;
}
if (GetCharacterMovement()->IsFalling() && !VaultComponent->bCanVaultFromFalling)
{
UE_LOG(LogTemp, Warning, TEXT("cant vault cuz is falling and cant vault from falling"));
return false;
}
if (GetCharacterMovement()->IsSwimming() && !VaultComponent->bCanVaultFromSwimming)
{
UE_LOG(LogTemp, Warning, TEXT("cant vault from swimming"));
return false;
}
}
else
{
UE_LOG(LogTemp, Warning, TEXT("cant vault cuz isnt either swimming, walking on the ground or falling"));
return false;
}
// Can't vault while crouching
if (!VaultComponent->bCanVaultFromCrouching && GetCharacterMovement()->IsCrouching())
{
UE_LOG(LogTemp, Warning, TEXT("cant vault cuz is crouching"));
return false;
}
UE_LOG(LogTemp, Warning, TEXT("actually can vault"));
// Passed all conditions
return true;
}

View File

@ -4,7 +4,6 @@
#include "CoreMinimal.h"
#include "EndlessVendettaCharacter.h"
#include "VITypes.h"
#include "Pawn/VIPawnInterface.h"
#include "MyVICharacterBase.generated.h"