Repeating an AppleScript until a set timer runs out

Hello, world! (lol)

I’ve created the following program for the sole purpose of annoying and amusing my sister. Since I don’t really know much about AppleScript, I’ve only the following:

say "Small Guys says Hi!"
say "Small Guys says Hi!"
say "Small Guy says Hi!"
-- Repeat about a thousand times :)

How do I create a timer inside the AppleScript so that when it runs out, the program stops? Right now, I created one line and Cmd+V’ed it a thousand times. If I could have a 15- or 30- minute timer embedded in the program, it a) would save some space and b) I could control how long I can keep my sister busy. Thanks!

Don’t tell your sister I told you how to do this…


repeat 10 times
	say "Small Guy says Hi!"
	delay 1
end repeat

Thanks andyazone! It works fine.
Is there a way to set an actual time, though? Although if I repeat it x times ( if x is greater than, say, 500), could I have it stop after 30 minutes or 1800 seconds, etc.? Thanks!

So far:

repeat 500 times
say "Small Guy says Hi!"
end repeat

I wash my hands of this strange script …


set myMinutes to 1

set timeA to current date
repeat
	say "Small Guy says Hi!"
	delay 5
	if (((current date) - timeA) / minutes) ≥ myMinutes then exit repeat
end repeat

Thanks!
By the way, to help my noobiness along, Google Search found me this: http://files.macscripter.net/sourcebook/AS4ASb2.pdf
“AppleScript for Absolute Starters” is its title.
I’ll be reading that a lot. Thanks for the help, Adayzdone!