E
EZTALES
Guest
.
Last edited by a moderator:
hey yall,
so my goal today is to when you press X, your players animation changes to another sprite to do the attack animation. i also want it to work depending on which way the player is looking. here is my code below and i keep getting two issues, one the left side isn't working and second the the animation for slide will not stop once started not really sure why. any help?
Code://attacking right if sprite_index = spr_player_R & keyboard_check_direct(ord("X")) { sprite_index = spr_player_slide_R; } //attacking left if sprite_index = spr_player_L & keyboard_check_pressed(ord("X")) { sprite_index = spr_player_slide_L; }
//attacking right
if sprite_index = spr_player_R & keyboard_check_direct(ord("X"))
{
sprite_index = spr_player_slide_R;
}
else
{
sprite_index = spr_player_R
}