|
JustMe Newbie
Joined: 16 May 2002 Posts: 8 Location: Estonia
|
Posted: Mon Jul 22, 2002 8:15 pm
%line, %line2, %line3 question |
The manual says, that %linexx gives the last(or one before last)line received from the MUD. I have found out, that %linexx also gives echo from commands.
The problem is the following:
normally, there are 2 lines of output, like this:
Somebody does this.
This happens.
i have such solution now:
i trigger ^This happens.$, then check
%line2(using =~), which should be ^Somebody does this.$
But if use any commands, like walking direction or any other, output comes:
Somebody does this.
south
This happens.
so it doesnt work like i want. Commands are not mud output, why then zmud stores it in
%linexx? I guess that messages #sa text will have the same effect.
i connect first from mud to proxy, then using telnet to zmud there. I tried turning telnet echo off, but it becomes much more slow, then with echo turned on.
But what should i do with #sa messages, they are saved in %linexx too.
Also, there should be NO other mud output between those 2 lines, i should be able to detect if there is.
Anybody could help? maybe i could configure zmud somehow, so it doesnt save #sa and commands to %linexx? Or any other solution? |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Mon Jul 22, 2002 9:48 pm |
Telnet echo is mud output. The mud is sending back what you just typed. For zMud though anything displayed to the mud output window is mud output and can be triggered off.
Now that the rant is out of the way, perhaps you would like to tell us what you actually want to do, instead of some vague request of what it might be like. For what you described now a nice timeout trigger would work.
#TR {^Somebody does this.$} {#TR "Happens" {^This happens.$} {#ECHO Happened!};#ALARM {+2} {#UNTRIGGER Happens}} |
|
|
|
JustMe Newbie
Joined: 16 May 2002 Posts: 8 Location: Estonia
|
Posted: Tue Jul 23, 2002 4:56 pm |
i'l explain what i wanna do:
output:
Somebody kicks your arm.
Your arm is broken.
There are many possibilities for line1(depending on a class and weapon), eg:
Somebody strikes your arm.
Your arm is broken.
and some other variations(i have them in a list).
But some people use emotes to make me think that arm is broken. This can be revealed in 2 ways:
1. either there's no 1 line, or
2. 1 line is a bit different(like name is more that one word).
I gotta detect if its broken or it was an emote. I could use 2-line triggers, yes, that would perfectly suit, but...
I use #sa messages alot, so it sometimes comes such an output:
Somebody kicks your arm.
message:Arm is broken
any another message
Your arm is broken.
so #sa messages separate those 2 lines, and also, normal commands from echo separate them too.
but its 100% that those 2 messages from mud come one after another. if #sa messages wouldnt be saved in %linexx, solution would be very simple.
And i should be able to detect if there was a emote attempt.
Like i understand, i must trigger the affliction message(^Your arm is broken.$), and then somehow check if previous line from mud was (^Somebody kicks your arm.$), not looking at #sa messages and commands echo. if there's no such line, then it was a fake, otherwise real.
Any suggestions? |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Tue Jul 23, 2002 5:56 pm |
#CLASS CombatDamages
#VAR BodyParts {arm|leg|head}
#VAR AttackWords {kicks|strikes}
#VAR HitBy {}
#VAR PartHit {}
#TR {^(%w) ({@AttackWords}) your ({@BodyParts}).$} {HitBy="%1";PartHit="%3";#T+ PartDamage}
#TR {^Your @PartHit is broken.$} {#ECHO Damage looks real.}
#CLASS 0
#CLASS PartDamage
#ALARM {*2} {PartHit="";HitBy="";#T- PartDamage}
#CLASS 0
You say you can already detect spoofers, and picking up both lines is part of it. Something like this just makes sense to use 2 triggers for. |
|
|
|
|
|
|
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
|
|