Bart House
36be0c0f0c
Merge branch 'macosx-curses-fall2018' of https://rodney.nethack.org:20040/git/NHsource into macosx-curses-fall2018
2018-11-20 16:11:42 -08:00
Bart House
d10a18ff00
Switching back to tty on picked by default for XCode biuld.
2018-11-20 16:11:22 -08:00
Bart House
b195025635
Added all header files to Xcode project.
2018-11-20 13:22:48 -08:00
Bart House
aa939a62b0
Adding README for building NetHack with XCode.
2018-11-20 11:16:24 -08:00
Bart House
da1e7de925
Adjusted compiler settings to reduce warnings in XCode project.
2018-11-20 10:51:03 -08:00
Bart House
2a6bd3e8ac
Addressed compiler warnings.
...
Added the initialization of several locals.
In check_fields, validate that we have a valid index (idx) before using.
2018-11-20 10:48:44 -08:00
Bart House
520b130a5c
Added initialization of locals to quite compiler warnings.
2018-11-20 10:47:12 -08:00
Bart House
d177b5e705
Addressed compiler warnings.
...
Fixed declarations of draw_classic, draw_vertical and draw_horizontal.
Moved definitions of locals before code. Added initialization of
locals. Changed comments to c-style.
2018-11-20 10:46:45 -08:00
Bart House
e66a8c4c73
Changed comments to c-style.
2018-11-20 10:45:04 -08:00
Bart House
347c45b420
Addressed compiler warnings.
...
Changed to c-style comments. Placed locals before code. Added
initialization of local value ret in curses_block.
2018-11-20 10:44:44 -08:00
Bart House
fcb28cd2e5
Addressed compiler warnings.
...
Moved local declarations before code. Changed comments to c-style.
2018-11-20 10:43:35 -08:00
Bart House
616e946393
Scoped existing code in a new block to quite compiler warnings.
2018-11-20 10:42:13 -08:00
Bart House
0b1e975b07
Addressed compiler warnings.
...
Moved locals before code. Changed comment type.
2018-11-20 10:35:25 -08:00
Bart House
be11d50d91
Added use of SCCS_Id to quite compiler warnings.
2018-11-20 10:33:36 -08:00
Bart House
c987a3dc2f
Added initialization of locals in create_room() to quite compiler warnings.
2018-11-20 10:30:11 -08:00
Bart House
a19b05d262
Added initialization of cc in do_look() to quite compiler warnings.
2018-11-20 10:29:05 -08:00
Bart House
d1cd20998f
Added initialization if ilet to quite compiler warnings.
2018-11-20 10:27:35 -08:00
Bart House
7f4a4188a0
Added initialization of newlevel to quite compiler warnings.
2018-11-20 10:27:09 -08:00
Bart House
8799f05904
Fix lrand48 and srand48 declarations.
2018-11-20 10:26:09 -08:00
Bart House
8c61ac476d
Fixed HACKDIR buid setting.
2018-11-20 07:32:23 -08:00
Bart House
9f8b419ec8
Added necessary build dependencies for xcode project.
2018-11-19 19:58:21 -08:00
Bart House
a68a8f21d4
Full build of nethack now supported in xcode.
2018-11-19 19:48:01 -08:00
Bart House
1af98716f2
Added the building of nhdat to xcode project.
2018-11-19 17:23:04 -08:00
Bart House
dd9ca9202c
Added building of nhdat to xcode project.
2018-11-19 16:54:31 -08:00
Bart House
6cf6e3c750
Added support for building Guidebook in xcode build.
2018-11-19 16:22:16 -08:00
Bart House
abb59e7283
Added building dungeon to xcode project.
2018-11-19 14:51:24 -08:00
Bart House
8dc9a3d930
Merge branch 'macosx-curses-fall2018' of https://rodney.nethack.org:20040/git/NHsource into macosx-curses-fall2018
2018-11-19 14:11:59 -08:00
Bart House
9f525b3241
Added building of special and quest levels in xcode build.
2018-11-19 14:11:39 -08:00
Bart House
d1b6581c08
Added building of more resources in xcode build.
2018-11-19 13:03:06 -08:00
Bart House
cbe2669e05
Removing personal data.
2018-11-19 12:17:37 -08:00
Bart House
d83ae1a4da
Adding the ignoring of xcuserdata.
2018-11-19 12:17:20 -08:00
Bart House
f47893258d
Removed personal user data.
2018-11-19 12:14:45 -08:00
Bart House
b2e65ad9cd
Adding the ignoring of xcuserdata.
2018-11-19 12:14:27 -08:00
Bart House
f221db4a94
Added NH_INC_DIR to xcode project build settings.
2018-11-19 12:13:58 -08:00
Bart House
bf549e865f
Added project wide build settings for nethack directories.
2018-11-19 12:03:02 -08:00
Bart House
898a22159f
Added building of data to xcode build.
2018-11-19 11:33:11 -08:00
Bart House
4788b10d88
XCode project check-point.
2018-11-19 11:06:57 -08:00
Bart House
3c5556d45e
Fix vi induced build problem.
2018-11-19 09:53:46 -08:00
Bart House
16d5631235
Merge branch 'macosx-curses-fall2018' of https://rodney.nethack.org:20040/git/NHsource into macosx-curses-fall2018
2018-11-19 09:22:32 -08:00
Bart House
aa48ed18e7
Initial check-in of work in progress xcode build of NetHack.
...
Buyer beware. This is a check-point of the xcode work to allow others
to play.
2018-11-19 09:22:11 -08:00
Bart House
360ee21861
Revert "Hint file for macOS X with curses."
...
This reverts commit f7fbbb8cb0 .
2018-11-18 11:45:36 -08:00
Bart House
444d1ec50a
Merge branch 'win-curses' of https://rodney.nethack.org:20040/git/NHsource into win-curses
2018-11-18 09:30:11 -08:00
Bart House
f7fbbb8cb0
Hint file for macOS X with curses.
2018-11-18 09:28:45 -08:00
Bart House
6ba270563c
Build curses if PDCurses is available.
...
There are two ways to enable curses in the build. Either set the
environment variable PDCURSES to a folder containing a PDCurses repository
OR place the PDCurses folder alongside the NetHack source repository.
2018-11-17 23:56:31 -08:00
Bart House
afe828507a
Getting build working.
2018-11-17 14:48:38 -08:00
Bart House
d2436d9f3c
Map curso blinking controlled by win32_cursorblink.
2018-11-16 21:48:00 -08:00
Bart House
dcac95b4b3
Delete GDI objects when map window is destroyed.
2018-11-16 13:50:12 -08:00
Bart House
90562f23c0
Menu check boxes drawn correctly when scaled.
...
Changed from using pattern brush to strech blt when rendering check box.
2018-11-16 13:29:59 -08:00
Bart House
94c4acc144
Made map cursor blink a compile time option.
2018-11-16 13:00:02 -08:00
Bart House
52cbbdafae
Completed map back buffer work and implemented map cursor blink.
...
Map back buffer work is done eliminating all flickering caused by
clears of the front buffer during partial updates.
Implemented a cursor blink in both ascii and tile modes.
Fixed bug where we would lose fit to screen when entering rogue level.
2018-11-16 12:39:04 -08:00
Bart House
3f4090ac38
Remap unicode control codes.
...
When running NetHack.exe in a console set to code page 850, the
multi-byte to wide character mapping will generate unicode values
in the unicode control code range. These values need to be re-mapped
to unicode renderable glyphs using the same mappings we use for
control page 437 otherwise the console font might not render a character
for these unicode control values.
2018-11-15 21:42:23 -08:00
Bart House
fdd4e129a1
Removed temporary comment left in by mistake.
2018-11-15 20:58:15 -08:00
Bart House
1f8c78fb40
Remove commented out line.
2018-11-14 21:08:59 -08:00
Bart House
093dc076ed
Modified RIP dialog to take into account monitor DPI.
2018-11-14 20:44:02 -08:00
Bart House
489abb45f5
Added monitor dpi awareness to NetHackW splash dialog.
2018-11-13 20:48:56 -08:00
Bart House
8069659912
Adjust menu item rendering based on monitor dpi.
2018-11-12 22:40:36 -08:00
Bart House
f67e7c0614
Merge branch 'win-minor' of https://rodney.nethack.org:20040/git/NHsource into win-minor
2018-11-12 21:39:05 -08:00
Bart House
4912149ff2
Implemented back buffer rendering to improve fit to screen rendering
...
quality.
2018-11-12 21:38:32 -08:00
Bart House
0bbc7cb6db
Adjust tile size to bounds of text meterics when in ascii mode.
2018-11-12 19:36:08 -08:00
Bart House
3bb759a9ab
Started work to support per monitor DPI. Using DPI to scale tiles
...
appropriately.
Renamed ntassert to nhassert. (Naming mistake caused by using ntassert
at work).
Re-ordered a few more includes to get window headers included before
nethack headers.
2018-11-12 17:45:22 -08:00
Bart House
f3bc4af242
Removing support for Visual Studio 2015 solution.
2018-11-12 09:13:51 -08:00
Bart House
8944235282
Enforced the inclusion of windows headers before nethack headers.
...
Moved the code page 437 mapping table to winnt.c so that it could be
used in window and console clients.
Added check that fonts support unicode values we use from code page 437.
Use unicode to draw text if font supports it otherwise use ASCII.
2018-11-12 01:58:56 -08:00
Bart House
26171ed9f5
Ignore .vs hidden folders generated by visual studio 2017.
2018-11-10 20:33:30 -05:00
Bart House
20e8482e6e
Fix crash that can occur when panic is called early.
2018-11-10 20:26:20 -05:00
Bart House
0a3f6d17df
Removed the defining of WIN32CONNDEBUG for NethackW.
...
Defined NOTTYGRAPHICS for NethackW.
2018-11-10 20:25:49 -05:00
Bart House
1f877dbca1
Additional changes to xputc_core() and early_raw_print() to manage
...
the cursor position correctly. This is needed to handle raw printing
correctly. Added check for when we might be running off the bottom
of the screen when handling msmsg(). Added runtime checks to keep
cursor always within bounds.
2018-05-13 20:46:43 -07:00
Bart House
53c7cb8c78
Changes to xputc_core to handle cursor correctly.
2018-05-13 18:54:20 -07:00
Bart House
0afd2570cb
Removing temporary debugging code and fixing compiler warnings.
2018-05-13 13:29:13 -07:00
Bart House
3dbbd188d9
Fixing typo.
2018-05-13 12:49:52 -07:00
Bart House
650d5230ec
Fix memory leak. See bug 1169.
2018-05-12 19:45:16 -07:00
Bart House
039687cf5f
Fix for bug 324 (aka H4216). We now will use nhraykey by default if the
...
players keyboard layout is non-english. nhraykey properly handles
non-english input. We also now support changing altkeyhandler in game.
2018-05-12 18:06:23 -07:00
Bart House
1d31a49661
Some nttty.c clean-up.
2018-05-12 15:58:44 -07:00
Bart House
3467b9f087
Added ntassert() mechanism for Windows based port use.
2018-05-12 13:59:06 -07:00
Bart House
f7e665be98
Fix for bug H7132.
...
In nethackw, there can be conflicts between menu accelerators and an extra
choice accelerator. For example, when engraving the using fingers options
conflicts with the unselect all menu accelerator. The extra choice
accelerator should take precedence.
2018-05-08 07:25:24 -07:00
Bart House
b7f351fdbb
Updated console back buffer support to correctly size the buffers as
...
appropriate.
2018-05-06 13:22:36 -07:00
Bart House
6322aec829
Win32TTY: Fix using a console font with wide glyphs
...
Added support to detect when the current console font has glyphs
that are too wide and will cause rendering errors in the console.
If detected, we warn the user and change the code page to 437
and the font to Consolas. At exit, if we had changed the font
and code page then we will restore to the original font and code page.
2017-10-25 10:59:11 +03:00
Bart House
a588541a27
Win32GUI: Gather raw_print text and display it all in single dialog
...
Defined strbuf_t and related routines to support dynamically sized
strings. Modified strip_newline() to strip the last newline in a string
instead of the first.
Simplified splash window code using new strbuf_t.
Prior to exiting game, re-enable getreturn and call wait_synch() in
case there is buffered raw prints that must be displayed to user.
2017-10-25 10:34:27 +03:00
Bart House
c64ae2d28d
Win32GUI: Clear selection counts for perm invent
2017-10-09 23:32:13 +03:00
Bart House
1ec7bed529
Win32GUI: Use a back buffer for all status rendering
...
This eliminates all flickering when status is updated.
2017-10-09 20:43:36 +03:00
Bart House
7c24b420a9
Win32GUI: Fix bug with specifying no color for status hilite.
...
We were mapping NO_COLOR to white instead of the default foreground color.
2017-10-09 14:57:34 +03:00
Bart House
b1f7bd3791
Win32GUI: Set main window background brush to black.
...
Black is a better choice given that the map background
will always be black. This also creates a better polished
experience when all window backgrounds are set to black.
2017-10-09 14:56:46 +03:00
Bart House
8656807b4d
Windows GUI supports WC2_HILITE_STATUS
...
Avoids raw_print on startup
2017-10-08 01:56:18 +03:00
Bart House
b744e2ce1f
Win32GUI: Fix permanent inventory window going away
...
Fix bug where permanent inventory window would go away after
any operation that used the inventory window to pick items. Since
we were hiding the permanent inventory window, this would also
leave a space filled with white, creating jarring visual if
using dark themed window backgrounds.
2017-10-08 01:26:24 +03:00
Bart House
f8760093cc
Set the local working directory when debugging to $BinDir.
...
This is needed to ensure the defaults.nh is found.
2017-10-07 14:25:21 +03:00
Bart House
78756c9bd6
Addressing bug with the use of static dieroll in uhitm.c.
2017-10-01 14:39:35 +03:00
Bart House
d51f74a507
Fix flashing issue that is seen with STATUS_HILITES in Windows port.
2017-10-01 14:32:43 +03:00
Bart House
70ac8a12af
Improvements to build.bat scripts used to build Windows builds. Remove CRT Secure warnings.
2017-09-05 13:14:13 +03:00
Bart House
51f7cb5e9d
Fix build errors with Visual Studio 2017 using latest SDK. We have yet another global namespace collision between window headers and nethack headers. This time it is the macro Protection that is defined before it is used in a function prototype in the windows headers.
2017-09-04 12:56:20 +03:00
Bart House
1bc3cbac7f
Additional changes needed to support Visual Studio 2017.
2017-09-04 12:56:20 +03:00
Bart House
8a5351c079
Upgrade to VS2017 and newer SDK.
2017-09-04 12:56:20 +03:00
Bart House
3614059379
Fix line endings (CRLF and extra space).
2017-09-04 12:56:20 +03:00
Bart House
5b08481637
Adding vs2015 solution file to starting set of files.
2017-09-04 12:56:19 +03:00
Bart House
ceaf2f6109
Create initial vs2017 files from vs2015 files.
2017-09-04 12:56:19 +03:00
Bart House
be4e0992e6
Fix crash that occurs when closing application window while invetory is displayed.
2017-09-04 12:52:18 +03:00
Bart House
497a0b47c8
Fixed compiler warhing of casting int to pointer.
2017-09-04 12:41:53 +03:00
Bart House
4a4193ab37
Fixed compiler warning using pointer as UINT.
2017-09-04 12:41:53 +03:00
Bart House
c9a82e8ae6
Fix compiler warning where we cast 32bit value to pointer.
2017-09-04 12:41:53 +03:00
Bart House
878a18388c
Fixed coding error. strlen() returns size_t causing a size_t sized value pushed onto stack instead of long. On x64 builds, size_t != long. Caught via compiler warning in x64 build.
2017-09-04 12:41:53 +03:00
Bart House
ee61f1b730
Use %p for formatted output of pointers (needed to support x86 and x64 cleanly).
2017-09-04 12:41:53 +03:00
Bart House
1374d148d7
Removing unused function which also contained coding error (calling putc instead of fputc).
2017-09-04 12:41:53 +03:00