Code:
function talk_click2()
{
var MySound = NULL;
my.event = NULL;
if(event_type == event_click)
{
MySound = snd_play(guard, 100, 0);
}
while(MySound!=NULL && snd_playing(MySound)) wait(1);
my.event = talk_click2;
}
action click_talk2()
{
my.enable_click = on;
my.event = talk_click2;
var anim_percentage = 0;
while(1)
{
anim_percentage += 8 * time;
anim_percentage %= 100;
ent_animate(my, "stand", anim_percentage, anm_cycle);
wait(1);
}
}
BTW this is no Lite-C code.