pixeltroid
Member
I have this in my players step event:
This in my keypress button:if keyboard_check(ord("F")) && health > 0 && (place_meeting(x,y+1,obj_solid))
{ pointup = true; }
else
{ pointup = false; }
if (pointup = true)
{
sprite_index = spr_pointup
}
This in my player shooting script:if (state == 'move' && pointup = true){
sprite_index = spr_pointup ;
}
Im just getting the sprite to change but the bullets still shoot sideways. How do I fix the code to shoot upwards?if (bullets > 2 && state == 'move' && pointup = true)
{
b=instance_create(x,y-30,obj_bullet);
b.speed = 9;
b.direction = 90;
}
bullets -= 1;
if (alarm[7] == -1) alarm[7] = (room_speed / 4);