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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
Seth_Aetolia
Newbie


Joined: 03 Dec 2006
Posts: 5
Location: Townsville, Australia

PostPosted: Sun Dec 03, 2006 11:56 pm   

Wildcards and pattern matching for C-Mud
 
I've been testing out C-mud for the last few days and I've come across a small problem with comparing the triggers that I use in Z-mud to this new set-up.

The mud I play (Aetolia) has a pre-set 80 character limit before using its own word wrap system so I've used $ to enable multiple line triggers.

The problem is, with C-mud that the $ symbol is used for local variables and doesn't do the same pattern matching that I'm used to with Z-mud.

I've gone through the C-mud help system and searched through the forums but it seems that the pages for the new wildcards and pattern matching symbols hasn't been created yet so I have no idea on what to use for this purpose under the new system.

Also, I have to admit that the file for using local variables is currently pointless as it displays no examples of use and no feasible information at all.

Not wanting to sound like a professional complainer or anything, but wouldn't it have been more logical to have those help sections filled out before expecting people to test them?

Anyways, any info is greatly appreciated.

-Seth
Reply with quote
crycry
Apprentice


Joined: 24 Jun 2006
Posts: 169
Location: UK - South Coast

PostPosted: Mon Dec 04, 2006 12:00 am   
 
if you run the compatability check in tools on all your scripts, it should pretty well flag up anything that needs changing.. youll also find alot of info on converting existing scripts here.
http://forums.zuggsoft.com/modules/mx_kb/kb.php?mode=doc&index=cmud_zmud&page=3&refpage=

if that still doesnt work, and your really stuck repost

as cMud is still BETA, youll find that the helpfiles arent complete yet.. when cMud goes alpha release, itll all be updated.
_________________
'Life is what happens, when your too busy doing something else'

_________________

XP Pro SP2
cMud 1.24
_________________
Reply with quote
Seth_Aetolia
Newbie


Joined: 03 Dec 2006
Posts: 5
Location: Townsville, Australia

PostPosted: Mon Dec 04, 2006 12:40 am   
 
Champion. Thanks for that.
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Mon Dec 04, 2006 12:49 am   
 
$ should still be matching the end of lines. The syntax for named wildcards is ($localvar:%wildcard) and that's the only time they make a difference in trigger patterns. So anyway, I created a trigger to test this:

#trig {This is a test trigger. When it gets to 80 characters, I'm going to word wrap it$like this and see how it goes.} {#echo Fired!}

Then, from the command line I do "#echo This is a test trigger. When it gets to 80 characters, I'm going to word wrap it;#echo like this and see how it goes." and it works just fine. Regardless, there's a better way to do this:

#trig {This is a test trigger. When it gets to 80 characters, I'm going to word wrap it} {}
#cond {like this and see how it goes.} {#echo Fired!} {Within|Param=1}

The second trigger state will only fire if it's within one line of the first trigger state, which is exactly the same but avoids that nasty $ syntax altogether.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Seth_Aetolia
Newbie


Joined: 03 Dec 2006
Posts: 5
Location: Townsville, Australia

PostPosted: Mon Dec 04, 2006 12:54 am   
 
Thanks, Fang. I love examples.
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Mon Dec 04, 2006 1:05 am   
 
Incidentally, all the Iron Realms MUDs were updated at some point (or at least Achaea, Imperian and Lusternia were) to let you set your line length. Pretty useful since CMUD triggers work on the mud's line length, not on CMUD's word wrap length. So you can CONFIG SCREENWIDTH 0 or whatever the command is, and then have CMUD wrap to whatever you like and never have to bother with this nonsense. Or at least you could if CMUD was word wrapping, which it doesn't seem to be. Separate report forthcoming.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Seth_Aetolia
Newbie


Joined: 03 Dec 2006
Posts: 5
Location: Townsville, Australia

PostPosted: Mon Dec 04, 2006 2:53 am   
 
Hmm, I'm not sure about the other IRE muds but on Aetolia you can only config your page length.

Quote:
Pagelength is the maximum number of lines that will be displayed to you at
once. This is useful when your client does not have a scrollback buffer or you
wish to artificially limit it. If you want to have more displayed, set a higher
number. (Max: 250, Default: 20)


Think this is because of Rapture though.
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Mon Dec 04, 2006 9:59 am   
 
Well, on the others you can DEFINITELY set your screenwidth. I know this because I've rewritten my systems to use screenwidth 0 for that exact reason. I guess Aetolia is slow updating :(
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum 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