Contains

True if a substring appears anywhere in a string. Case-sensitive. For a case-insensitive variant see ContainsI.

Category: String Returns: bool

Signature

Contains(haystack, needle)

The first argument is the string to search; the second is the substring to look for.

Examples

Contains(var_player_name, 'Sir')    // true if the name contains 'Sir'
Contains(var_reply, 'yes')          // exact-case yes match
!Contains(var_player_input, "@")    // gate that the input isn't an email
Docs last synced: 2026-07-18
Screenshot viewer