delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/04/19/11:45:23

From: "Edward Griffin" <edward AT neptune DOT greatxscape DOT net>
Newsgroups: comp.os.msdos.djgpp
Subject: Fustrated person ranting about text input
Date: Wed, 19 Apr 2000 08:30:51 +0100
Organization: Customer of Planet Online
Lines: 24
Message-ID: <8djplv$27o$1@news6.svr.pol.co.uk>
NNTP-Posting-Host: modem-19.banded-shark.dialup.pol.co.uk
X-Trace: news6.svr.pol.co.uk 956131839 2296 62.136.226.19 (19 Apr 2000 08:10:39 GMT)
NNTP-Posting-Date: 19 Apr 2000 08:10:39 GMT
X-Complaints-To: abuse AT theplanet DOT net
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2919.6600
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Hello.

I'm writting a server program for a network game and I need to write my own
custom text input function. The program runs in text mode so I don't need
any graphical stuff. It currently handles IPX packets and sends them to
other computers on the network. When it's not doing that, I want it to be
checking for keypresses, and if it gets one, add the letter to a string, and
display the text on the screen.

It also needs to understand delete, pgup, pgdn, enter and esc seperately.
How should I go about doing this? There are so many functions like getch,
kbhit, getche, putchar, getchar etc. I've tried hundreds of combinations and
I can't get it to work. When enter is pressed, it also needs to add the \0
and p. Alternatively I could just use gets and use allegro timers to do the
ipx stuff but I'm not sure if that would work. I would need to lock all the
memory and stuff for every variable I use in them and that would be
practicaly imposssible. :-o. Please help!!!

(If you read this far then I congratulate you)

Edward



- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019