How to use
To use this system – you should just:
- Create empty GameObject and add Collider(IsTrigger=true) and Rigidbody components to it
- Add Audio source if you’ll need sound FX
- Attach DoorController component and tune it as you want
- Attach door object(with Animation component) as child and set it as AnimatedObject in DoorController
- If you need combination-lock – attach CodeLock component as well and assign your Player to PlayerObject parameter
- If you want to have door unlocked by object that “know” code – attach CodeCard component to this object and specify code to door in it.