* munchy monk input + mustache fixes
* fork lifter and pajama party bopping
* meat grinder miss bop fix
* cloud monkey Real
* marching orders Go! was broken
* force march doesn't break when it's too early from a game switch
* you can use the March! block without the marching now
This commit is contained in:
AstrlJelly
2023-06-10 15:18:45 -04:00
parent c5f5b6d800
commit faf3fbf97c
40 changed files with 4253 additions and 2766 deletions

View File

@ -14,36 +14,58 @@ namespace HeavenStudio.Games.Loaders
public static Minigame AddGame(EventCaller eventCaller) {
return new Minigame("pajamaParty", "Pajama Party", "fc9ac3", false, false, new List<GameAction>()
{
new GameAction("bop", "Bop")
{
function = delegate { var e = eventCaller.currentEntity; PajamaParty.instance.Bop(e.beat, e.length, e["bop"], e["autoBop"]); },
parameters = new List<Param>()
{
new Param("bop", true, "Keep Bopping", "Should Mako and the monkeys bop for the duration of the block?"),
new Param("autoBop", false, "Keep Bopping (Auto)", "Should Mako and the monkeys bop indefinitely?"),
},
resizable = true,
},
// both same timing
new GameAction("jump (side to middle)", "Side to Middle Jumps")
{
function = delegate {PajamaParty.instance.DoThreeJump(eventCaller.currentEntity.beat);},
function = delegate { PajamaParty.instance.DoThreeJump(eventCaller.currentEntity.beat); },
defaultLength = 4f,
inactiveFunction = delegate {PajamaParty.WarnThreeJump(eventCaller.currentEntity.beat);}
inactiveFunction = delegate { PajamaParty.WarnThreeJump(eventCaller.currentEntity.beat); }
},
new GameAction("jump (back to front)", "Back to Front Jumps")
{
function =delegate {PajamaParty.instance.DoFiveJump(eventCaller.currentEntity.beat);},
function =delegate { PajamaParty.instance.DoFiveJump(eventCaller.currentEntity.beat); },
defaultLength = 4f,
inactiveFunction = delegate {PajamaParty.WarnFiveJump(eventCaller.currentEntity.beat);}
inactiveFunction = delegate { PajamaParty.WarnFiveJump(eventCaller.currentEntity.beat); }
},
//idem
new GameAction("slumber", "Slumber")
{
function = delegate {var e = eventCaller.currentEntity; PajamaParty.instance.DoSleepSequence(e.beat, e["toggle"], e["type"]);},
function = delegate { var e = eventCaller.currentEntity; PajamaParty.instance.DoSleepSequence(e.beat, e["toggle"], e["type"]); },
defaultLength = 8f,
parameters = new List<Param>()
{
new Param("type", PajamaParty.SleepType.Normal, "Sleep Type", "Type of sleep action to use"),
new Param("toggle", false, "Alt. Animation", "Use an alternate animation for Mako")
},
inactiveFunction = delegate {var e = eventCaller.currentEntity; PajamaParty.WarnSleepSequence(e.beat, e["toggle"], e["type"]);}
inactiveFunction = delegate { var e = eventCaller.currentEntity; PajamaParty.WarnSleepSequence(e.beat, e["toggle"], e["type"]); }
},
new GameAction("throw", "Throw Pillows")
{
function = delegate {PajamaParty.instance.DoThrowSequence(eventCaller.currentEntity.beat);},
function = delegate { PajamaParty.instance.DoThrowSequence(eventCaller.currentEntity.beat); },
defaultLength = 8f,
inactiveFunction = delegate {PajamaParty.WarnThrowSequence(eventCaller.currentEntity.beat);}
inactiveFunction = delegate { PajamaParty.WarnThrowSequence(eventCaller.currentEntity.beat); }
},
new GameAction("instant slumber", "Instant Slumber")
{
function = delegate { var e = eventCaller.currentEntity; PajamaParty.instance.DoInstantSleep(e.beat + e.length - 1, e["type"]); },
defaultLength = 0.5f,
inactiveFunction = delegate { var e = eventCaller.currentEntity; PajamaParty.WarnInstantSleep(e.beat, e.length, e["type"]); },
resizable = true,
parameters = new List<Param>()
{
new Param("type", PajamaParty.SleepType.Normal, "Sleep Type", "Type of sleep action to use"),
},
priority = 5,
},
// todo cosmetic crap
// background stuff
@ -79,9 +101,11 @@ namespace HeavenStudio.Games
static float WantFiveJump = Single.MinValue;
static float WantThrowSequence = Single.MinValue;
static float WantSleepSequence = Single.MinValue;
static float WantInstantSleep = Single.MinValue;
static bool WantSleepType = false;
static int WantSleepAction = (int) PajamaParty.SleepType.Normal;
static int WantInstantSleepAction = (int) PajamaParty.SleepType.Normal;
public enum SleepType {
Normal,
NoAwake,
@ -151,6 +175,32 @@ namespace HeavenStudio.Games
DoSleepSequence(WantSleepSequence, WantSleepType, WantSleepAction, false);
WantSleepSequence = Single.MinValue;
}
if (WantInstantSleep != Single.MinValue)
{
DoInstantSleep(WantInstantSleep, WantInstantSleepAction);
WantInstantSleep = Single.MinValue;
}
}
public void Bop(float beat, float length, bool doesBop, bool autoBop)
{
void Bops(bool bop) {
Mako.shouldBop = bop;
for (int y = 0; y < 5; y++) {
for (int x = 0; x < 5; x++) {
if (!(y == 0 && x == 2)) monkeys[x, y].shouldBop = bop;
}
}
}
Bops(autoBop || doesBop);
if (!autoBop && doesBop) {
BeatAction.New(gameObject, new List<BeatAction.Action>() {
new BeatAction.Action(beat + length, delegate {
Bops(false);
})
});
}
}
public void DoThreeJump(float beat, bool doSound = true)
@ -222,8 +272,8 @@ namespace HeavenStudio.Games
public static void WarnFiveJump(float beat)
{
MultiSound.Play(new MultiSound.Sound[] {
new MultiSound.Sound("pajamaParty/five1", beat),
MultiSound.Play(new MultiSound.Sound[] {
new MultiSound.Sound("pajamaParty/five1", beat),
new MultiSound.Sound("pajamaParty/five2", beat + 0.5f),
new MultiSound.Sound("pajamaParty/five3", beat + 1f),
new MultiSound.Sound("pajamaParty/five4", beat + 1.5f),
@ -240,8 +290,8 @@ namespace HeavenStudio.Games
BeatAction.New(Mako.Player, new List<BeatAction.Action>()
{
new BeatAction.Action( beat + 2f, delegate { MonkeyCharge(beat + 2f); } ),
new BeatAction.Action( beat + 3f, delegate { MonkeyThrow(beat + 3f); } ),
new BeatAction.Action(beat + 2f, delegate { MonkeyCharge(beat + 2f); } ),
new BeatAction.Action(beat + 3f, delegate { MonkeyThrow(beat + 3f); } ),
});
}
@ -267,7 +317,6 @@ namespace HeavenStudio.Games
public void DoSleepSequence(float beat, bool alt = false, int action = (int) PajamaParty.SleepType.Normal, bool doSound = true)
{
var cond = Conductor.instance;
Mako.StartSleepSequence(beat, alt, action);
MonkeySleep(beat, action);
if (doSound)
@ -294,6 +343,35 @@ namespace HeavenStudio.Games
WantSleepAction = action;
}
public void DoInstantSleep(float deslumber, int action)
{
Mako.anim.Play("MakoSleepJust", -1, 1);
for (int y = 0; y < 5; y++) {
for (int x = 0; x < 5; x++) {
if (!(y == 0 && x == 2)) monkeys[x, y].anim.Play("MonkeySleep02", -1, 1);
}
}
if (action == 1) return;
BeatAction.New(gameObject, new List<BeatAction.Action>() {
new BeatAction.Action(deslumber, delegate {
Mako.anim.DoScaledAnimationAsync("MakoAwake", 0.5f);
Jukebox.PlayOneShotGame("pajamaParty/siestaDone");
for (int y = 0; y < 5; y++) {
for (int x = 0; x < 5; x++) {
if (!(y == 0 && x == 2)) monkeys[x, y].anim.DoScaledAnimationAsync("MonkeyAwake", 0.5f);
}
}
}),
});
}
public static void WarnInstantSleep(float beat, float length, int action)
{
WantInstantSleep = beat + length - 1;
WantInstantSleepAction = action;
}
public void DoBedImpact()
{
Bed.GetComponent<Animator>().Play("BedImpact", -1, 0);