Thread: $text question
View Single Post
  #2  
Old 04-07-2011, 05:48 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

Yes, it is possible. You can use the $text variable and input it into a quest command just like any other variable that you may have created. Though, you will most likely want to add a filter on the text they enter to prevent them from adding special characters and such. If you search google for regular expression and perl and look for the regex to filter out all but letters, you can then set whatever you want as long as there is a quest command/object for it. You will also want to add in checks to make sure they aren't just hailing the NPC or using one of its other prompt key words (IE. if ($text !~ /Hail/i)).
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote