View Single Post
  #3  
Old 03-02-2003, 08:23 PM
Torankusu Torankusu is offline
Elite Member
Torankusu's Avatar
Join Date: Jun 2001
Posts: 10,065
Torankusu is a jewel in the roughTorankusu is a jewel in the rough
Quote:
Originally posted by AlexH
Use

if (playerchats&&strequals(#c,text)) {
stuff;
}

Instead of playersays.
Example using your (melissa-whatever's) code:

NPC Code:

if (playertouchsme){
message Welcome to my room!;
sleep 3;
message Do you like punk?;
sleep 3;
if (playerchats && strequals(#c,yes)) {message Really? I LOVE punk!;
sleep 3;
message You got any liquor?;
sleep 3;
}
}


#c = chat, in case you didn't know.

strequals is really useful, as is strcontains and other things with "str" in them. I recommend looking them up and learning more about them. Check in newfeatures also. There are some pretty new commands there.
Reply With Quote