simon@shiva.trl.oz (Simon Michnowicz - A Free Spirit) (02/26/90)
I have noticed an error in castle. When I attempt an inventory of some object I found, the program sometimes hangs. I am not sure why. S.G.M
andrewt@watnow.waterloo.edu (Andrew Thomas) (02/26/90)
In article <1082@trlluna.trl.oz> simon@shiva.trl.oz (Simon Michnowicz - A Free Spirit) writes:
I have noticed an error in castle. When I attempt an inventory
of some object I found, the program sometimes hangs. I am
not sure why.
I had the same problem. The trick here is that one of the window
pointers is being overwritten with zeros. The way to fix this is to
increase the length of the global variable 'string' in castle.h. It
is currently 9, but one of the source files assumes it is at least 20
in length and zeros 20 bytes. I increased it to 32 for safety.
The change is: in castle.h
char string[9];
should be:
char string[32];
And all is fine after that.
--
Andrew Thomas
andrewt@watsnew.waterloo.edu Systems Design Eng. University of Waterloo
"If a million people do a stupid thing, it's still a stupid thing." - Opus
mtv@milton.acs.washington.edu (David Schanen) (02/26/90)
Another bug, anyone fix the save bug? Every time *I* try to save it gives a can't write to file message, in fact it gives several can't write to file errors. I might be having problems with linked directories? Has any- one else had this problem? -games dude
rph@cs.brown.edu (Richard Hughey) (02/27/90)
In article <1082@trlluna.trl.oz> simon@shiva.trl.oz (Simon Michnowicz - A Free Spirit) writes: >I have noticed an error in castle. When I attempt an inventory >of some object I found, the program sometimes hangs. I am >not sure why. > > S.G.M Hanging in castle generally comes from seg faults, which are "trapped" into never-never land, after which the only way to get out of castle is to send an interupt, which is then trapped into a quit command. Somewhere in the code, the curses window for inventory is getting clobbered (no idea where). My fix for this is: castle.c(926): look_inv() /* look at your inventory. */ { unsigned char choice; start = firstnode; + if (! inv_win) + inv_win = newwin(8,26,4,54); ------------- Another hanging occured here since the save directory in castle.h does not use FILES, but has its own name. I've heard from one of the players hear that we have another seg fault (hang) still to find, and castle -s never works. - Richard ------------------------------ Richard Hughey CSNET: rph%cs.brown.edu@relay.cs.net Brown University BITNET: rph@browncs (decvax, ihnp4, allegra)!brunix!rph
simon@shiva.trl.oz (Simon Michnowicz - A Free Spirit) (02/27/90)
I have found the reason why my version of castle did not save games. Deep in windows.h the SAVE_FILE definition was to a directory that did not exist. The program hung after a file access to a null pointer was made.
mollers.pad@nixpbe.uucp (Moellers) (02/27/90)
Another error and an irritating ?bug?: Error: castle dumped core because "savetty" was called before "initscr". "savetty" uses a structure which is allocated by "initscr". (This happened on a Pyramid) Irritating: When one moves, the screen is refreshed twice or more! Josef Moellers | c/o Nixdorf Computer AG USA: uunet!philabs!linus!nixbur!mollers.pad | Abt. DX-PC !USA: mcvax!unido!nixpbe!mollers.pad | Pontanusstr Phone: (+49) 5251 146245 | D-4790 Paderborn
doneill@cs.strath.ac.uk (Dave) (02/27/90)
In article <2138@milton.acs.washington.edu> mtv@milton.acs.washington.edu (David Schanen) writes: > > Another bug, anyone fix the save bug? Every time *I* try to save it >gives a can't write to file message, in fact it gives several can't write to >file errors. I might be having problems with linked directories? Has any- >one else had this problem? > Have the same problem, my screen fills up with can't write file, cant write file and the only key that actions anything is the ^C with which i get the prompt Do you really want to quit? Have I missed something out or is this a bug?
apm279l@vaxc.cc.monash.edu.au (02/28/90)
[warning: potential spoiler for novice players...] Thanks to the patch, we've been able to fix *most* problems, but we can't seem to go down the stairs to level two. As soon as we enter the password to make stairs appear, we get a hang! anyone managed to solve this? -Peter
edgard@legos.gipsi.fr (Jean-Marc Odinot) (03/02/90)
To get a better display, i replace a lot of wrefresh by
wnoutrefresh, and i use doupdate just before get char or sleep.
Also, i twist the stat_win and inv_win.
I had a problem with the overwrite in inv_win and message_win, so
all time before write in those windows, i write a blank pattern from
the start of the sentence/word, to the end of the window.
With those three patches (and the patches arrived by news), the screen is
displayed one time each move.
--
My computer ___ ___
is watching < 0 > < 0 >
- -
\ / / \ | | | /^\ edgard@cao.gipsi.fr
\/ | | | | | \_________/ (-: Struggle for life!! :-)
| \_/ \_/ o \_______/