Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
xekon
Apprentice


Joined: 11 Oct 2007
Posts: 154

PostPosted: Wed Jun 17, 2009 5:39 am   

HELP, how to I do a #call with Name Like AND zone = ? THANK YOU!
 
Right now I use the following to set the mapper to set the mapfilter for perticular room Names, however I would also like to set it to a perticular room zone ID...

#CALL %mapfilter(%concat("Name LIKE '",%replace(%1, "'", "''"),"%'"))

so I need to rewrite this so that it is Name LIKE AND Zone = I tried rewriting it a couple different ways but cmud just gets stuck in a hard lock and I have to end task it, Im probably just writing it wrong, here is what I tried:

#CALL %mapfilter(%concat("Name LIKE '",%replace(%1, "'", "''"),"%'"," AND Zone ='",%replace(%2, "'", "''"),"'"))

Also when using the mapfilter to search by zone, should I be passing the zoneID or the zone name??
Reply with quote
charneus
Wizard


Joined: 19 Jun 2005
Posts: 1876
Location: California

PostPosted: Wed Jun 17, 2009 7:31 am   
 
#CALL %mapquery( [Name] Like '%replace( %1, "'", "''")%' AND [ZoneID] Like '%zonenum(%2)')

That should do what you want.

Charneus
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
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

© 2009 Zugg Software. Hosted by Wolfpaw.net