Is it possible to fill the requirements of this function with variables instead of the direct sprite name?
I have a script that is called in the step event if the character is supposed to have glasses on.
This code returns a cannot draw non existing sprite in the draw event
posted below
I have a script that is called in the step event if the character is supposed to have glasses on.
Code:
var tspr
tspr[0] = sprite_duplicate(gear); //should equal spr_bifocals
tspr[1] = sprite_duplicate(curr_sprite); //should equal spr_head
sprite_merge(tspr[0], tspr[1]);
end_sprite = tspr[0];
sprite_delete(tspr[1]);
posted below
Code:
sprite_index = asset_get_index(end_sprite)
draw_self();
shader_reset();
Last edited: