Commit Graph

29 Commits

Author SHA1 Message Date
Pasi Kallinen f64b9da317 Fix watching, thanks to Jilles!
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@349 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2007-03-31 16:21:58 +00:00
Jilles Tjoelker debd70f269 Use select() if kevent() does not work, e.g. file on msdosfs.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@337 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-28 21:30:54 +00:00
Jilles Tjoelker 8038fbe363 Use kqueue() if available (FreeBSD) to improve watching.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@336 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-23 14:00:29 +00:00
Jilles Tjoelker 0817cc32e8 * Make sure curses will redraw the watch list after 'm' has been used
* ^L and ^R will redraw the entire screen in the watch list


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@334 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-23 12:59:33 +00:00
Jilles Tjoelker ca91ccc027 Use one select() call to both delay and detect keypresses.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@333 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-23 12:43:59 +00:00
Jilles Tjoelker 30973454e4 * Clean up a bit
* Close the ttyrec file when watching is done


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@332 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-23 12:30:24 +00:00
Jilles Tjoelker e31ca985ee Making watching more efficient:
* Don't uselessly read the ttyrec file at the start.
* Toggle the ttyrec file between buffered and non-buffered. Non-buffered I/O
  via stdio can be very inefficient.
* Keep stdout buffered, and flush it when waiting for a key or more ttyrec
  data.

Tested somewhat on my FreeBSD 4 machine.


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@331 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-08-22 22:32:10 +00:00
Joshua Kwan 9333116712 populate_gfx_array(stripped) in ttyplay_main, not (NO_GRAPHICS).
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@257 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-02-23 03:55:21 +00:00
Joshua Kwan ccd503105e Removed some worthless input cruft
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@228 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-02-10 21:19:49 +00:00
Joshua Kwan c0afaba270 - remove third argument from ttyplay_main
- kludge to not run strip_gfx when stripped == NO_GRAPHICS
- other random fixes


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@221 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-02-03 02:55:24 +00:00
Jilles Tjoelker 142b5d434e Remove C++ variable declaration after statement.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@217 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-02-02 20:51:37 +00:00
Joshua Kwan 38503b374a allow dynamic switching of graphics stripping
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@216 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-02-02 20:43:12 +00:00
Joshua Kwan 8bdb57a194 Fix a little fallout, also notify mailer of failed login...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@196 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-31 03:10:03 +00:00
Joshua Kwan 710df809e0 Allow user to login on the spot.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@195 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-31 03:04:58 +00:00
Jilles Tjoelker e8f6f8de8e Return to watching after sending a simplemail message. This behaves like
choosing the letter again in the watch menu, as the screen contents are lost
when typing in the message and must be restored.

Tested on my FreeBSD 4.8 machine and the Solaris 9 machine. On the latter,
some problems because dgamelaunch doesn't recognize nethackstub's clear
screen sequence. Continuing watching works on both.


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@193 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-30 21:28:38 +00:00
Jilles Tjoelker 7222c4a282 Clearer error message if h->len is too big. The current value of errno has
no meaning here, so don't use perror().


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@192 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-30 20:08:31 +00:00
Joshua Kwan 6f11c9053a Regenerate dependencies, function prototypes, remove useless includes, globals,
and make code more readable. Move externs into a header file, just tidying up.


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@186 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-30 02:49:29 +00:00
Joshua Kwan a095001e0a remove deep_copy function, rename initncurses to initcurses
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@169 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-26 08:29:04 +00:00
Joshua Kwan c4932ed44b Cleanups - globals, extraneous #defines, #include order, etc.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@161 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-25 22:34:35 +00:00
Jilles Tjoelker eaaf80eb43 Avoid calling lseek() on a descriptor managed by stdio.
This often leads to undefined behaviour.
Function: set_seek_offset_clrscr()


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@153 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-23 18:21:07 +00:00
Joshua Kwan 0f9d024d26 ncurses.h -> curses.h
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@129 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-19 16:56:03 +00:00
Jilles Tjoelker 1a081cc170 Solaris compatibility.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@123 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-16 16:36:33 +00:00
Jilles Tjoelker 7fab8e128d Some fixes to simplemail. It appears to work for me now.
To keep it simple, 'm' quits out of watching.


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@107 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 13:35:38 +00:00
Brett Carrington 45afd54ca0 graceful_exit, does nothing but please deprecate exit().
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@63 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 01:45:21 +00:00
Joshua Kwan ede90e71bd usage() is useless
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@47 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-03 00:31:47 +00:00
Joshua Kwan d829ac26e2 caught_sighup has no real purpose, get rid of it
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@36 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-02 06:15:30 +00:00
Joshua Kwan 8b0af2e9aa I can't stand it anymore, reindenting with 2 spaces,
also add a dgl-banner file that has a $VERSION token that one can put
anywhere, replace VER[1-7] and VERLINES


git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@24 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2003-12-31 19:47:49 +00:00
Joshua Kwan 363b57f1a2 reindent files, add some glue to allow mailing from within the ttyplay session
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@13 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2003-12-31 01:58:56 +00:00
Joshua Kwan f626f44b02 initial commit of new dgamelaunch to CVS
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@1 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2003-12-30 21:30:32 +00:00