arrow wall obeys to the freeze ability

This commit is contained in:
Novvator 2021-04-06 14:25:53 +01:00
parent fffb50a6a2
commit 203b2e9c82
1 changed files with 4 additions and 1 deletions

View File

@ -1,3 +1,4 @@
using Ktyl.Util;
using System;
using System.Collections;
using System.Collections.Generic;
@ -14,6 +15,8 @@ public class ArrowWall : MonoBehaviour
private float? _triggered = null;
[SerializeField] private SerialFloat objectTimeScale;
public void Trigger()
{
// TODO: pressure plate 'click' sound
@ -29,7 +32,7 @@ public class ArrowWall : MonoBehaviour
var elapsed = Time.time - _triggered.Value;
// TODO: implications for time freeze
if (elapsed > _delay)
if (elapsed > _delay && objectTimeScale!=0)
{
// TODO: arrow whoosh noises