mirror of
https://github.com/MaddyThorson/StrawberryBF.git
synced 2024-11-28 16:58:56 +08:00
Module.Swap to manually swap
This commit is contained in:
parent
ef5a886b3a
commit
b68ad22764
|
@ -7,6 +7,7 @@ namespace Strawberry
|
||||||
|
|
||||||
private float msCounter;
|
private float msCounter;
|
||||||
private uint32 prevTicks;
|
private uint32 prevTicks;
|
||||||
|
private bool swap;
|
||||||
|
|
||||||
public this()
|
public this()
|
||||||
{
|
{
|
||||||
|
@ -62,7 +63,7 @@ namespace Strawberry
|
||||||
// exit or swap to another module
|
// exit or swap to another module
|
||||||
if (PlatformLayer.Closed())
|
if (PlatformLayer.Closed())
|
||||||
return null;
|
return null;
|
||||||
else if (Input.KeyPressed(.F1))
|
else if (swap || Input.KeyPressed(.F1))
|
||||||
{
|
{
|
||||||
let swapTo = CreateSwapModule();
|
let swapTo = CreateSwapModule();
|
||||||
if (swapTo != null)
|
if (swapTo != null)
|
||||||
|
@ -81,5 +82,10 @@ namespace Strawberry
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void Swap()
|
||||||
|
{
|
||||||
|
swap = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user