Add : Rtpc progression on staircase + events
This commit is contained in:
@@ -8,6 +8,7 @@ using UnityEngine;
|
||||
using UnityEngine.Events;
|
||||
using UnityEngine.InputSystem;
|
||||
using UnityEngine.Rendering.Universal;
|
||||
using static UnityEngine.Rendering.DebugUI;
|
||||
|
||||
public class SpiralStaircase : MonoBehaviour
|
||||
{
|
||||
@@ -117,7 +118,11 @@ public class SpiralStaircase : MonoBehaviour
|
||||
void Update()
|
||||
{
|
||||
if (_state.PlayerInside)
|
||||
{
|
||||
Count();
|
||||
SetRtpc();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void OnTriggerEnter(Collider col)
|
||||
@@ -208,7 +213,7 @@ public class SpiralStaircase : MonoBehaviour
|
||||
private void Count()
|
||||
{
|
||||
if (!OctoPlayer.Instance) return;
|
||||
|
||||
|
||||
Vector2[] steps = new Vector2[4] { Vector2.up, Vector2.left, Vector2.down, Vector2.right };
|
||||
Vector2 nextStep = steps[_state.Quarters % steps.Length];
|
||||
|
||||
@@ -288,4 +293,11 @@ public class SpiralStaircase : MonoBehaviour
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
//--Sound--------------
|
||||
private void SetRtpc()
|
||||
{
|
||||
float rtpcValue = _state.TotalProgression;
|
||||
AKRESULT aKRESULT = AkSoundEngine.SetRTPCValue("BinauralFREQ_Rtpc", rtpcValue);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user