Merge branch 'NetHack-3.6.0'

This commit is contained in:
nhmall
2018-05-15 01:21:54 -04:00
20 changed files with 1592 additions and 702 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -136,12 +136,6 @@ register char *op;
return;
}
void
load_keyboard_handler()
{
return;
}
/* this is used as a printf() replacement when the window
* system isn't initialized yet
*/
@@ -176,4 +170,15 @@ more()
return;
}
void
nethack_enter_nttty()
{
return;
}
void
set_altkeyhandler(const char *inName)
{
return;
}
#endif /* TTYSTUBS */

View File

@@ -207,7 +207,7 @@ VA_DECL(const char *, s)
/* error() may get called before tty is initialized */
if (iflags.window_inited)
end_screen();
if (!strncmpi(windowprocs.name, "tty", 3)) {
if (windowprocs.name != NULL && !strncmpi(windowprocs.name, "tty", 3)) {
buf[0] = '\n';
(void) vsprintf(&buf[1], s, VA_ARGS);
Strcat(buf, "\n");
@@ -461,6 +461,31 @@ char *buf;
}
#endif /* RUNTIME_PORT_ID */
/* ntassert_failed is called when an ntassert's condition is false */
void ntassert_failed(const char * exp, const char * file, int line)
{
char message[128];
_snprintf(message, sizeof(message),
"NHASSERT(%s) in '%s' at line %d\n", exp, file, line);
if (IsDebuggerPresent()) {
OutputDebugStringA(message);
DebugBreak();
}
// strip off the newline
message[strlen(message) - 1] = '\0';
error(message);
}
/* nethack_enter_winnt() is the first thing called from main */
void nethack_enter_winnt()
{
#ifdef WIN32CON
nethack_enter_nttty();
#endif
}
#endif /* WIN32 */
/*winnt.c*/