Almondspace197
Member
___________________________________________
############################################################################################
ERROR in
action number 1
of Create Event
for object <undefined>:
Variable <unknown_object>.sprite_index(25, -2147483648) not set before reading it.
at gml_GlobalScript_playerAnimateSprite (line 3) - var _totalFrames = sprite_get_number(sprite_index)/ 4;
############################################################################################
gml_GlobalScript_playerAnimateSprite (line 3)
this is The error i am getting.
//Upate Sprite
var _cardinalDirection = round(90);
var _totalFrames = sprite_get_number(sprite_index)/ 4;
image_index = localFrame + (_cardinalDirection * _totalFrames);
localFrame += sprite_get_speed(sprite_index)/ FRAME_RATE;
//If Animation Woud Loop on Next Game Step
if (localFrame >= _totalFrames)
{
animationEnd = true;
localFrame -= _totalFrames;
} else animationEnd = false;
this is the file its giving error for ig. I have just started using gml, i used to work with dnd earlier.
############################################################################################
ERROR in
action number 1
of Create Event
for object <undefined>:
Variable <unknown_object>.sprite_index(25, -2147483648) not set before reading it.
at gml_GlobalScript_playerAnimateSprite (line 3) - var _totalFrames = sprite_get_number(sprite_index)/ 4;
############################################################################################
gml_GlobalScript_playerAnimateSprite (line 3)
this is The error i am getting.
//Upate Sprite
var _cardinalDirection = round(90);
var _totalFrames = sprite_get_number(sprite_index)/ 4;
image_index = localFrame + (_cardinalDirection * _totalFrames);
localFrame += sprite_get_speed(sprite_index)/ FRAME_RATE;
//If Animation Woud Loop on Next Game Step
if (localFrame >= _totalFrames)
{
animationEnd = true;
localFrame -= _totalFrames;
} else animationEnd = false;
this is the file its giving error for ig. I have just started using gml, i used to work with dnd earlier.