View Single Post
  #2  
Old 06-22-2006, 07:03 PM
JustBreathe JustBreathe is offline
Registered User
Join Date: Jun 2006
Posts: 59
JustBreathe is on a distinguished road
Quote:
Originally Posted by Omini
How do I do

NPC Code:
if (strcontains(,)) { }



in GS2? I checked the basic scripting page and it's not there...



Can anyone help me out?
PHP Code:
function containsstrStackstrNeedle )
  { 
// Usage: container( this.var, "foo" );
  
for ( 0strStack.length() - strNeedle.length(); ++ )
    if ( 
strStack.substringistrNeedle.length()) == strNeedle)
      return 
true;
  return 
false;
  } 
Reply With Quote