Fix linux compiling

This commit is contained in:
nukeykt 2019-11-14 05:06:48 +09:00 committed by Christoph Oelckers
parent e4c1d0e7c8
commit 708a6ecba6
7 changed files with 14 additions and 13 deletions

View file

@ -12,7 +12,7 @@
#include "config.h"
#include <string>
#include <io.h>
//#include <io.h>
#include <stdio.h>
#include <time.h>

View file

@ -1,8 +1,8 @@
#include "engine.h"
#include <io.h>
#include <fcntl.h>
//#include <io.h>
//#include <fcntl.h>
#include <malloc.h>
// static int globhiz, globloz, globhihit, globlohit;

View file

@ -3409,7 +3409,7 @@ int Query(short nLines, short nKeys, ...)
{
char *str = va_arg(args, char*);
strcpy(strings[i], str);
strupr(strings[i]);
Bstrupr(strings[i]);
int strWidth = MyGetStringWidth(strings[i]);

View file

@ -1,9 +1,9 @@
#include "save.h"
#include <stdio.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <io.h>
//#include <fcntl.h>
//#include <sys/stat.h>
//#include <io.h>
#include "engine.h"
int savegame(int nSlot)

View file

@ -466,7 +466,7 @@ int LoadSound(const char *sound)
int i;
for (i = 0; i < nSoundCount; i++)
{
if (!strnicmp(szSoundName[i], sound, kMaxSoundNameLen))
if (!Bstrncasecmp(szSoundName[i], sound, kMaxSoundNameLen))
return i;
}

View file

@ -21,13 +21,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//-------------------------------------------------------------------------
#include "build.h"
#include "cmdline.h"
#include "common.h"
#include "common_game.h"
#include "compat.h"
#include "keyboard.h"
#include "control.h"
#include "config.h"
#include "exhumed.h"
#include "dynamicgtk.h"
#include "game.h"
#include "grpscan.h"
#include "gtkpixdata.h"

View file

@ -699,8 +699,9 @@ void DrawStatus()
if (bCoordinates)
{
char *cFPS = itoa(lastfps, numberBuf, 10);
printext(xdim - 20, nViewTop, cFPS, kTile159, -1);
sprintf(numberBuf, "%i", lastfps);
// char *cFPS = itoa(lastfps, numberBuf, 10);
printext(xdim - 20, nViewTop, numberBuf, kTile159, -1);
}
// draw ammo count