Section 10: Outline and Glow Effects - Lecture 186
Swap pickup text
This commit is contained in:
parent
9e1d093008
commit
70d390a0de
BIN
Content/AnimStarterPack/Aim_Space_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Aim_Space_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Aim_Space_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Aim_Space_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/BS_CrouchWalk.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/BS_CrouchWalk.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/BS_Jog.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/BS_Jog.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Idle_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Idle_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Idle_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Idle_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Bwd_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Bwd_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Bwd_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Bwd_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Fwd_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Fwd_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Fwd_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Fwd_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Lt_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Lt_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Lt_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Lt_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Rt_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Rt_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_Walk_Rt_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_Walk_Rt_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_to_Stand_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_to_Stand_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Crouch_to_Stand_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Crouch_to_Stand_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Death_1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Death_1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Death_2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Death_2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Death_3.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Death_3.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Death_Ironsights_1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Death_Ironsights_1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Death_Ironsights_2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Death_Ironsights_2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Equip_Pistol_Standing.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Equip_Pistol_Standing.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Equip_Rifle_Standing.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Equip_Rifle_Standing.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Fire_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Fire_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Fire_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Fire_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Fire_Shotgun_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Fire_Shotgun_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Fire_Shotgun_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Fire_Shotgun_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Hit_React_1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Hit_React_1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Hit_React_2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Hit_React_2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Hit_React_3.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Hit_React_3.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Hit_React_4.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Hit_React_4.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Idle_Pistol.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Idle_Pistol.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Idle_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Idle_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Idle_Rifle_Hip_Break1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Idle_Rifle_Hip_Break1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Idle_Rifle_Hip_Break2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Idle_Rifle_Hip_Break2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Idle_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Idle_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jog_Bwd_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jog_Bwd_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jog_Fwd_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jog_Fwd_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jog_Lt_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jog_Lt_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jog_Rt_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jog_Rt_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jump_From_Jog.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jump_From_Jog.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jump_From_Stand.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jump_From_Stand.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Jump_From_Stand_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Jump_From_Stand_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Death_1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Death_1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Death_2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Death_2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Fire_1.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Fire_1.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Fire_2.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Fire_2.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Idle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Idle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Reload_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Reload_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_Reload_Shotgun.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_Reload_Shotgun.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Prone_To_Stand.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Prone_To_Stand.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Reload_Pistol.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Reload_Pistol.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Reload_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Reload_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Reload_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Reload_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Reload_Shotgun_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Reload_Shotgun_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Reload_Shotgun_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Reload_Shotgun_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Showcase.umap (Stored with Git LFS)
BIN
Content/AnimStarterPack/Showcase.umap (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Sprint_Fwd_Rifle.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Sprint_Fwd_Rifle.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Stand_To_Prone.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Stand_To_Prone.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Stand_to_Crouch_Rifle_Hip.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Stand_to_Crouch_Rifle_Hip.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Stand_to_Crouch_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Stand_to_Crouch_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4ASP_HeroTPP_AnimBlueprint.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4ASP_HeroTPP_AnimBlueprint.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/M_UE4Man_Body.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/M_UE4Man_Body.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/M_UE4Man_ChestLogo.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/M_UE4Man_ChestLogo.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_GlossyBlack_Latex_UE4.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_GlossyBlack_Latex_UE4.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_Plastic_Shiny_Beige.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_Plastic_Shiny_Beige.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_Plastic_Shiny_Beige_LOGO.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_Plastic_Shiny_Beige_LOGO.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_SoftMetal_UE4.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/ML_SoftMetal_UE4.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Aluminum01.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Aluminum01.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Aluminum01_N.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Aluminum01_N.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Rubber_Blue_01_D.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Rubber_Blue_01_D.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Rubber_Blue_01_N.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Materials/MaterialLayers/T_ML_Rubber_Blue_01_N.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/SK_Mannequin.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/SK_Mannequin.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/SK_Mannequin_PhysicsAsset.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/SK_Mannequin_PhysicsAsset.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/UE4_Mannequin_Skeleton.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Mesh/UE4_Mannequin_Skeleton.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4Man_Logo_N.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4Man_Logo_N.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_LOGO_CARD.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_LOGO_CARD.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin_MAT_MASKA.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin_MAT_MASKA.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin__normals.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin__normals.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin_occlusion_Mobile.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/UE4_Mannequin/Textures/UE4_Mannequin_occlusion_Mobile.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Ue4ASP_Character.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Ue4ASP_Character.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Walk_Bwd_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Walk_Bwd_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Walk_Fwd_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Walk_Fwd_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Walk_Lt_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Walk_Lt_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/AnimStarterPack/Walk_Rt_Rifle_Ironsights.uasset (Stored with Git LFS)
BIN
Content/AnimStarterPack/Walk_Rt_Rifle_Ironsights.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/_Game/Ammo/Ammo9mmBP.uasset (Stored with Git LFS)
BIN
Content/_Game/Ammo/Ammo9mmBP.uasset (Stored with Git LFS)
Binary file not shown.
Binary file not shown.
BIN
Content/_Game/Character/Animations/Retargeted/Equip_Rifle_Standing.uasset (Stored with Git LFS)
Normal file
BIN
Content/_Game/Character/Animations/Retargeted/Equip_Rifle_Standing.uasset (Stored with Git LFS)
Normal file
Binary file not shown.
BIN
Content/_Game/Character/ShooterAnimBP.uasset (Stored with Git LFS)
BIN
Content/_Game/Character/ShooterAnimBP.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/_Game/Character/ShooterCharacterBP.uasset (Stored with Git LFS)
BIN
Content/_Game/Character/ShooterCharacterBP.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/_Game/HUD/PickupWidgetBP.uasset (Stored with Git LFS)
BIN
Content/_Game/HUD/PickupWidgetBP.uasset (Stored with Git LFS)
Binary file not shown.
BIN
Content/_Game/Maps/DefaultMap.umap (Stored with Git LFS)
BIN
Content/_Game/Maps/DefaultMap.umap (Stored with Git LFS)
Binary file not shown.
BIN
Content/_Game/Weapons/BaseWeapon/BaseWeaponBP.uasset (Stored with Git LFS)
BIN
Content/_Game/Weapons/BaseWeapon/BaseWeaponBP.uasset (Stored with Git LFS)
Binary file not shown.
|
@ -35,7 +35,8 @@ AItem::AItem() :
|
||||||
GlowAmount(150.f),
|
GlowAmount(150.f),
|
||||||
FresnelExponent(3.f),
|
FresnelExponent(3.f),
|
||||||
FresnelReflectFraction(4.f),
|
FresnelReflectFraction(4.f),
|
||||||
SlotIndex(0)
|
SlotIndex(0),
|
||||||
|
bCharacterInventoryFull(false)
|
||||||
{
|
{
|
||||||
// Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it.
|
// Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it.
|
||||||
PrimaryActorTick.bCanEverTick = true;
|
PrimaryActorTick.bCanEverTick = true;
|
||||||
|
@ -129,11 +130,18 @@ void AItem::setActiveStars()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void AItem::PlayPickupSound()
|
void AItem::PlayPickupSound(bool bForcePlaySound)
|
||||||
{
|
{
|
||||||
if (Character)
|
if (Character)
|
||||||
{
|
{
|
||||||
if (Character->ShouldPlayPickupSound())
|
if (bForcePlaySound)
|
||||||
|
{
|
||||||
|
if (PickupSound)
|
||||||
|
{
|
||||||
|
UGameplayStatics::PlaySound2D(this, PickupSound);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (Character->ShouldPlayPickupSound())
|
||||||
{
|
{
|
||||||
Character->StartPickupSoundTimer();
|
Character->StartPickupSoundTimer();
|
||||||
if (PickupSound)
|
if (PickupSound)
|
||||||
|
@ -219,11 +227,15 @@ void AItem::DisableGlowMaterial()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void AItem::PlayEquipSound()
|
void AItem::PlayEquipSound(bool bForcePlaySound)
|
||||||
{
|
{
|
||||||
if (Character)
|
if (Character)
|
||||||
{
|
{
|
||||||
if (Character->ShouldPlayEquipSound())
|
if (bForcePlaySound)
|
||||||
|
{
|
||||||
|
UGameplayStatics::PlaySound2D(this, EquipSound);
|
||||||
|
}
|
||||||
|
else if (Character->ShouldPlayEquipSound())
|
||||||
{
|
{
|
||||||
Character->StartEquipSoundTimer();
|
Character->StartEquipSoundTimer();
|
||||||
if (EquipSound)
|
if (EquipSound)
|
||||||
|
@ -462,7 +474,7 @@ void AItem::SetItemProperties(EItemState State)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void AItem::StartItemCurve(AShooterCharacter* Char)
|
void AItem::StartItemCurve(AShooterCharacter* Char, bool bForcePlaySound)
|
||||||
{
|
{
|
||||||
// Store a handle to the Character
|
// Store a handle to the Character
|
||||||
Character = Char;
|
Character = Char;
|
||||||
|
@ -473,7 +485,7 @@ void AItem::StartItemCurve(AShooterCharacter* Char)
|
||||||
// Add 1 to the Item Count for this interp location struct
|
// Add 1 to the Item Count for this interp location struct
|
||||||
Character->IncrementInterpLocItemCount(InterpLocIndex, 1);
|
Character->IncrementInterpLocItemCount(InterpLocIndex, 1);
|
||||||
|
|
||||||
PlayPickupSound();
|
PlayPickupSound(bForcePlaySound);
|
||||||
|
|
||||||
// Store the initial locatino of the Item
|
// Store the initial locatino of the Item
|
||||||
ItemInterpStartLocation = GetActorLocation();
|
ItemInterpStartLocation = GetActorLocation();
|
||||||
|
|
|
@ -81,7 +81,7 @@ protected:
|
||||||
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Item Properties", meta = (AllowPrivateAccess = true))
|
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = "Item Properties", meta = (AllowPrivateAccess = true))
|
||||||
USphereComponent* AreaSphere;
|
USphereComponent* AreaSphere;
|
||||||
|
|
||||||
void PlayPickupSound();
|
void PlayPickupSound(bool bForcePlaySound = false);
|
||||||
|
|
||||||
virtual void InitializeCustomDepth();
|
virtual void InitializeCustomDepth();
|
||||||
|
|
||||||
|
@ -113,7 +113,7 @@ public:
|
||||||
FVector GetInterpLocation();
|
FVector GetInterpLocation();
|
||||||
|
|
||||||
// Called in AShooterCharacter::GetPickupItem
|
// Called in AShooterCharacter::GetPickupItem
|
||||||
void PlayEquipSound();
|
void PlayEquipSound(bool bForcePlaySound = false);
|
||||||
private:
|
private:
|
||||||
|
|
||||||
/* Skeletal mesh for the item */
|
/* Skeletal mesh for the item */
|
||||||
|
@ -252,6 +252,10 @@ private:
|
||||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = Inventory, meta = (AllowPrivateAccess = true))
|
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = Inventory, meta = (AllowPrivateAccess = true))
|
||||||
int32 SlotIndex;
|
int32 SlotIndex;
|
||||||
|
|
||||||
|
/** True when the character's inventory is full */
|
||||||
|
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = Inventory, meta = (AllowPrivateAccess = true))
|
||||||
|
bool bCharacterInventoryFull;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
FORCEINLINE UWidgetComponent* GetPickupWidget() const { return PickupWidget; }
|
FORCEINLINE UWidgetComponent* GetPickupWidget() const { return PickupWidget; }
|
||||||
|
|
||||||
|
@ -273,8 +277,12 @@ public:
|
||||||
FORCEINLINE int32 GetSlotIndex() const { return SlotIndex; }
|
FORCEINLINE int32 GetSlotIndex() const { return SlotIndex; }
|
||||||
FORCEINLINE void SetSlotIndex(int32 Index) { SlotIndex = Index; }
|
FORCEINLINE void SetSlotIndex(int32 Index) { SlotIndex = Index; }
|
||||||
|
|
||||||
|
FORCEINLINE void SetCharacter(AShooterCharacter* Char) { Character = Char; }
|
||||||
|
|
||||||
|
FORCEINLINE void SetCharacterInventoryFull(bool bFull) { bCharacterInventoryFull = bFull; }
|
||||||
|
|
||||||
/** Called from the AShooterCharacter class */
|
/** Called from the AShooterCharacter class */
|
||||||
void StartItemCurve(AShooterCharacter* Char);
|
void StartItemCurve(AShooterCharacter* Char, bool bForcePlaySound = false);
|
||||||
|
|
||||||
virtual void EnableCustomDepth();
|
virtual void EnableCustomDepth();
|
||||||
virtual void DisableCustomDepth();
|
virtual void DisableCustomDepth();
|
||||||
|
|
|
@ -62,6 +62,7 @@ void UShooterAnimInstance::UpdateAnimationProperties(float DeltaTime)
|
||||||
bAiming = ShooterCharacter->GetAiming();
|
bAiming = ShooterCharacter->GetAiming();
|
||||||
bReloading = ShooterCharacter->GetCombatState() == ECombatState::ECS_Reloading;
|
bReloading = ShooterCharacter->GetCombatState() == ECombatState::ECS_Reloading;
|
||||||
bCrouching = ShooterCharacter->IsCrouching();
|
bCrouching = ShooterCharacter->IsCrouching();
|
||||||
|
bEquipping = ShooterCharacter->GetCombatState() == ECombatState::ECS_Equipping;
|
||||||
|
|
||||||
if (bReloading)
|
if (bReloading)
|
||||||
{
|
{
|
||||||
|
@ -148,7 +149,7 @@ void UShooterAnimInstance::TurnInPlace()
|
||||||
// Set the recoil weight
|
// Set the recoil weight
|
||||||
if (bTurningInPlace)
|
if (bTurningInPlace)
|
||||||
{
|
{
|
||||||
if (bReloading)
|
if (bReloading || bEquipping)
|
||||||
{
|
{
|
||||||
RecoilWeight = 1.f;
|
RecoilWeight = 1.f;
|
||||||
}
|
}
|
||||||
|
@ -161,7 +162,7 @@ void UShooterAnimInstance::TurnInPlace()
|
||||||
{
|
{
|
||||||
if (bCrouching)
|
if (bCrouching)
|
||||||
{
|
{
|
||||||
if (bReloading)
|
if (bReloading || bEquipping)
|
||||||
{
|
{
|
||||||
RecoilWeight = 1.f;
|
RecoilWeight = 1.f;
|
||||||
}
|
}
|
||||||
|
@ -172,7 +173,7 @@ void UShooterAnimInstance::TurnInPlace()
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (bAiming || bReloading)
|
if (bAiming || bReloading || bEquipping)
|
||||||
{
|
{
|
||||||
RecoilWeight = 1.f;
|
RecoilWeight = 1.f;
|
||||||
}
|
}
|
||||||
|
|
|
@ -112,11 +112,15 @@ private:
|
||||||
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Crouching", meta = (AllowPrivateAccess = true))
|
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Crouching", meta = (AllowPrivateAccess = true))
|
||||||
bool bCrouching;
|
bool bCrouching;
|
||||||
|
|
||||||
|
/** True when equipping */
|
||||||
|
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Combat", meta = (AllowPrivateAccess = true))
|
||||||
|
bool bEquipping;
|
||||||
|
|
||||||
/** Change the recoil weight based on turning in place and aiming */
|
/** Change the recoil weight based on turning in place and aiming */
|
||||||
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Combat", meta = (AllowPrivateAccess = true))
|
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Combat", meta = (AllowPrivateAccess = true))
|
||||||
float RecoilWeight;
|
float RecoilWeight;
|
||||||
|
|
||||||
/** True when turning in place */
|
/** True when turning in place */
|
||||||
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Combat", meta = (AllowPrivateAccess = true))
|
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Turn In Place", meta = (AllowPrivateAccess = true))
|
||||||
bool bTurningInPlace;
|
bool bTurningInPlace;
|
||||||
};
|
};
|
||||||
|
|
|
@ -152,6 +152,7 @@ void AShooterCharacter::BeginPlay()
|
||||||
EquipWeapon(SpawnDefaultWeapon());
|
EquipWeapon(SpawnDefaultWeapon());
|
||||||
Inventory.Add(EquippedWeapon);
|
Inventory.Add(EquippedWeapon);
|
||||||
EquippedWeapon->SetSlotIndex(0);
|
EquippedWeapon->SetSlotIndex(0);
|
||||||
|
EquippedWeapon->SetCharacter(this);
|
||||||
|
|
||||||
InitializeAmmoMap();
|
InitializeAmmoMap();
|
||||||
|
|
||||||
|
@ -413,7 +414,10 @@ void AShooterCharacter::Key5Pressed()
|
||||||
|
|
||||||
void AShooterCharacter::ExchangeInventoryItems(int32 CurrentItemIndex, int32 NewItemIndex)
|
void AShooterCharacter::ExchangeInventoryItems(int32 CurrentItemIndex, int32 NewItemIndex)
|
||||||
{
|
{
|
||||||
if (CurrentItemIndex == NewItemIndex || NewItemIndex >= Inventory.Num()) return;
|
if (CurrentItemIndex == NewItemIndex
|
||||||
|
|| NewItemIndex >= Inventory.Num()
|
||||||
|
|| CombatState != ECombatState::ECS_Unoccupied)
|
||||||
|
return;
|
||||||
|
|
||||||
auto OldEquippedWeapon = EquippedWeapon;
|
auto OldEquippedWeapon = EquippedWeapon;
|
||||||
auto NewWeapon = Cast<AWeapon>(Inventory[NewItemIndex]);
|
auto NewWeapon = Cast<AWeapon>(Inventory[NewItemIndex]);
|
||||||
|
@ -422,6 +426,15 @@ void AShooterCharacter::ExchangeInventoryItems(int32 CurrentItemIndex, int32 New
|
||||||
|
|
||||||
OldEquippedWeapon->SetItemState(EItemState::EIS_PickedUp);
|
OldEquippedWeapon->SetItemState(EItemState::EIS_PickedUp);
|
||||||
NewWeapon->SetItemState(EItemState::EIS_Equipped);
|
NewWeapon->SetItemState(EItemState::EIS_Equipped);
|
||||||
|
|
||||||
|
CombatState = ECombatState::ECS_Equipping;
|
||||||
|
UAnimInstance* AnimInstance = GetMesh()->GetAnimInstance();
|
||||||
|
if (AnimInstance && EquipMontage)
|
||||||
|
{
|
||||||
|
AnimInstance->Montage_Play(EquipMontage, 1.0f);
|
||||||
|
AnimInstance->Montage_JumpToSection(FName("Equip"));
|
||||||
|
}
|
||||||
|
NewWeapon->PlayEquipSound(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
int32 AShooterCharacter::GetInterpLocationIndex()
|
int32 AShooterCharacter::GetInterpLocationIndex()
|
||||||
|
@ -762,6 +775,16 @@ void AShooterCharacter::TraceForItems()
|
||||||
TraceHitItem = nullptr;
|
TraceHitItem = nullptr;
|
||||||
|
|
||||||
SetItemPickupWidgetVisibility(TraceHitItem, true);
|
SetItemPickupWidgetVisibility(TraceHitItem, true);
|
||||||
|
|
||||||
|
if (Inventory.Num() >= INVENTORY_CAPACITY)
|
||||||
|
{
|
||||||
|
// Inventory is full
|
||||||
|
TraceHitItem->SetCharacterInventoryFull(true);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TraceHitItem->SetCharacterInventoryFull(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (OldTraceHitItem) // Hide widget for the item from last frame
|
else if (OldTraceHitItem) // Hide widget for the item from last frame
|
||||||
{
|
{
|
||||||
|
@ -841,9 +864,11 @@ void AShooterCharacter::DropWeapon()
|
||||||
|
|
||||||
void AShooterCharacter::SelectButtonPressed()
|
void AShooterCharacter::SelectButtonPressed()
|
||||||
{
|
{
|
||||||
|
if (CombatState != ECombatState::ECS_Unoccupied) return;
|
||||||
|
|
||||||
if (TraceHitItem)
|
if (TraceHitItem)
|
||||||
{
|
{
|
||||||
TraceHitItem->StartItemCurve(this);
|
TraceHitItem->StartItemCurve(this, true);
|
||||||
TraceHitItem = nullptr;
|
TraceHitItem = nullptr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1001,6 +1026,11 @@ void AShooterCharacter::FinishReloading()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void AShooterCharacter::FinishEquipping()
|
||||||
|
{
|
||||||
|
CombatState = ECombatState::ECS_Unoccupied;
|
||||||
|
}
|
||||||
|
|
||||||
bool AShooterCharacter::CarryingAmmo()
|
bool AShooterCharacter::CarryingAmmo()
|
||||||
{
|
{
|
||||||
if (!EquippedWeapon) return false;
|
if (!EquippedWeapon) return false;
|
||||||
|
|
|
@ -24,6 +24,7 @@ enum class ECombatState : uint8
|
||||||
ECS_Unoccupied UMETA(DisplayName = "Unoccupied"),
|
ECS_Unoccupied UMETA(DisplayName = "Unoccupied"),
|
||||||
ECS_FireTimerInProgress UMETA(DisplayName = "FireTimerInProgress"),
|
ECS_FireTimerInProgress UMETA(DisplayName = "FireTimerInProgress"),
|
||||||
ECS_Reloading UMETA(DisplayName = "Reloading"),
|
ECS_Reloading UMETA(DisplayName = "Reloading"),
|
||||||
|
ECS_Equipping UMETA(DisplayName = "Equipping"),
|
||||||
|
|
||||||
ECS_MAX UMETA(DisplayName = "DefaultMax")
|
ECS_MAX UMETA(DisplayName = "DefaultMax")
|
||||||
};
|
};
|
||||||
|
@ -167,6 +168,9 @@ protected:
|
||||||
|
|
||||||
UFUNCTION(BlueprintCallable)
|
UFUNCTION(BlueprintCallable)
|
||||||
void FinishReloading();
|
void FinishReloading();
|
||||||
|
|
||||||
|
UFUNCTION(BlueprintCallable)
|
||||||
|
void FinishEquipping();
|
||||||
|
|
||||||
/** Check to see if we have ammo of the EquippedWeapon's ammo type */
|
/** Check to see if we have ammo of the EquippedWeapon's ammo type */
|
||||||
bool CarryingAmmo();
|
bool CarryingAmmo();
|
||||||
|
@ -382,6 +386,10 @@ private:
|
||||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Combat, meta = (AllowPrivateAccess = true))
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Combat, meta = (AllowPrivateAccess = true))
|
||||||
UAnimMontage* ReloadMontage;
|
UAnimMontage* ReloadMontage;
|
||||||
|
|
||||||
|
/* Montage for reloading the weapon */
|
||||||
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Combat, meta = (AllowPrivateAccess = true))
|
||||||
|
UAnimMontage* EquipMontage;
|
||||||
|
|
||||||
/* Transform of the clip when we first grab the clip during reloading */
|
/* Transform of the clip when we first grab the clip during reloading */
|
||||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = Combat, meta = (AllowPrivateAccess = true))
|
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = Combat, meta = (AllowPrivateAccess = true))
|
||||||
FTransform ClipTransform;
|
FTransform ClipTransform;
|
||||||
|
|
Loading…
Reference in New Issue