fix session being stopped before puzzle measured
This commit is contained in:
@@ -54,14 +54,6 @@ namespace EscapeRoomEngine.Engine.Runtime.Modules
|
||||
protected virtual void Start()
|
||||
{
|
||||
OnPuzzleEvent(PuzzleEventType.Restarted);
|
||||
|
||||
PuzzleEvent += (_, type) =>
|
||||
{
|
||||
if (type == PuzzleEventType.Solved)
|
||||
{
|
||||
Measure.Solve((PuzzleModuleDescription)Module.description);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private void OnPuzzleEvent(PuzzleEventType type)
|
||||
|
||||
@@ -59,6 +59,8 @@ namespace EscapeRoomEngine.Engine.Runtime
|
||||
{
|
||||
if (type == PuzzleEventType.Solved)
|
||||
{
|
||||
Measure.Solve((PuzzleModuleDescription)puzzle.description);
|
||||
|
||||
if (LastRoom)
|
||||
{
|
||||
GameControl.Instance.StopGame();
|
||||
|
||||
Reference in New Issue
Block a user