GameMaker Touhou Engine   Home   Downloads   Documentation

_SPELL_BONUS_CONTROLLER


The object that controls the spell card bonus and draws it after a spell card is finished.


Locals:


Name Value/Default Significance
_DRAW_TRIGGER <boolean>/false true: The gained spell bonus should start being drawn. false: The current spell card has not ended yet or the player is not inside a spellcard at all.
_DRAWING <boolean>/false true: The gained spell bonus is being drawn at the time of access. false: The gained spell bonus is not being drawn at the time of access.
_SBONUS <integer>/0 The value to draw while _DRAWING.

Events:


Trigger # Actions
Create 1 Set local variables to default values. Declare global._SPELL_BONUS and global._SURVIVAL_CARD.
Alarm[0] 1 Stop drawing the gained spell card bonus.
Step 1 If the spell card bonus is positive and the ongoing card isn't a survival card, decrease the bonus, making sure it doesn't go below 0. If the gained spell bonus should start being drawn, start drawing it, set _DRAW_TRIGGER to false and Alarm[0] to an arbitrary value.
Draw 1 If drawing, draw the gained spell card bonus using _DRAW_TEXT_BORDER, drawing "BONUS FAILED" if said bonus is not higher than 0.