$(repeat)
- Syntax
$(repeat <count> <phrase>)- Arguments
- Required
The $(repeat) variable allows you to repeat a specified phrase multiple times in your StreamElements Chatbot messages. This can be useful for creating emphasis, generating patterns, or simply for fun interactions in chat.
Use it
Section titled “Use it”!command add !hype $(repeat 5 HYPE)The basic syntax for using the $(repeat) variable is:
$(repeat <count> <phrase>)Where <count> is the number of times you want to repeat the phrase, and <phrase> is the text you want to repeat. The repetitions are joined with single spaces.
Examples
Section titled “Examples”Using with Other Variables
Section titled “Using with Other Variables”You can combine $(repeat) with other variables:
$(repeat 2 "$(user) is awesome!")Parameters
Section titled “Parameters”The $(repeat) variable requires two parameters:
- Count: The number of times to repeat the phrase. Must be a positive integer; capped at 100.
- Phrase: The text or variable to be repeated.
Related Variables
Section titled “Related Variables”$(queryescape): Escapes text for use in URL query parameters.$(random): Generates random numbers or selects random items, which can be used with$(repeat).
Q: Is there a limit to how many times I can repeat a phrase?
A: Yes. The repeat count is capped at 100, and the total output is limited to roughly 1,000 characters — whichever is reached first.
Q: Can I use $(repeat) within other variables?
A: Yes, you can nest $(repeat) within other variables or use other variables within $(repeat).
Q: Why doesn’t my command respond at all?
A: A missing or invalid repeat count suppresses the entire response. Double-check that the first parameter is a whole number of 1 or more.