Re-introduce prototype code

This commit is contained in:
2024-08-23 00:39:15 -07:00
parent 8b3d1bed8a
commit 2fb0c364ca
62 changed files with 1685 additions and 187 deletions

View File

@@ -0,0 +1,26 @@
using Chickensoft.Introspection;
using Chickensoft.LogicBlocks;
namespace GameJamDungeon
{
public partial class GameLogic
{
public partial record State
{
[Meta]
public partial record Paused : State, IGet<Input.InventoryMenuButtonPressed>, IGet<Input.MiniMapButtonReleased>
{
public Paused()
{
this.OnEnter(() => Get<IGameRepo>().Pause());
this.OnExit(() => Output(new Output.SetPauseMode(false)));
}
public virtual Transition On(in Input.InventoryMenuButtonPressed input) => To<Playing>();
public virtual Transition On(in Input.MiniMapButtonReleased input) => To<Playing>();
}
}
}
}