Update Pistol for Projectile, VFX & SFX Relative to Crosshair
This commit is contained in:
parent
80eec7267c
commit
c392ebc5c3
@ -60,7 +60,7 @@
|
||||
+CollisionChannelRedirects=(OldName="PawnMovement",NewName="Pawn")
|
||||
|
||||
[/Script/EngineSettings.GameMapsSettings]
|
||||
EditorStartupMap=/Game/Levels/MainMenuLevel.MainMenuLevel
|
||||
EditorStartupMap=/Game/Levels/AITest.AITest
|
||||
LocalMapOptions=
|
||||
TransitionMap=None
|
||||
bUseSplitscreen=True
|
||||
|
BIN
EndlessVendetta/Content/AI/Enemy/Basic/BP_BasicEnemyCharacterSwat.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/AI/Enemy/Basic/BP_BasicEnemyCharacterSwat.uasset
(Stored with Git LFS)
Binary file not shown.
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/BaseWeapons/Pistols/BP_BasePistolWeapon.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/FirstPerson/Blueprints/BaseWeapons/Pistols/BP_BasePistolWeapon.uasset
(Stored with Git LFS)
Binary file not shown.
BIN
EndlessVendetta/Content/__ExternalActors__/Levels/AITest/B/8N/O8PP5KE5USY7FTAE75J65R.uasset
(Stored with Git LFS)
BIN
EndlessVendetta/Content/__ExternalActors__/Levels/AITest/B/8N/O8PP5KE5USY7FTAE75J65R.uasset
(Stored with Git LFS)
Binary file not shown.
@ -179,7 +179,7 @@ void ABaseWeaponClass::Fire()
|
||||
traceEnd = traceStart + (GunStartArrow->GetForwardVector() * BulletDistance);
|
||||
if (GetWorldTimerManager().IsTimerActive(timerHandle)) return;
|
||||
GetWorld()->LineTraceSingleByChannel(outHit, traceStart, traceEnd, ECC_Visibility, collisionParams);
|
||||
DrawDebugLine(this->GetWorld(), traceStart, traceEnd, FColor::Black , false, 0.2f, 0U, 0.2f);
|
||||
WeaponFired.Broadcast();
|
||||
playerControllerRef->PlayerCameraManager->StartCameraShake(CameraShakeClass, 1);
|
||||
currentAmmoCount -= 1;
|
||||
GenerateRecoilVector();
|
||||
|
@ -27,7 +27,7 @@ protected:
|
||||
virtual void BeginPlay() override;
|
||||
|
||||
virtual void ApplyRecoil(float DeltaTime);
|
||||
|
||||
|
||||
void GenerateRecoilVector();
|
||||
|
||||
void nullSamples();
|
||||
@ -45,22 +45,20 @@ protected:
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void ShowReloadingWidget();
|
||||
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void HideReloadingWidget();
|
||||
|
||||
|
||||
|
||||
public:
|
||||
// Called every frame
|
||||
virtual void Tick(float DeltaTime) override;
|
||||
void ReloadTimer();
|
||||
|
||||
|
||||
float currentPitch;
|
||||
|
||||
|
||||
UPROPERTY(EditAnywhere)
|
||||
float BulletDistance;
|
||||
|
||||
|
||||
UPROPERTY(EditAnywhere, BlueprintReadWrite)
|
||||
FString WeaponName;
|
||||
|
||||
@ -111,9 +109,9 @@ public:
|
||||
|
||||
UPROPERTY(VisibleAnywhere)
|
||||
ACharacter* playerInWorld;
|
||||
|
||||
|
||||
AEndlessVendettaCharacter* endlessVendettaChar;
|
||||
|
||||
|
||||
APlayerController* playerControllerRef;
|
||||
|
||||
FTimerHandle timerHandle;
|
||||
@ -169,7 +167,7 @@ public:
|
||||
|
||||
void Interact() override;
|
||||
|
||||
void InteractPrompt() override;
|
||||
void InteractPrompt() override;
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void WeaponStatsPopUp();
|
||||
@ -185,6 +183,11 @@ public:
|
||||
UFUNCTION(BlueprintImplementableEvent)
|
||||
void HideNeedReloadUI();
|
||||
|
||||
DECLARE_DYNAMIC_MULTICAST_DELEGATE(FWeaponFired);
|
||||
|
||||
UPROPERTY(BlueprintAssignable, Category = "Weapons")
|
||||
FWeaponFired WeaponFired;
|
||||
|
||||
protected:
|
||||
UArrowComponent* GunStartArrow;
|
||||
bool bStopShooting = false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user