Author |
Message |
Topic: Does %regex expand @regexPattern? |
veek
Replies: 1
Views: 1477
|
Forum: zMUD General Discussion Posted: Fri Dec 15, 2006 2:35 pm Subject: Does %regex expand @regexPattern? |
#TRIGGER matchRoom {.+?\[(.+)\]} {#COLOR Red; okayToWalk=1; #VAR roomContentsLst ""; #TEMP {Hp:.+} {#COLOR Yellow; #STATE matchRoom 0;} "" {regex|prompt}} "" {regex|disable}
#COND {} {#COLOR Green; # ... |
Topic: Does %regex expand @regexPattern? |
veek
Replies: 1
Views: 1477
|
Forum: zMUD General Discussion Posted: Fri Dec 15, 2006 8:37 am Subject: Does %regex expand @regexPattern? |
Hello, I'm trying to do: userInRoom=%regex(@roomContents, @users)
Where roomContents = "something, something, something" and users="Sandra|Harry|Chooch|Whatever"
This does not work because @users ... |
Topic: Breaking or returning from a ALIAS. (return?) |
veek
Replies: 2
Views: 2037
|
Forum: zMUD General Discussion Posted: Thu Nov 23, 2006 4:59 am Subject: Breaking or returning from a ALIAS. (return?) |
I've pasted the whole code. ABORT does not break out of the FORALL :(. Perhaps there is some other way to code this.
I'm trying to process a list of rooms. Enter a room, check if there are pechs. Kil ... |
Topic: Breaking or returning from a ALIAS. (return?) |
veek
Replies: 2
Views: 2037
|
Forum: zMUD General Discussion Posted: Wed Nov 22, 2006 9:28 am Subject: Breaking or returning from a ALIAS. (return?) |
#ALIAS WalkAroundVillage {
#FORALL @pechRoomList {
WalkToRoom/Main %i
#WHILE (!@moved) {#WAIT 2000}
moved = 0
#WHILE (@pechInRoom) { #IF (@_noCombat = 1) {#WALK 504; ... |
Topic: zMUD equivalent of a C/Perl Function. |
veek
Replies: 8
Views: 4591
|
Forum: zMUD General Discussion Posted: Fri Nov 17, 2006 8:09 am Subject: zMUD equivalent of a C/Perl Function. |
Thanks guys! Umm, actually i'm just a noob programmer in college etc and not even in Comp Sci, so maybe that's why i found it confusing..anyway thank you. It's clear now!! And i do appreciate all the ... |
Topic: Commenting code and Importing settings into zMUD. |
veek
Replies: 3
Views: 2351
|
Forum: zMUD General Discussion Posted: Fri Nov 17, 2006 8:02 am Subject: Commenting code and Importing settings into zMUD. |
Thanks Matt and Vitae. Doh! The UNCLASS thing should have occured to me. |
Topic: zMUD equivalent of a C/Perl Function. |
veek
Replies: 8
Views: 4591
|
Forum: zMUD General Discussion Posted: Wed Nov 15, 2006 3:19 pm Subject: zMUD equivalent of a C/Perl Function. |
Thanks for the Help Matt, but what i meant was like so:
#CLASS {Blah}
#VAR MyVar 5
#TRIGGER {^.+$} {#VAR MyVar 10}
#TRIGGER {^.+$} {/Blah/MyVar abcd} ; Which variable is bein ... |
Topic: Commenting code and Importing settings into zMUD. |
veek
Replies: 3
Views: 2351
|
Forum: zMUD General Discussion Posted: Wed Nov 15, 2006 2:44 pm Subject: Commenting code and Importing settings into zMUD. |
How come the docs make no mention of how whitespace is handled and how do i comment code!!
Anyway! I tried something like so:
#CLASS {Blah}
#VAR poo {}
#ALIAS goo {}
#CLAS ... |
Topic: zMUD equivalent of a C/Perl Function. |
veek
Replies: 8
Views: 4591
|
Forum: zMUD General Discussion Posted: Wed Nov 15, 2006 2:27 am Subject: zMUD equivalent of a C/Perl Function. |
Thanks, the code is looking reasonably pretty. Is the context in which variables exist explained anywhere - Variable scope when used within a CLASS, FUNCTION, TRIGGER, ALIAS? Also, about #REGEX.. with ... |
Topic: Calling a ALIAS from another class and waiting for a REGEX. |
veek
Replies: 0
Views: 1087
|
Forum: zMUD General Discussion Posted: Tue Nov 14, 2006 5:59 pm Subject: Calling a ALIAS from another class and waiting for a REGEX. |
Any idea how i can call a ALIAS in WalkToRoom from HealByWiggly.
I cannot use WalkToRoom/Main (at least on the cmd line) because if WalkToRoom has variables with the same name as HealByWiggly then th ... |
Topic: zMUD equivalent of a C/Perl Function. |
veek
Replies: 8
Views: 4591
|
Forum: zMUD General Discussion Posted: Tue Nov 14, 2006 3:46 am Subject: zMUD equivalent of a C/Perl Function. |
I am trying to write a re-useable chunk off code in zMUD that is self-contained. In Perl i'd do something like this:
sub FatalError( $ ) {
print STDERR "$progname: @_\n";
exit(1);
}
... |
Topic: Perl Regex/zMUD - matching a multiline string |
veek
Replies: 2
Views: 2308
|
Forum: zMUD General Discussion Posted: Mon Oct 09, 2006 6:28 pm Subject: Perl Regex/zMUD - matching a multiline string |
7. Err..also Lets say i use the Editor to create some Functions - how do i now put that into zMUD? Is there some place where i can store all my functions (a central repository) and then just reuse the ... |
Topic: Perl Regex/zMUD - matching a multiline string |
veek
Replies: 2
Views: 2308
|
Forum: zMUD General Discussion Posted: Mon Oct 09, 2006 6:25 pm Subject: Perl Regex/zMUD - matching a multiline string |
5. Also how do i do something like #SEND say %ansi(brown)Booo!
6. I use #WIN CHAT %1 to send the text to the CHAT window. Now to scroll up i have to click in that (ideally i'd like to just Ctrl 1 a ... |
Topic: Perl Regex/zMUD - matching a multiline string |
veek
Replies: 2
Views: 2308
|
Forum: zMUD General Discussion Posted: Mon Oct 09, 2006 6:08 pm Subject: Perl Regex/zMUD - matching a multiline string |
How do i match something like this:
Valev asks you: I am merely curious, what type of weapons do you intend
<lots of spaces>to focus on using?
It's a multiline string and i don't want to us ... |
Topic: Pattern matching ANSI enclosed string, tick timers etc. |
veek
Replies: 1
Views: 1948
|
Forum: zMUD General Discussion Posted: Wed Oct 04, 2006 8:14 am Subject: Pattern matching ANSI enclosed string, tick timers etc. |
Okay, i got fed up with mudding so consider this question closed! Thanks for the help (in the previous questions though!) |
Topic: Pattern matching ANSI enclosed string, tick timers etc. |
veek
Replies: 1
Views: 1948
|
Forum: zMUD General Discussion Posted: Tue Oct 03, 2006 11:27 am Subject: Pattern matching ANSI enclosed string, tick timers etc. |
On New Moon, The room exits "There are four obvious exits: north, east, west and up." is in Green.
1.
When mapping, i wanted to know if it was possible to pattern match on ANSI. The reason i want t ... |
Topic: Deleting a string in the description across all rooms. |
veek
Replies: 2
Views: 1757
|
Forum: zMUD General Discussion Posted: Mon Oct 02, 2006 6:44 am Subject: Deleting a string in the description across all rooms. |
Is there a way to move by room title only..or ignore the whole thing and just move - In follow mode the instructions are sent and i invariably arrive at the right destination but the blue dot does not ... |
Topic: Deleting a string in the description across all rooms. |
veek
Replies: 2
Views: 1757
|
Forum: zMUD General Discussion Posted: Mon Oct 02, 2006 6:35 am Subject: Deleting a string in the description across all rooms. |
I have mapped a city and now find that most of the room descriptions have lines like: "The air is very cold, with dense cloud cover." that change within 24 hours. I'd like to delete this line in all m ... |
Topic: Newbie - Automapping with changing room description. |
veek
Replies: 2
Views: 1877
|
Forum: zMUD General Discussion Posted: Thu Sep 28, 2006 7:29 am Subject: Newbie - Automapping with changing room description. |
Thanks Matt - It's working great now! |
Topic: Backing up my map work. |
veek
Replies: 1
Views: 1193
|
Forum: zMUD General Discussion Posted: Thu Sep 28, 2006 7:28 am Subject: Backing up my map work. |
Is there a fail safe way to backup my map work? How? I tried exporting to a text file but the file wasn't created..I don't want to change the DB fileName, just backup my data. |
Topic: Newbie - Automapping with changing room description. |
veek
Replies: 2
Views: 1877
|
Forum: zMUD General Discussion Posted: Thu Sep 28, 2006 2:56 am Subject: Newbie - Automapping with changing room description. |
Hello, I am MUD'ing on NEW MOON. At one location the room description changes by one word and the auto-map/speedwalk feature breaks. Is there a way to setup a regex or a points system such that if the ... |
|