Jak zrobic zeby np. jesli zmienna siedzi = false to mozna chodzic bohaterem a jesli siedzi = true to juz nie mozna
Dalem tak ale ...
GML
direction = point_direction( x , y , mouse_x , mouse_y )
image_angle = direction
if ( point_distance( x , y , mouse_x , mouse_y ))
{
s = 5
if( keyboard_check( ord('A')))
{
x += lengthdir_x( s, direction + 90 );
y += lengthdir_y( s, direction + 90 );
}
else
if( keyboard_check( ord( 'D' )))
{
x += lengthdir_x( s, direction - 90 );
y += lengthdir_y( s, direction - 90 );
}
if ( keyboard_check( ord( 'W' )))
{
if ( keyboard_check( vk_shift )) speed = 8
else
speed = 3
}
else
if ( keyboard_check( ord( 'S' ))) speed = -2
else
speed = 0
}
else
speed = 0
else
if (na_fotelu = true)
{
speed = 0
}
///obsługa sprita
if ( speed <> 0 ) image_speed = 0.25
else
{
speed = 0
image_index = 0
}
wystepuje blad
a jak skasuje else z 32 lini to wystepuje taki blad