Hi there. This is my script...what It does is is animate and on click of model talk. After it has run it wont work again. so if i click the model again it doesnt work. Any ideas what to do. thanks ^^


function talk_click2 () //script for my click on blacksmith guard on left of gate
{
my.event = null;//i put this line in so it could only be said once
if(event_type == event_click)
{
me= null;
wait(1);

snd_play (guard1, 100, 0);
}wait(1);
}


action click_talk2
{
my.enable_click = on;
my.event = talk_click2;
{ var counter = 0;
var c=0;
var anim_percentage = 0;

while (c<1000)
{ wait (1);
c+=1;
counter += time / 50; // add "1" to counter every second
anim_percentage += 8 * time;
ent_animate(my, "stand", anim_percentage, anm_cycle); // play the "stand" animation
}
}
}