Delete function

i have this function on frame 5

function playit() {
play();
}

setTimeout(playit,5000);

and i want to delete it on frame 10 how to do this try like this but nothing

delete playit();

i have a button on stage and when i press on it its paly frame 10 and thats wy i want to delete this time out,if u dont press on it in 5 secont it should play automatic

stop();
my_btn.onRelease = function() {
	clearInterval(playInterval);
	gotoAndPlay(10);
};
function playit() {
	gotoAndPlay(10);
}
playInterval = setInterval(playit, 5000);

thanks :slight_smile: thanks thanks :slight_smile: