Commit Graph

4530 Commits

Author SHA1 Message Date
Pasi Kallinen
04dd85e138 Fix magic mapped dark room symbols 2015-04-10 22:43:13 +03:00
Pasi Kallinen
dc63af1396 Disclose extinct species alongside genocided ones 2015-04-10 22:00:33 +03:00
Pasi Kallinen
cc1b5de2a8 Fix warnings, unused and shadowed variables 2015-04-10 20:55:24 +03:00
Pasi Kallinen
ddd7c9b690 Cast time_t into unsigned long 2015-04-10 19:47:17 +03:00
Pasi Kallinen
c6e9838615 Update precompiled lex and yacc files 2015-04-10 19:45:04 +03:00
Pasi Kallinen
64405f6774 Fix attribution of sortloot patch 2015-04-10 19:20:31 +03:00
Pasi Kallinen
c266d05680 Minor special level and compiler tweakage
Fix allowed map characters.
Make some predefined MAPs blend in better with randomly
generated parts.
2015-04-10 16:47:32 +03:00
Sean Hunt
0edd645384 Fix Sanctum phasing bug. 2015-04-10 09:14:23 -04:00
Sean Hunt
6a116ee59c Restore the insect legs on Baalzebub's level. 2015-04-10 09:14:23 -04:00
PatR
71d7eff0a7 revisit variable arguments in new lev_comp
The previous USE_OLDARGS worked with gcc on Intel, but was inherently
unsafe.  This method is completely safe, just obnoxiously intrusive.
It you disliked debugpline*(), you're bound to hate this....
2015-04-10 01:39:55 -07:00
Sean Hunt
f523055746 Make WALLIFIED_MAZE into a level flag.
It should now be randomly disabled for a 3rd of Gehennom, to make things
a tad more interesting there. It's also disabled in Baalzebub's lair,
to make things a little more interesting.

Still don't know why the beetle is disappearing.
2015-04-09 13:27:44 -04:00
Pasi Kallinen
92a7962399 Add sortloot -patch
Adds the "sortloot" compound option, with possible values
of "none", "loot", or "full".  It controls the sorting of
item pickup lists for inventory and looting.
2015-04-09 18:23:54 +03:00
PatR
9072e80085 support pre-ansi varargs in new lev_comp
Remove the requirement for <stdarg.h> that was introduced to lev_comp.
USE_STDARG still works.  USE_OLDARGS required hackery but has been
tested and actually works, although I wouldn't trust it on platforms
where 'long' and 'char *' aren't the same size.  USE_VARARGS didn't
require any hackery--aside from the conversion to core's pline code--
but has not been tested:  <varargs.h> supplied with OSX won't compile,
with an #error directive that basically says "switch to <stdarg.h>".

I changed several printf formats of %i and %li to %d and %ld because
I'm not sure how widespread the 'i' variant was back in days of yore.
[TODO:  avoid use of snprintf since pre-ANSI systems won't have it.]
2015-04-09 03:09:00 -07:00
Pasi Kallinen
5cf86e0409 Add 2 new Medusa variants 2015-04-08 20:38:32 +03:00
Pasi Kallinen
ea084680ac Add 10 new bigroom variants 2015-04-08 18:31:32 +03:00
keni
692292e46e Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-08 10:32:11 -04:00
keni
ed631c51fa nhsub docs and fixes 2015-04-08 10:31:49 -04:00
Pasi Kallinen
3979e012f7 Renumber other.txt tiles 2015-04-07 21:34:57 +03:00
Pasi Kallinen
c967dabc0b Clive Crous' Dark Room patch
This patch adds a new glyph that represents dark parts of room,
splitting the dual functionality of the "unexplored/dark area" glyph.
2015-04-07 21:01:21 +03:00
Pasi Kallinen
1c2f2af357 Indicator glyph for good target positions
Add a new glyph, S_goodpos, to indicate valid locations
instead of reusing the camera flash beam glyph.
2015-04-07 18:18:54 +03:00
PatR
f5b71c5b8f tty fix for bad curs positioning (-1,n)
DEBUGFILES set to "wintty.c" reported a bad cursor positioning attempt
at the end of the RIP tombstone, and when set to "questpgr.c wintty.c"
reported a whole bunch right at the start of the game when enumerating
all the quest messages for the chosen role.  Both were triggered by
this x==0 call to tty_curs() near the end of process_text_window().
    if (i == cw->maxrow) {
        if(cw->type == NHW_TEXT){
            tty_curs(BASE_WINDOW, 0, (int)ttyDisplay->cury+1);
            cl_eos();
        }
    ...
The x value is always decremented in tty_curs, so passing in 0 yields
a bad value of -1.  The bad call returns without doing anything, and
when DEBUG is disabled, it does so silently.

No fixes entry; it was caused by a post-3.4.3 fix for something else.
2015-04-07 01:23:16 -07:00
keni
5cff7e59aa nhsub: handle some more cases 2015-04-06 17:48:48 -04:00
nhmall
13185adad2 Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-06 16:18:44 -04:00
nhmall
3d6fabf730 nhclose
Changes to be committed:
	modified:   include/extern.h
	modified:   src/bones.c
	modified:   src/do.c
	modified:   src/files.c
	modified:   src/music.c
	modified:   src/restore.c
	modified:   src/save.c
	modified:   sys/share/pcmain.c
	modified:   sys/share/pcsys.c
	modified:   sys/share/pcunix.c

In order to get level file locking correctly again post 3.4.3
with the newer compilers for windows, I had to funnel close()
calls to an intercepting routine.

I had two choices:

1. Surround every close() in at least 9 source files with messy:
	#ifdef WIN32
		nhclose(fd);
	#else
		close(fd);
	#endif

OR

2. Replace every close() with nhclose() and
   deal with the special code in the nhclose()
   version for windows, while just calling
   close() for other platforms (in files.c).

   It is also possible, although not done in this commit,
   to
	#define nhclose(fd) close(fd)
   in a header file for non-windows, rather than funnel
   though a real nhclose() function in files.c.
2015-04-06 10:12:10 -04:00
keni
a5d6c1dd7a Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-06 08:11:17 -04:00
Pasi Kallinen
3ab441b1a1 Quick band-aid to prevent PRNG prediction
This is originally Derek's change from Spork, but sniping it
so we can mark this done for now, and can move on with the
nextversion.

Better solution is to use something like the ISAAC PRNG, which
cannot be predicted.
2015-04-06 09:30:39 +03:00
keni
043c55a613 Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-05 20:57:28 -04:00
nhmall
b7ad4a8a2a Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-05 09:34:00 -04:00
Pasi Kallinen
d8a65cd150 Add missing protos 2015-04-05 16:29:34 +03:00
nhmall
660534389e a warning bout lc_error
lev_comp.l(310) : warning C4013: 'lc_error' undefined; assuming extern returning int
2015-04-05 09:26:01 -04:00
Pasi Kallinen
2c8b088edf Add S_poisoncloud to Guidebooks 2015-04-05 15:15:49 +03:00
Pasi Kallinen
2643a5c311 Show stinking cloud valid positions 2015-04-05 13:51:30 +03:00
Pasi Kallinen
056565fe75 Make all elementals breathless
It makes no sense that air, fire and water elementals
would choke in stinking cloud.
2015-04-05 12:47:27 +03:00
Pasi Kallinen
71401a7db8 Add poison cloud glyph, fumaroles to fire plane.
When a gas cloud that deals damage is created, it uses
a poison cloud glyph instead of the cloud glyph.
(A bright green '#', or a bright-green recolor of the
cloud tile)

The plane of fire has random "stinking clouds", or
fumaroles, centered on lava pools.

Also make poison cloud glyph override lava, pool and
moat glyphs.
2015-04-05 12:31:55 +03:00
keni
89b0fd5ca7 nhsub bug fixes 2015-04-04 15:43:58 -04:00
Pasi Kallinen
68a39aeab4 Fix GCC warnings caused by new lev_comp 2015-04-03 17:40:54 +03:00
Pasi Kallinen
fdc7e980ea Prevent segfaults, makemon can return null 2015-04-03 14:46:28 +03:00
Pasi Kallinen
30bce1ec6b Suggest only accessible positions for polearms and jumping 2015-04-03 12:29:58 +03:00
Pasi Kallinen
0344771b12 Silence warnings 2015-04-03 08:33:14 +03:00
Pasi Kallinen
d0c3050d08 Update Guidebook with menucolor docs 2015-04-02 20:17:51 +03:00
Pasi Kallinen
c8e781c418 Add menucolors
-Add a boolean option menucolors to toggle menu color
-Add MENUCOLOR -config file option

TODO:
-Better support for win32
-Support more windowports
-Update Guidebook
-Allow changing menucolor lines in-game
2015-04-02 20:16:25 +03:00
Pasi Kallinen
9f66b234ed Separate splev stack pops 2015-04-02 16:08:15 +03:00
Pasi Kallinen
f150adf0ce Silence GCC warnings 2015-04-02 14:04:31 +03:00
Pasi Kallinen
884d9d4be5 Record in xlogfile if any bones were loaded 2015-04-02 13:06:45 +03:00
PatR
066e415c3e some lint cleanup
Mostly local variables using the same name as other things.
2015-04-01 17:29:26 -07:00
Pasi Kallinen
2a4affbf6f Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource into paxed-new_lev_comp 2015-04-01 23:03:04 +03:00
Pasi Kallinen
d883da2353 Add doors correctly 2015-04-01 23:01:25 +03:00
keni
bc6bd724ac Merge branch 'master' of https://rodney.nethack.org:20040/git/NHsource 2015-04-01 14:41:11 -04:00
keni
32236f7985 bug fixes for nhsub 2015-04-01 14:40:48 -04:00
Pasi Kallinen
5bbde14a39 Generate oracle monsters after subroom 2015-04-01 19:02:52 +03:00