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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
FiendishX
Wanderer


Joined: 19 Nov 2005
Posts: 53

PostPosted: Sat Jul 12, 2008 8:59 pm   

detect zmud color settings
 
Is there a way to detect (and change) what color settings zmud is using? (vt100, ansi, windows, user defined)
Reply with quote
Fang Xianfu
GURU


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

PostPosted: Sat Jul 12, 2008 9:24 pm   
 
From the server, or yourself? All the options are configurable in the settings - VT100 and ANSI emulation are both toggleable there. The default is ANSI emulation, but the user can change which colours are associated with which ANSI codes.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
FiendishX
Wanderer


Joined: 19 Nov 2005
Posts: 53

PostPosted: Sat Jul 12, 2008 9:52 pm   
 
From a script.
The default seems to be VT100, not ANSI.
If it were ANSI I probably wouldn't be asking this question. The reason for asking is that I have a script that works fine when zmud is set to ANSI but doesn't work when set to VT100 (yeah, I know. I'm working on making it not matter.). And I just thought that it'd be really nice to be able to determine what the client settings are.
Reply with quote
Fang Xianfu
GURU


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

PostPosted: Sat Jul 12, 2008 10:30 pm   
 
...it shouldn't matter, so if you could show us the script that'd help.

Afaik there's no way to do this in zMUD, because zMUD doesn't have the %pref function.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
FiendishX
Wanderer


Joined: 19 Nov 2005
Posts: 53

PostPosted: Sat Jul 12, 2008 10:41 pm   
 
I know it shouldn't matter. But the ansi codes that I receive from the mud appear to be different depending on which scheme I have set.

For instance...
an ansi trigger with the pattern ^(~|*~|)$ will pick up certain colored lines received while ANSI is set, but not while VT100 is set.
To catch them with VT100 you have to remove the ^ or add in %e[37m because the line actually begins with that code in VT100 mode but maybe it gets ignored in ANSI mode.

That is trivial to change in the script so that it works both ways, but it is an example of where the different schemes make a difference.

There is another issue somewhere that's causing another problem. Once I figure out what the code is that's causing the problem, I'll post again in the thread to show you.
Reply with quote
FiendishX
Wanderer


Joined: 19 Nov 2005
Posts: 53

PostPosted: Sun Jul 13, 2008 12:46 am   
 
Well I've managed to fix everything and make it work in VT100. The problems encountered were ultimately related to the ANSI default color being white and not accounting for extra space taken up by the necessary additional white color codes on certain lines. Anyway, I guess it's not important.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD 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