View Single Post
  #6  
Old 12-06-2001, 01:00 PM
Saga2001 Saga2001 is offline
Wishing he had 3 feet
Join Date: Aug 2001
Location: Basement
Posts: 1,565
Saga2001 is on a distinguished road
Send a message via ICQ to Saga2001 Send a message via AIM to Saga2001 Send a message via Yahoo to Saga2001
ok...

NPC Code:

// assume the player says "you are a carrot, *flinch*"
if (playerchats) {
tokenize #c;
/*
this cuts up the line "you are a carrot, *flinch*" into a new string at every space and comma. so it is:
#t(0) = you
#t(1) = are
#t(2) = a
#t(3) = carrot
#t(4) = *flinch*
meaning no only does it break at every space and comma it also cuts them.
*/

// Now strequals()
if (strequals(Owner,#a)&&strequals(#a,Owner)) {
/*
since it is making sure the two strings equal each other the two strings are interchangible.
*/
if (strequals(#t(0),you)&&strequals(#t(1),are)&&streq uals(#t(2),a)&&strequals(#t(3),carrot)) {
showimg 201,@Yesh i am,20,120;
changeimgvis 201,4;
}
}
}



hope this helped, e-mail me: [email protected] if u have ne further questions.
__________________

!Wan ( 11:27:55 AM):
can i c ur scripts please?
Zorg (RC): If I hear NPC Server call Ne0, Past Austin or Brent sexy one more time im disconnecting it
Reply With Quote