Looking-Glass/Assets/scripts/Unlocker.cs

16 lines
403 B
C#
Raw Normal View History

2024-02-27 19:03:50 +01:00
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
// when Unlock() is called, sets locked to false for all attached Lockables
public class Unlocker : MonoBehaviour
{
public List<Lockable> attachedLockables = new List<Lockable>();
public void Unlock(){
foreach(Lockable lockable in attachedLockables){
lockable.locked = false;
}
}
}