TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

regexp question

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Script Help
View previous topic :: View next topic  
Author Message
stormdragon2976



Joined: 19 Nov 2010
Posts: 46
Location: /dev/null

PostPosted: Sun Dec 18, 2011 3:00 pm    Post subject: regexp question Reply with quote

Confused
I was reading regexp help and found that if you use %S it matches any number of nonspaces. I wanted to set a trigger for when players arrive and not when mobs. In the area I use the trigger in mobs all start with A or The. So, my action looks kind of like this:
#act {%S has arrived.$}
My understanding of this syntax is that a single word has to proceed has arrived. the action, however, is still going off when mobs walk into the room. A guard has arrived is still causing it to fire. So, am I missing something here?
Thanks
_________________
Storm
Follow me on Twitter: http://twitter.com/stormdragon2976
or on Identica: http://identi.ca/stormdragon2976
Back to top
View user's profile Send private message Visit poster's website AIM Address
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3281

PostPosted: Sun Dec 18, 2011 4:59 pm    Post subject: Reply with quote

It matches zero or more non spaces, for this to work you have to force start of line matching:

#act {^%S has arrived.$}
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Script Help All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group