In <Pine.BSI.3.93.960705132952.22020A-100000@global.california.com>, on 07/05/96 at 01:42 PM, ShadowLord <dkoepke@california.com> said: >On Thu, 4 Jul 1996, Andrew P Carter wrote: >> As a side note, I was wondering if anyone had a simple way to promp >> players on whether they wanted ansi or not before they login (before the >> opening screen even). That way you could put in an ansi opening screen, >> character creations menus, etc. Yeah, it seems pretty easy, but I hate >> messing around with any stuff around the socket code, and besides I'm la >> So if anyone has done it and could lend me their interpreter.c to look >> at (or tell me how it's done) I'd be much obliged :P >It's easy. You don't even need to get around the socket code *AT ALL.* >Just go into structs.h and add a new CON state, I call mine CON_TERM_TYPE >but you can call it whatever you want, to. Be sure to add the string to >constants.c with the names of the other CON_xxx states. A better way which doesn't involve asking the players is by using the telnet get remote terminal emulator function-thing. This way, by the string returned by the telnet client (ansi, vt100, vt220, etc) you could automatically enable or disable colors unless the player overrides the option. The only problem with this is that many crappy pseudo-telnet clients don't correctly do all the telnet command codes (and you'd have to do socket stuff for programming). You'd need to make a big database of all the terminals and which ones support 8-bit characters, which have color, and so on, if you're up to it. Both methods will work, though, and the first is definitely much simpler to add. --------------------------------------------------------------------------- Barid Bel Medar icarus@berkshire.net Knights of the Cosmos Shayol Ghul Resort and Health Spa --------------------------------------------------------------------------- "I am returning this otherwise good typing paper to you because someone has printed gibberish all over it and put your name at the top." - English Professor, Ohio University ---------------------------------------------------------------------------
This archive was generated by hypermail 2b30 : 12/07/00 PST