diff --git a/.gitignore b/.gitignore index 4f8be313f..aedf39f50 100644 --- a/.gitignore +++ b/.gitignore @@ -32,6 +32,8 @@ core Makefile # Win32-specific ignores +Debug/ +Release/ binary/ build/ ipch/ diff --git a/src/hack.c b/src/hack.c index 1edfb9f4e..8f82aa296 100644 --- a/src/hack.c +++ b/src/hack.c @@ -1099,7 +1099,7 @@ domove() register struct monst *mtmp; register struct rm *tmpr; register xchar x,y; - struct trap *trap; + struct trap *trap = NULL; int wtcap; boolean on_ice; xchar chainx, chainy, ballx, bally; /* ball&chain new positions */ diff --git a/src/read.c b/src/read.c index 9be9f9390..b6bed9341 100644 --- a/src/read.c +++ b/src/read.c @@ -2031,7 +2031,7 @@ create_particular() { char buf[BUFSZ], *bufp, monclass; int which, tryct, i, firstchoice = NON_PM; - struct permonst *whichpm; + struct permonst *whichpm = NULL; struct monst *mtmp; boolean madeany = FALSE; boolean maketame, makepeaceful, makehostile; @@ -2080,14 +2080,14 @@ create_particular() pline1(thats_enough_tries); } else { if (!randmonst) { - firstchoice = which; - if (cant_revive(&which, FALSE, (struct obj *)0)) { - /* wizard mode can override handling of special monsters */ - Sprintf(buf, "Creating %s instead; force %s?", - mons[which].mname, mons[firstchoice].mname); - if (yn(buf) == 'y') which = firstchoice; - } - whichpm = &mons[which]; + firstchoice = which; + if (cant_revive(&which, FALSE, (struct obj *)0)) { + /* wizard mode can override handling of special monsters */ + Sprintf(buf, "Creating %s instead; force %s?", + mons[which].mname, mons[firstchoice].mname); + if (yn(buf) == 'y') which = firstchoice; + } + whichpm = &mons[which]; } for (i = 0; i <= multi; i++) { if (monclass != MAXMCLASSES) diff --git a/sys/winnt/nhsetup.bat b/sys/winnt/nhsetup.bat index 3cd4e3826..12021483f 100755 --- a/sys/winnt/nhsetup.bat +++ b/sys/winnt/nhsetup.bat @@ -126,6 +126,7 @@ if NOT exist %SRCPATH%\levcomp.vcxproj goto skipvcexpress if NOT exist %SRCPATH%\levstuff.vcxproj goto skipvcexpress if NOT exist %SRCPATH%\recover.vcxproj goto skipvcexpress if NOT exist %SRCPATH%\tiles.vcxproj goto skipvcexpress +if NOT exist %SRCPATH%\nhdefkey.vcxproj goto skipvcexpress copy %SRCPATH%\makedefs.vcxproj %BUILDPATH% >nul copy %SRCPATH%\tile2bmp.vcxproj %BUILDPATH% >nul @@ -140,6 +141,7 @@ copy %SRCPATH%\levcomp.vcxproj %BUILDPATH% >nul copy %SRCPATH%\levstuff.vcxproj %BUILDPATH% >nul copy %SRCPATH%\recover.vcxproj %BUILDPATH% >nul copy %SRCPATH%\tiles.vcxproj %BUILDPATH% >nul +copy %SRCPATH%\nhdefkey.vcxproj %BUILDPATH% >nul echo LIBRARY nhdefkey >%BUILDPATH%\nhdefkey64.def echo LIBRARY nhdefkey >%BUILDPATH%\nhdefkey.def echo EXPORTS >>%BUILDPATH%\nhdefkey.def diff --git a/win/win32/vs2013/NetHack.sln b/win/win32/vs2013/NetHack.sln index 48ea6ef93..3b335b62f 100644 --- a/win/win32/vs2013/NetHack.sln +++ b/win/win32/vs2013/NetHack.sln @@ -58,6 +58,9 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "NetHack", "build\NetHack.vc EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "nhdefkey", "build\nhdefkey.vcxproj", "{6813477F-64B6-4B97-B230-438D0D233385}" + ProjectSection(ProjectDependencies) = postProject + {BA3DD34C-04B7-40D0-B373-9329AA9E8945} = {BA3DD34C-04B7-40D0-B373-9329AA9E8945} + EndProjectSection EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/win/win32/vs2013/NetHack.vcxproj b/win/win32/vs2013/NetHack.vcxproj index 397701d75..cdf4406f7 100644 --- a/win/win32/vs2013/NetHack.vcxproj +++ b/win/win32/vs2013/NetHack.vcxproj @@ -94,7 +94,7 @@ true MaxSpeed true - true + false WIN32;WIN32CON;DLB;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;NDEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions) true ..\win\win32;..\include;..\sys\winnt;..\sys\share;..\win\share;%(AdditionalIncludeDirectories) @@ -152,7 +152,7 @@ true MaxSpeed true - true + false WIN32;WIN32CON;DLB;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;NDEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions) true ..\win\win32;..\include;..\sys\winnt;..\sys\share;..\win\share;%(AdditionalIncludeDirectories) diff --git a/win/win32/vs2013/nhdefkey.vcxproj b/win/win32/vs2013/nhdefkey.vcxproj index 061f1d854..9d5d01666 100644 --- a/win/win32/vs2013/nhdefkey.vcxproj +++ b/win/win32/vs2013/nhdefkey.vcxproj @@ -86,6 +86,7 @@ Disabled WIN32;WIN32CON;_DEBUG;_WINDOWS;_USRDLL;NHDEFKEY_EXPORTS;%(PreprocessorDefinitions) $(ProjectDir)..\include;$(ProjectDir)..\sys\winnt;%(AdditionalIncludeDirectories) + false Windows @@ -110,6 +111,7 @@ Disabled WIN32;WIN32CON;_DEBUG;_WINDOWS;_USRDLL;NHDEFKEY_EXPORTS;%(PreprocessorDefinitions) $(ProjectDir)..\include;$(ProjectDir)..\sys\winnt;%(AdditionalIncludeDirectories) + false Windows @@ -134,6 +136,7 @@ true WIN32;WIN32CON;NDEBUG;_WINDOWS;_USRDLL;NHDEFKEY_EXPORTS;%(PreprocessorDefinitions) $(ProjectDir)..\include;$(ProjectDir)..\sys\winnt;%(AdditionalIncludeDirectories) + false Windows @@ -162,6 +165,7 @@ true WIN32;WIN32CON;NDEBUG;_WINDOWS;_USRDLL;NHDEFKEY_EXPORTS;%(PreprocessorDefinitions) $(ProjectDir)..\include;$(ProjectDir)..\sys\winnt;%(AdditionalIncludeDirectories) + false Windows