mirror of
https://github.com/RHeavenStudioPlus/HeavenStudioPlus.git
synced 2024-11-08 18:55:07 +00:00
Trick on the class: Speech Bubble Toggle (#329)
* Trick on the class Speech Bubble toggle * fixed tiny lil' bug
This commit is contained in:
parent
0b5faa3753
commit
94fdf7fa8d
1 changed files with 17 additions and 3 deletions
|
@ -31,12 +31,17 @@ namespace HeavenStudio.Games.Loaders
|
|||
},
|
||||
defaultLength = 3,
|
||||
},
|
||||
new GameAction("toggleBubble", "Toggle Speech Bubble")
|
||||
{
|
||||
function = delegate { TrickClass.instance.BubbleToggle(); },
|
||||
defaultLength = 1,
|
||||
},
|
||||
new GameAction("bop", "")
|
||||
{
|
||||
function = delegate { var e = eventCaller.currentEntity; TrickClass.instance.Bop(e.beat, e.length); },
|
||||
resizable = true,
|
||||
hidden = true
|
||||
},
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -86,6 +91,7 @@ namespace HeavenStudio.Games
|
|||
public float playerCanDodge = Single.MinValue;
|
||||
float playerBopStart = Single.MinValue;
|
||||
float girlBopStart = Single.MinValue;
|
||||
bool showBubble = true;
|
||||
|
||||
|
||||
void OnDestroy()
|
||||
|
@ -154,13 +160,20 @@ namespace HeavenStudio.Games
|
|||
bop.length = length;
|
||||
}
|
||||
|
||||
public static void PreTossObject(float beat, int type)
|
||||
public void BubbleToggle()
|
||||
{
|
||||
instance.showBubble = !instance.showBubble;
|
||||
}
|
||||
|
||||
public static void PreTossObject(float beat, int type)
|
||||
{
|
||||
if (GameManager.instance.currentGame == "trickClass")
|
||||
{
|
||||
BeatAction.New(instance.gameObject, new List<BeatAction.Action>()
|
||||
{
|
||||
new BeatAction.Action(beat - 1, delegate
|
||||
{
|
||||
if (instance.showBubble == true)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
|
@ -171,7 +184,8 @@ namespace HeavenStudio.Games
|
|||
instance.warnAnim.Play("WarnPlane", 0, 0);
|
||||
break;
|
||||
}
|
||||
}),
|
||||
}
|
||||
}),
|
||||
new BeatAction.Action(beat, delegate
|
||||
{
|
||||
instance.warnAnim.Play("NoPose", 0, 0);
|
||||
|
|
Loading…
Reference in a new issue