Frees up the character to perform any action.
Example, called from attack_update.gml:
// this attack is cancellable on hit:
if (window == 3 && has_hit){
iasa_script();
}
By George — February 11, 2018
Frees up the character to perform any action.
Example, called from attack_update.gml:
// this attack is cancellable on hit:
if (window == 3 && has_hit){
iasa_script();
}
By George — February 11, 2018
Changes the character’s state to the specified attack.
Argument | Type | Description |
---|---|---|
state | :real | The attack to set |
Example, called from attack_update.gml:
// allows the player to cancel the endlag of a successful parry into Nspecial (but not other specials):
if (state == PS_PARRY && window == 2 && perfect_dodged && special_pressed) {
if !(up_down || down_down || left_down || right_down) {
set_attack( AT_NSPECIAL );
}
}
By George — February 11, 2018
Changes the character’s state.
Argument | Type | Description |
---|---|---|
state | :real | The state to set |
Example, called from attack_update.gml:
// this attack cancels into pratfall when you press the dodge button:
if (window == 3 && shield_pressed){
set_state( PS_PRATFALL );
}
By George — February 11, 2018
Returns a string of the player’s state.
Argument | Type | Description |
---|---|---|
state_index | :real | The state index to get the name of |
Example, called from debug_draw.gml:
// draws the player's state:
draw_debug_text( x, y, "state: " + get_state_name( state ));
By George — February 11, 2018
Resets can_hit properties for all hitbox groups for the current attack. Can be used for looping attack windows, so that the hitboxes can hit again.
Example, called from attack_update.gml:
if (window == 3 && window_timer == 1 && attack_down){
window = 2;
window_timer = 0;
attack_end(); //refreshes window 2's hitbox
}