View Single Post
  #2  
Old 09-25-2001, 11:48 AM
BocoC BocoC is offline
Registered User
BocoC's Avatar
Join Date: Jun 2001
Location: Washington State, USA
Posts: 980
BocoC is on a distinguished road
Send a message via AIM to BocoC Send a message via Yahoo to BocoC
Re: tokenizing test ...

Quote:
Originally posted by nyghtGT
would this be correct ?

if (playerchats && startswith(jail player,#c) && strequals(#g,GP)) {tokenize #c;
setstring server.jailaccount,#t(3);
}
Nope. #t(n) starts at zero. jail is #t(0), player is #t(1), and the player name is #t(2). So:
NPC Code:

if (playerchats && startswith(jail player,#c)) {
if (strequals(#g,GP)) {
tokenize #c;
setstring server.jailaccount,#t(2);
}
}

__________________
-Boco

FLKJH$TRFG*$(&%>FMG >REN<>F ;.kjsd
Reply With Quote