XxBartmanxX
Newcomer
I have a telnet server coded in C#, and I am trying to send text that is colorized to the client. This should be pretty trivial, but as it turns out it's not wanting to work.
Here's how it works:
For red foreground color you would send "\033[31m" to the telnet client. "\033" is the hex code for the Esc key I believe.
Now, this worked fine and dandy back in my C++ days but for some reason C# is ignoring the entire escape code. It sees "\0" and interprets it as null, instead of looking at the whole "\033".
Basically, I need to force it to look at the whole code and not just the \0. I am completely stumped at this point.
To recap, I need it to interpret "\033" as a whole, and not as "\0 33".
Thanks,
Bartman
Here's how it works:
For red foreground color you would send "\033[31m" to the telnet client. "\033" is the hex code for the Esc key I believe.
Now, this worked fine and dandy back in my C++ days but for some reason C# is ignoring the entire escape code. It sees "\0" and interprets it as null, instead of looking at the whole "\033".
Basically, I need to force it to look at the whole code and not just the \0. I am completely stumped at this point.
To recap, I need it to interpret "\033" as a whole, and not as "\0 33".
Thanks,
Bartman