1
This commit is contained in:
@@ -3,6 +3,7 @@ using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using BITFALL.Entities;
|
||||
using BITFALL.Player.Movement;
|
||||
using BITFALL.Props;
|
||||
using BITKit;
|
||||
using BITKit.Entities;
|
||||
using BITKit.Entities.Player;
|
||||
@@ -19,6 +20,7 @@ namespace BITFALL.Feel
|
||||
[SerializeField] private UnityEvent _unityEvent;
|
||||
[SerializeField] private UnityEvent playerDeathEvent;
|
||||
[SerializeField] private Volume vignettingVolume;
|
||||
[SerializeField] private Volume playerFlashVolume;
|
||||
[SerializeField] private AnimationCurve vignettingCurve;
|
||||
[Inject]
|
||||
private IKnockdown _knockdown;
|
||||
@@ -26,13 +28,15 @@ namespace BITFALL.Feel
|
||||
private IHealth _health;
|
||||
[Inject]
|
||||
private IPlayerMovement _playerMovement;
|
||||
|
||||
[Inject] private IStunObject _stunObject;
|
||||
private void Start()
|
||||
{
|
||||
playerService.OnPlayerInitialized += OnPlayerInitialized;
|
||||
playerService.OnPlayerDisposed += OnPlayerDisposed;
|
||||
|
||||
vignettingVolume.weight = 0;
|
||||
|
||||
playerFlashVolume.weight = 0;
|
||||
}
|
||||
|
||||
private void Update()
|
||||
@@ -63,6 +67,15 @@ namespace BITFALL.Feel
|
||||
_knockdown.OnRevive += OnRevive;
|
||||
|
||||
_health.OnSetAlive += OnSetAlive;
|
||||
|
||||
_stunObject.OnWeightChanged += OnWeightChanged;
|
||||
|
||||
playerFlashVolume.weight = 0;
|
||||
}
|
||||
|
||||
private void OnWeightChanged(float obj)
|
||||
{
|
||||
playerFlashVolume.weight= obj;
|
||||
}
|
||||
|
||||
private void OnSetAlive(bool obj)
|
||||
|
Reference in New Issue
Block a user