timed button stand puzzle

This commit is contained in:
2023-04-12 12:18:04 +02:00
parent 7e803a5279
commit 42ef7cc9bd
22 changed files with 1145 additions and 365 deletions

View File

@@ -1,23 +1,30 @@
using Station46.Modules.Holes.Scripts;
using System;
using EscapeRoomEngine.Engine.Runtime.Modules;
using EscapeRoomEngine.Engine.Runtime.Modules.State;
using Station46.Modules.Holes.Scripts;
using Station46.Scripts;
using UnityEngine;
namespace Station46.Modules.Hoop.Scripts
{
[RequireComponent(typeof(Animator))]
public class ButtonHoop : Hole
[RequireComponent(typeof(Animator), typeof(Hole))]
public class ButtonHoop : ModuleState
{
private static readonly int PressedHash = Animator.StringToHash("Pressed");
public Hole Button { get; private set; }
private Animator _animator;
protected override void Start()
private void Awake()
{
base.Start();
_animator = GetComponent<Animator>();
Button = GetComponent<Hole>();
}
ButtonEvent += (_, type) =>
private void Start()
{
Button.ButtonEvent += (_, type) =>
{
// ReSharper disable once SwitchStatementMissingSomeEnumCasesNoDefault
switch (type)
@@ -31,5 +38,7 @@ namespace Station46.Modules.Hoop.Scripts
}
};
}
public override void SetModule(Module module) {}
}
}