liskon_frotz.git
7 years agoend_of_sound now maybe works.
Timo Korvola [Sat, 3 Mar 2018 18:59:22 +0000 (20:59 +0200)]
end_of_sound now maybe works.

Went back to end_of_sound taking no args, so sound.c got reverted.
Should be easier on DOS frotz, which I never attempted to fix.  Made
interpret call os_tick, as SDL front end expects (WinFrotz also has
os_tick).  os_tick calls end_of_sound as appropriate.  Added os_tick
to the other front ends.  In dumb it does nothing, in curses it
handles resizes.

7 years agoUseless use of dup.
Timo Korvola [Sat, 3 Mar 2018 15:40:35 +0000 (17:40 +0200)]
Useless use of dup.

7 years agoDrastically simplify getaiff.
Timo Korvola [Sat, 3 Mar 2018 12:54:30 +0000 (14:54 +0200)]
Drastically simplify getaiff.

Axe all conversion code (which was complicated and likely buggy)
and let SDL_mixer take care of everything.

7 years agoDrop an unused source file from compilation.
Timo Korvola [Sat, 3 Mar 2018 11:52:22 +0000 (13:52 +0200)]
Drop an unused source file from compilation.

7 years agoremove dfrotz build dependencies
Sean Fitzgerald [Mon, 26 Feb 2018 07:19:03 +0000 (23:19 -0800)]
remove dfrotz build dependencies

As the intention of dfrotz is be dependency free, make it so at build time as well.

7 years agoLose remaining traces of rindex.
Timo Korvola [Fri, 2 Mar 2018 20:19:11 +0000 (22:19 +0200)]
Lose remaining traces of rindex.

rindex never was but POSIX and is deprecated even there.  strrchr
does the same and is C89.

7 years agoAdd declarations.
Timo Korvola [Fri, 2 Mar 2018 19:34:37 +0000 (21:34 +0200)]
Add declarations.

Add enough function prototypes to get rid of warnings.  Fix errors
caused by calls actually not matching definitions.

7 years agoFix dirname / basename problems.
Timo Korvola [Thu, 1 Mar 2018 20:58:13 +0000 (22:58 +0200)]
Fix dirname / basename problems.

It is annoying how vaguely POSIX dirname and basename are defined,
so make our own versions with well-defined behaviour.

Now actually loads a story and starts.

7 years agosfrotz now links.
Timo Korvola [Thu, 1 Mar 2018 20:05:36 +0000 (22:05 +0200)]
sfrotz now links.

Dies of SEGV though.

7 years agoAdd generic.c and generic.h.
Timo Korvola [Sat, 3 Mar 2018 10:24:48 +0000 (12:24 +0200)]
Add generic.c and generic.h.

The functions here are identical or nearly so in most ports.  They should
really be put somewhere so that they can be shared.  For now, this.

7 years agoFix external link problems.
Timo Korvola [Wed, 28 Feb 2018 22:55:12 +0000 (00:55 +0200)]
Fix external link problems.

Now it is just that lots of os_whatever functions are missing from
the SDL front end.  Many of them (e.g., file I/O) could probably be
shared.

7 years agoFix SDL stuff to compile.
Timo Korvola [Wed, 28 Feb 2018 22:02:20 +0000 (00:02 +0200)]
Fix SDL stuff to compile.

Add a minimal GNU Makefile.  A large part of os_process_arguments
was replaced from the curses version.  Other fixes were minimal.

Compiles (with warnings) but haven't tried linking.

7 years agoFix resource Blorb opening.
Timo Korvola [Mon, 19 Feb 2018 21:02:53 +0000 (23:02 +0200)]
Fix resource Blorb opening.

ux_blorb_init may have worked for story Blorbs but handling of
separate resource Blorbs (accompanying a plain story file) was quite
broken.

dumb_blorb.c is basically a copy of ux_blorb.c.  Can't be bothered
to copy this fix there.  dfrotz should use the same code instead of
a copy.

7 years agoMinor tweaks.
Timo Korvola [Sun, 18 Feb 2018 21:32:15 +0000 (23:32 +0200)]
Minor tweaks.

RTFM: ao_initialize must be called from the main thread.

7 years agoMerge pull request #65 from tkorvola/resize
David Griffith [Fri, 23 Feb 2018 05:25:57 +0000 (21:25 -0800)]
Merge pull request #65 from tkorvola/resize

Terminal resizing.  Still needs some work vis-a-vis reformatting text when shrinking or expanding horizontally.  That'll require implementing a history buffer, which will be implemented later.  In the meantime, we have resize code that actually works (just not ideally).

7 years agoEliminate compiler warnings.
Timo Korvola [Thu, 22 Feb 2018 20:07:15 +0000 (22:07 +0200)]
Eliminate compiler warnings.

Some of this is rather silly.

7 years agoSmall Makefile tweaks.
Timo Korvola [Thu, 22 Feb 2018 19:17:36 +0000 (21:17 +0200)]
Small Makefile tweaks.

Build all by default (frotz and dfrotz).
Don't use find ... -delete.  Dangerous.  Was broken anyway.
Clean up whitespace.

7 years agoSuspend on ^Z.
Timo Korvola [Tue, 20 Feb 2018 21:33:42 +0000 (23:33 +0200)]
Suspend on ^Z.

In raw mode ^Z is just another character.  It is easier to
handle than in cbreak because it can be done in normal execution
without having to replace the curses SIGTSTP handler.

7 years agoMerge branch 'master' into resize
Timo Korvola [Tue, 20 Feb 2018 16:56:07 +0000 (18:56 +0200)]
Merge branch 'master' into resize

7 years agoos_repaint_window: return true for zero size area.
Timo Korvola [Tue, 20 Feb 2018 16:51:09 +0000 (18:51 +0200)]
os_repaint_window: return true for zero size area.

7 years agoAdd a dummy os_repaint_window to DOS version.
Timo Korvola [Tue, 20 Feb 2018 16:47:28 +0000 (18:47 +0200)]
Add a dummy os_repaint_window to DOS version.

Untested, as I don't have the compiler for it.

7 years agoMerge branch 'tschmidty69-move_ldflags'
David Griffith [Tue, 20 Feb 2018 12:52:01 +0000 (04:52 -0800)]
Merge branch 'tschmidty69-move_ldflags'

7 years agoMerge branch 'move_ldflags' of https://github.com/tschmidty69/frotz into tschmidty69...
David Griffith [Tue, 20 Feb 2018 12:50:25 +0000 (04:50 -0800)]
Merge branch 'move_ldflags' of https://github.com/tschmidty69/frotz into tschmidty69-move_ldflags

7 years agoMerge pull request #62 from escondida/makefile_tiny_tweak
David Griffith [Tue, 20 Feb 2018 12:42:07 +0000 (04:42 -0800)]
Merge pull request #62 from escondida/makefile_tiny_tweak

Makefile: make -llibs LDFLAGS

7 years agoRevert "Merge branch 'escondida-quetzal'"
David Griffith [Tue, 20 Feb 2018 12:30:59 +0000 (04:30 -0800)]
Revert "Merge branch 'escondida-quetzal'"

This reverts commit a35ecc2eebbb6e6de6d314af5da2363f25b3e3cd, reversing
changes made to 92c121a4e36291f4836f852a573c549736104ec1.

Workaround for compilers lacking a fallthrough attribute failed.

7 years agoMerge branch 'escondida-quetzal'
David Griffith [Tue, 20 Feb 2018 11:40:27 +0000 (03:40 -0800)]
Merge branch 'escondida-quetzal'

7 years agoAdd workarounds for compilers that lack the fallthrough attribute.
David Griffith [Tue, 20 Feb 2018 11:37:50 +0000 (03:37 -0800)]
Add workarounds for compilers that lack the fallthrough attribute.

7 years agoMerge branch 'quetzal' of https://github.com/escondida/frotz into escondida-quetzal
David Griffith [Tue, 20 Feb 2018 11:10:53 +0000 (03:10 -0800)]
Merge branch 'quetzal' of https://github.com/escondida/frotz into escondida-quetzal

7 years agoMerge branch 'escondida-clear_line'
David Griffith [Tue, 20 Feb 2018 10:56:56 +0000 (02:56 -0800)]
Merge branch 'escondida-clear_line'

7 years agoAdded os_quit() and ^Q command to cause Frotz to immediately and cleanly exit.
David Griffith [Tue, 20 Feb 2018 10:54:05 +0000 (02:54 -0800)]
Added os_quit() and ^Q command to cause Frotz to immediately and cleanly exit.

7 years agoChange curses from cbreak mode to raw mode to allow for ^C to clear the line.
David Griffith [Tue, 20 Feb 2018 10:30:41 +0000 (02:30 -0800)]
Change curses from cbreak mode to raw mode to allow for ^C to clear the line.

7 years agoEnsure window 0 has at least one line.
Timo Korvola [Mon, 19 Feb 2018 23:08:50 +0000 (01:08 +0200)]
Ensure window 0 has at least one line.

No other window heights are adjusted, so they may be out of bounds
and overlap with window 0.

7 years agoKeep cursor within bounds in os_read_line.
Timo Korvola [Mon, 19 Feb 2018 21:41:49 +0000 (23:41 +0200)]
Keep cursor within bounds in os_read_line.

Maximum scrpos is width - 1 even if len == width.  Then the cursor
will stay on the last character because there is no room to the right
of it.

#42: Handle terminal resizing

7 years agoStay in os_read_line on resize.
Timo Korvola [Sun, 18 Feb 2018 18:24:46 +0000 (20:24 +0200)]
Stay in os_read_line on resize.

The callers of os_read_line weren't taking a return value of ZC_BAD
too well.  So just chop input to fit and keep editing.

Document that width is adjusted according to terminal width.

#42: Handle terminal resizing

7 years agoClean up a bit.
Timo Korvola [Sun, 18 Feb 2018 14:36:08 +0000 (16:36 +0200)]
Clean up a bit.

Add resize_screen to frotz.h.  Remove its declarations from .c files.
Also remove an unused declaration.

#42: Handle terminal resizing

7 years agoForgot to update dfrotz after interface change.
Timo Korvola [Sun, 18 Feb 2018 14:28:02 +0000 (16:28 +0200)]
Forgot to update dfrotz after interface change.

dfrotz is not built by default, so it is easy to miss errors there.

7 years agoHave resize_screen repaint window 0.
Timo Korvola [Sat, 17 Feb 2018 21:00:12 +0000 (23:00 +0200)]
Have resize_screen repaint window 0.

resize_screen decides which part of the window it wants to keep,
adjusts the window properties and calls a new front end function
os_repaint_window to repaint the required part.  Only window 0 currently
has this special handling - for the others it seems to suffice that
curses repaints the screen from the top left.  Resizing now
works pretty well in Beyond Zork as long as the width is not resized
and the height is enough for the upper window.

Also have resize_screen ask V6 games to redraw.  This used to be in
the front end but I can't see how any front end could do anything else
because the interpreter does not know what kind of window layout the
game wants.  So it may as well be in the common code.

#42: Handle terminal resizing

7 years agoUse a pad for storing the old screen during resize.
Timo Korvola [Sat, 17 Feb 2018 18:36:21 +0000 (20:36 +0200)]
Use a pad for storing the old screen during resize.

Why bother reinventing the wheel when curses does the job?

#42: Handle terminal resizing

7 years agoMoved ldflags to end of cc line
tschmidty69 [Sat, 17 Feb 2018 15:05:43 +0000 (10:05 -0500)]
Moved ldflags to end of cc line

7 years agoMoved ldflags to end of cc line
tschmidty69 [Sat, 17 Feb 2018 15:05:13 +0000 (10:05 -0500)]
Moved ldflags to end of cc line

7 years agoMoved ldflags to end of cc line
tschmidty69 [Sat, 17 Feb 2018 15:04:31 +0000 (10:04 -0500)]
Moved ldflags to end of cc line

7 years agosrc/common/quetzal.c: make fallthrough explicit
Ivy Foster [Fri, 16 Feb 2018 21:55:27 +0000 (15:55 -0600)]
src/common/quetzal.c: make fallthrough explicit

This silences compiler warnings about this deliberate decision, so in
future it will be easier to spot compiler warnings about mistakes;
also, it should now be possible to compile with -Wall -Wextra -Werror.

7 years agoMakefile: make -llibs LDFLAGS
Ivy Foster [Fri, 16 Feb 2018 21:49:34 +0000 (15:49 -0600)]
Makefile: make -llibs LDFLAGS

7 years agoMake ^U behave more like a standard UNIX command-line
Ivy Foster [Fri, 16 Feb 2018 01:32:05 +0000 (19:32 -0600)]
Make ^U behave more like a standard UNIX command-line

Traditionally, ^U deletes everything from the character before point
to the beginning of the line, and this is how your average shell or
REPL behaves. Previously, frotz deleted the whole line.

7 years agoIf ^C isn't used for SIGINT, clear line instead
Ivy Foster [Fri, 16 Feb 2018 01:31:15 +0000 (19:31 -0600)]
If ^C isn't used for SIGINT, clear line instead

7 years agoUse select to wait for input.
Timo Korvola [Sun, 11 Feb 2018 20:41:17 +0000 (22:41 +0200)]
Use select to wait for input.

Using select is more complicated but guarantees interruption on
signals and thus allows immediate reaction to terminal resize.

#42: Handle terminal resizing

7 years agoSplit out a struct timeval version of timeout_to_ms.
Timo Korvola [Sun, 11 Feb 2018 15:58:46 +0000 (17:58 +0200)]
Split out a struct timeval version of timeout_to_ms.

Planning to move to select for timeout handling, and select uses
struct timeval.

#42: Handle terminal resizing

7 years agoClip cursor position to window sizes.
Timo Korvola [Sat, 10 Feb 2018 17:12:47 +0000 (19:12 +0200)]
Clip cursor position to window sizes.

This introduces an inconvenient dependency between resize_screen
and unix_resize_screen.

#42: Handle terminal resizing

7 years agoCope with resize in os_read_line.
Timo Korvola [Sat, 10 Feb 2018 12:43:44 +0000 (14:43 +0200)]
Cope with resize in os_read_line.

os_read_line now returns ZC_BAD if the screen becomes too narrow.
Not sure if that is right but it will do for now.  The bigger problem
is that the Zwindow structures in screen.c are not updated, thus
subsequent output makes a mess of the screen.

#42: Handle terminal resizing

7 years agoUse // for commenting away.
Timo Korvola [Sat, 10 Feb 2018 12:23:48 +0000 (14:23 +0200)]
Use // for commenting away.

Stops warnings about nested comments.  Eventually the commented
away declarations should be either implemented or dropped, but let's
keep them in limbo for now.

7 years agoBetter method for row shrinking.
Timo Korvola [Tue, 6 Feb 2018 22:25:46 +0000 (00:25 +0200)]
Better method for row shrinking.

Shrink the screen so that the cursor will normally be on the last row.

#42: Handle terminal resizing

7 years agoTry to repaint the screen.
Timo Korvola [Fri, 26 Jan 2018 19:11:31 +0000 (21:11 +0200)]
Try to repaint the screen.

The old screen contents are read from curses.

7 years agoMerge branch 'master' into resize
Timo Korvola [Sat, 10 Feb 2018 12:57:04 +0000 (14:57 +0200)]
Merge branch 'master' into resize

7 years agoUpdate README to state that audio support is through libao.
David Griffith [Tue, 6 Feb 2018 04:26:36 +0000 (20:26 -0800)]
Update README to state that audio support is through libao.

7 years agoMerge pull request #57 from escondida/make
David Griffith [Tue, 6 Feb 2018 04:23:49 +0000 (20:23 -0800)]
Merge pull request #57 from escondida/make

Rewrite the Makefile

7 years agoRewrite the Makefile
Ivy Foster [Fri, 2 Feb 2018 00:56:20 +0000 (18:56 -0600)]
Rewrite the Makefile

Some general patterns for the changes:
- Use user LDFLAGS and CFLAGS
- Generally allow user to pass well-known variables through the
  environment or on the command-line rather than editing the file and
  finding what they're called
- Get rid of non-standard variables like OPTS in favor of additive
  assignmet
- Remove repetitive code (compare %.a definition with previous foo_lib
  recipes)
- Correct build dependencies (e.g., it is frotz_curses.a that requires
  the curses defines.h; frotz itself requires that defines.h only
  indirectly)
- Reduce number of needless variables; it's just as easy to use sed to
  change all occurrences of "frotz" if the name ever changes as it
  would be to change $(NAME)
- Clarify recipes where possible by breaking out conditionals and such
  that can go elsewhere
- Make git usage less brittle by providing fall-backs; this also means
  that releases built from dist tarballs are more clearly marked by
  having GIT_BRANCH and GIT_HASH be "none"
- Remove variable definitions that make automagically handles when not
  passed by user, such as CC

I also removed any mention of the oss and sun audio options, since the
existing checks raised an error if any option other than "ao" or
"none" was passed

7 years agoCheck for resize after getch.
Timo Korvola [Sat, 27 Jan 2018 22:21:59 +0000 (00:21 +0200)]
Check for resize after getch.

Most of the time is spent in getch, so that is when we'll likely
get SIGWINCH.

7 years agoCall endwin() if unix_get_terminal_size() has to punt.
Timo Korvola [Sat, 27 Jan 2018 17:51:29 +0000 (19:51 +0200)]
Call endwin() if unix_get_terminal_size() has to punt.

Curses must be very messed up at this point.  Turn it off and hope
something prints on our way out.

This is 3505ee0d revived, as it got clobbered in the merge.

7 years agoMerge branch 'master' into resize
Timo Korvola [Sat, 27 Jan 2018 18:26:45 +0000 (20:26 +0200)]
Merge branch 'master' into resize

7 years agoFound some new droppings that need to be ignored.
David Griffith [Fri, 26 Jan 2018 14:17:51 +0000 (06:17 -0800)]
Found some new droppings that need to be ignored.

7 years agoTurn off curses before doing an os_fatal() for screen width > 255.
David Griffith [Fri, 26 Jan 2018 13:56:16 +0000 (05:56 -0800)]
Turn off curses before doing an os_fatal() for screen width > 255.

7 years agoFixed weirdness in os_char_width() carried over from old DOS interface.
David Griffith [Fri, 26 Jan 2018 12:55:45 +0000 (04:55 -0800)]
Fixed weirdness in os_char_width() carried over from old DOS interface.

7 years agoAdd DUMMY macro call to calm the compiler.
David Griffith [Fri, 26 Jan 2018 12:23:56 +0000 (04:23 -0800)]
Add DUMMY macro call to calm the compiler.

7 years agoSet screen width to 255 when terminal asks for more.
David Griffith [Fri, 26 Jan 2018 12:13:55 +0000 (04:13 -0800)]
Set screen width to 255 when terminal asks for more.

The Z-machine design uses an 8-bit value to describe the number of
columns on a terminal.  At the time (late 1970s), this seemed like a
reasonable limitation.  Now some people are trying to use terminals
(emulators really) this wide.

7 years agoRemove duplicate prototypes and move other stuff to a better place.
David Griffith [Fri, 26 Jan 2018 12:10:07 +0000 (04:10 -0800)]
Remove duplicate prototypes and move other stuff to a better place.

7 years agoNew function unix_get_terminal_size.
Timo Korvola [Thu, 25 Jan 2018 22:08:29 +0000 (00:08 +0200)]
New function unix_get_terminal_size.

Now startup and resize use the same code for getting the terminal
size (including override support).

7 years agoSimplify the SIGWINCH handler.
Timo Korvola [Wed, 24 Jan 2018 23:46:46 +0000 (01:46 +0200)]
Simplify the SIGWINCH handler.

Calling curses from the signal handler may not be safe.
So just set a flag and do the actual work in unix_read_char.

7 years agoFix unix_resize_display.
Timo Korvola [Wed, 24 Jan 2018 21:59:15 +0000 (23:59 +0200)]
Fix unix_resize_display.

COLS and LINES are updated by refresh(), so that needs
to come first.

7 years agoMerge branch 'master' into resize
Timo Korvola [Wed, 24 Jan 2018 22:05:42 +0000 (00:05 +0200)]
Merge branch 'master' into resize

7 years agoMerge pull request #55 from tkorvola/undo
David Griffith [Wed, 24 Jan 2018 20:59:07 +0000 (12:59 -0800)]
Merge pull request #55 from tkorvola/undo

Fix SEGV on undo past beginning of game.

7 years agoFix SEGV on undo past beginning of game.
Timo Korvola [Sun, 21 Jan 2018 18:53:26 +0000 (20:53 +0200)]
Fix SEGV on undo past beginning of game.

7 years agoMerge pull request #54 from laanwj/2017_12_yellow
David Griffith [Sun, 31 Dec 2017 15:13:11 +0000 (07:13 -0800)]
Merge pull request #54 from laanwj/2017_12_yellow

Allow color 'yellow' for option -f and -b

7 years agoAllow color 'yellow' for option -f and -b
Wladimir J. van der Laan [Sat, 23 Dec 2017 07:24:51 +0000 (08:24 +0100)]
Allow color 'yellow' for option -f and -b

This color was missing in `getcolor()`, but is supported by the ncurses
backend, so add it.

7 years agoMerge pull request #52 from llasram/dumb-command-name
David Griffith [Fri, 15 Dec 2017 14:01:33 +0000 (06:01 -0800)]
Merge pull request #52 from llasram/dumb-command-name

Provide dfrotz `f_setup.command_name` with an initial buffer

7 years agoMerge pull request #51 from everlastingwonder/patch-1
David Griffith [Fri, 15 Dec 2017 14:00:06 +0000 (06:00 -0800)]
Merge pull request #51 from everlastingwonder/patch-1

Update Makefile to support versions of install that don't recognize -D option

7 years agoProvide dfrotz `f_setup.command_name` with an initial buffer
Marshall Bockrath [Thu, 14 Dec 2017 19:09:52 +0000 (14:09 -0500)]
Provide dfrotz `f_setup.command_name` with an initial buffer

Without this initialization `f_setup.command_name` is NULL, but
e.g. `replay_open()` assumes that it points to a valid buffer, and produces a
segfault if it does not.  In particular, this causes `dfrotz` to segfault when
attempting to replay a command playback file.

7 years agoUpdate Makefile to support versions of install that don't recognize -D
Gus Wiedey [Tue, 12 Dec 2017 20:07:18 +0000 (15:07 -0500)]
Update Makefile to support versions of install that don't recognize -D

On some versions of MacOS (e.g. the one I'm currently using), the system default version of `install` doesn't recognize the `-D` option (the closest equivalent is `-d`); this provides support for those versions.

7 years ago...forgot src/dumb/dumb_params.txt
David Griffith [Fri, 21 Jul 2017 23:12:23 +0000 (16:12 -0700)]
...forgot src/dumb/dumb_params.txt

7 years agoClean up minor unevenness in "dfrotz -h" output.
David Griffith [Fri, 21 Jul 2017 23:11:36 +0000 (16:11 -0700)]
Clean up minor unevenness in "dfrotz -h" output.

7 years agoMention the '-m' flag in "dfrotz -h" output.
David Griffith [Fri, 21 Jul 2017 23:08:14 +0000 (16:08 -0700)]
Mention the '-m' flag in "dfrotz -h" output.

7 years agoRemove references to obsolete PORTING and PACKAGING files from README.
David Griffith [Thu, 13 Jul 2017 00:05:48 +0000 (17:05 -0700)]
Remove references to obsolete PORTING and PACKAGING files from README.

7 years agoAdded .EXE, .LIB, and .z? to .gitignore.
David Griffith [Wed, 12 Jul 2017 12:34:45 +0000 (05:34 -0700)]
Added .EXE, .LIB, and .z? to .gitignore.

7 years agoDOS Frotz restricted mode (not tested yet) and fixed problems in bcsample.c.
David Griffith [Wed, 12 Jul 2017 12:31:13 +0000 (05:31 -0700)]
DOS Frotz restricted mode (not tested yet) and fixed problems in bcsample.c.

7 years agoStyle correction.
David Griffith [Sat, 1 Jul 2017 09:25:49 +0000 (02:25 -0700)]
Style correction.

7 years agoAdd list of parameters for DOS interface for use with src/misc/twocol.pl
David Griffith [Wed, 28 Jun 2017 23:48:03 +0000 (16:48 -0700)]
Add list of parameters for DOS interface for use with src/misc/twocol.pl

7 years agoAdd restricted mode for curses, which is now -R. -L is for loading saves.
David Griffith [Wed, 28 Jun 2017 23:29:02 +0000 (16:29 -0700)]
Add restricted mode for curses, which is now -R.  -L is for loading saves.

7 years agoAdd -W flag to dumb help. Clarify that -W restricts reading as well.
David Griffith [Wed, 28 Jun 2017 22:38:35 +0000 (15:38 -0700)]
Add -W flag to dumb help.  Clarify that -W restricts reading as well.

7 years agoAdded support for directory restriction.
David Griffith [Tue, 27 Jun 2017 11:57:07 +0000 (04:57 -0700)]
Added support for directory restriction.

I cringed while writing this, looking at all those unsafe string calls.
I resisted the urge to go off on a tangent, correcting all of them.
Rather than do that now and forget what I should be doing, I'll get
directory restriction done and THEN tackle the string call problem.

7 years agoClarify some stuff about the intended effects of -W.
David Griffith [Tue, 27 Jun 2017 11:09:53 +0000 (04:09 -0700)]
Clarify some stuff about the intended effects of -W.

7 years agoAdding some stuff to ease the process of reworking -h output.
David Griffith [Tue, 27 Jun 2017 09:43:02 +0000 (02:43 -0700)]
Adding some stuff to ease the process of reworking -h output.

7 years agoModified the manpages in anticipation of the -W option
David Griffith [Tue, 27 Jun 2017 09:39:11 +0000 (02:39 -0700)]
Modified the manpages in anticipation of the -W option

The -W option restricts Frotz to writing only in the specified
directory.  This is to prevent players from writing somewhere they
should not.  This is intended to be useful for front-ends or restricted
environments -- for instance a chatbot or telnetting to a certain TCP/IP
port to play a game.

7 years agoMerge branch 'timtelcik-frotz-issue-44'
David Griffith [Thu, 15 Jun 2017 19:10:24 +0000 (12:10 -0700)]
Merge branch 'timtelcik-frotz-issue-44'

7 years agoFix to appease -Wmisleading-indentation
David Griffith [Thu, 15 Jun 2017 19:08:53 +0000 (12:08 -0700)]
Fix to appease -Wmisleading-indentation

7 years agofrotz-issue-44: Replaced type "ulong" with type "unsigned long" to enable support...
Tim Telcik [Thu, 15 Jun 2017 15:05:32 +0000 (23:05 +0800)]
frotz-issue-44: Replaced type "ulong" with type "unsigned long" to enable support for Apple MacOS Sierra 10.12 plus MacPorts 2.4.1.

7 years agofrotz-issue-44: Added compiler support for Apple MacOS Sierra 10.12 plus MacPorts...
Tim Telcik [Mon, 12 Jun 2017 16:20:33 +0000 (00:20 +0800)]
frotz-issue-44: Added compiler support for Apple MacOS Sierra 10.12 plus MacPorts 2.4.1.

8 years agoClean up assorted foibles in Makefile.
David Griffith [Thu, 9 Mar 2017 11:37:09 +0000 (03:37 -0800)]
Clean up assorted foibles in Makefile.

Fix problem with "make dist" resulting in a distro file missing src/common/git_hash.h
Only delete src/common/git_hash.h when cleaning IF we're in a git repo (and git is installed).
Make sure compiling with no sound actually works
Optimized the hash target and refrain from needlessly redoing it

8 years agoClean up assorted foibles in Makefile.
David Griffith [Thu, 9 Mar 2017 11:31:52 +0000 (03:31 -0800)]
Clean up assorted foibles in Makefile.

Fix problem with "make dist" resulting in a distro file missing src/common/git_hash.h
Only delete src/common/git_hash.h when cleaning IF we're in a git repo (and git is installed).
Make sure compiling with no sound actually works
Optimized the hash target and refrain from needlessly redoing it

8 years agoThis approach almost works. First character typed after the resize gets lost though.
David Griffith [Thu, 9 Mar 2017 06:21:05 +0000 (22:21 -0800)]
This approach almost works.  First character typed after the resize gets lost though.

8 years agoDelete useless os_speech_output() call.
David Griffith [Thu, 9 Mar 2017 06:19:59 +0000 (22:19 -0800)]
Delete useless os_speech_output() call.

8 years agoInitial attempt at resizing the screen.
David Griffith [Wed, 8 Mar 2017 13:25:15 +0000 (05:25 -0800)]
Initial attempt at resizing the screen.

Essentially I just copied stuff from FrotzWnd.cpp from David Kinder's
Windows Frotz codebase.  I don't understand how he's getting the screen
contents to reprint.