What is it with Pixel's official code, and relying on non-standard
stuff? Even his PxTone library had portability issues.
This commit is contained in:
Clownacy 2019-09-02 02:02:25 +01:00
parent 2a70cbe89a
commit 35344c5f4f
11 changed files with 14 additions and 21 deletions

View file

@ -7,7 +7,6 @@
#include "CommonDefines.h"
#include "Draw.h"
#include "File.h"
#include "Frame.h"
#include "Game.h"
#include "Map.h"

View file

@ -5,7 +5,6 @@
#include "WindowsWrapper.h"
#include "Config.h"
#include "File.h"
#include "Tags.h"
static const char* const config_filename = "Config.dat"; // Not the original name

View file

@ -281,7 +281,7 @@ long GetFileSizeLong(const char *path)
}
#ifdef WINDOWS
BOOL PrintBitmapError(char *string, int value)
BOOL PrintBitmapError(const char *string, int value)
{
char path[MAX_PATH];
FILE *fp;
@ -351,7 +351,7 @@ BOOL CenterWindow(HWND hWnd)
}
// TODO - Inaccurate stack frame
BOOL LoadWindowRect(HWND hWnd, char *filename, BOOL unknown)
BOOL LoadWindowRect(HWND hWnd, const char *filename, BOOL unknown)
{
char path[MAX_PATH];
int min_window_width;

View file

@ -13,10 +13,10 @@ int CheckTime(SYSTEMTIME *system_time_low, SYSTEMTIME *system_time_high);
BOOL CheckFileExists(const char *name);
long GetFileSizeLong(const char *path);
#ifdef WINDOWS
BOOL PrintBitmapError(char *string, int value);
BOOL PrintBitmapError(const char *string, int value);
#endif
BOOL IsShiftJIS(unsigned char c);
BOOL CenterWindow(HWND hWnd);
BOOL LoadWindowRect(HWND hWnd, char *filename, BOOL unknown);
BOOL LoadWindowRect(HWND hWnd, const char *filename, BOOL unknown);
BOOL SaveWindowRect(HWND hWnd, const char *filename);
BOOL IsEnableBitmap(const char *path);

View file

@ -31,8 +31,8 @@ int gJoystickButtonTable[8];
HWND ghWnd;
BOOL bFullscreen;
BOOL gbUseJoystick = FALSE;
static BOOL gbUseJoystick = FALSE;
static BOOL bFps = FALSE;
static BOOL bActive = TRUE;
@ -655,24 +655,24 @@ LRESULT __stdcall WindowProcedure(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lPa
break;
case 40002:
DialogBoxParamA(ghInstance, "DLG_ABOUT", hWnd, VersionDialog, NULL);
DialogBoxParamA(ghInstance, "DLG_ABOUT", hWnd, VersionDialog, 0);
break;
case 40004:
if (!OpenVolumeConfiguration(hWnd))
#ifdef JAPANESE
MessageBoxA(hWnd, "â{âèâàü[âÇɦÆÞé­ïNô«é+é½é_é¦é±é+éÁé¢", lpWindowName, NULL);
MessageBoxA(hWnd, "â{âèâàü[âÇɦÆÞé­ïNô«é+é½é_é¦é±é+éÁé¢", lpWindowName, 0);
#else
MessageBoxA(hWnd, "Could not launch volume configuration", lpWindowName, NULL);
MessageBoxA(hWnd, "Could not launch volume configuration", lpWindowName, 0);
#endif
break;
case 40005:
DialogBoxParamA(ghInstance, "DLG_SAVE", hWnd, DebugSaveDialog, NULL);
DialogBoxParamA(ghInstance, "DLG_SAVE", hWnd, DebugSaveDialog, 0);
break;
case 40007:
DialogBoxParamA(ghInstance, "DLG_MUTE", hWnd, DebugMuteDialog, NULL);
DialogBoxParamA(ghInstance, "DLG_MUTE", hWnd, DebugMuteDialog, 0);
break;
}

View file

@ -9,7 +9,6 @@
#include "CommonDefines.h"
#include "Draw.h"
#include "File.h"
#include "NpChar.h"
#include "Tags.h"

View file

@ -9,7 +9,6 @@
#include "Caret.h"
#include "Draw.h"
#include "Game.h"
#include "File.h"
#include "MyChar.h"
#include "NpChar.h"
#include "Sound.h"

View file

@ -9,7 +9,6 @@
#include "ArmsItem.h"
#include "Caret.h"
#include "Draw.h"
#include "File.h"
#include "Flags.h"
#include "Game.h"
#include "MyChar.h"

View file

@ -6,7 +6,6 @@
#include "WindowsWrapper.h"
#include "File.h"
#include "Generic.h"
#include "NpcAct.h"

View file

@ -109,7 +109,7 @@ typedef struct OrgData
void PlayData(void);
void SetPlayPointer(long x); // 再生ポインターを指定の位置に設定 (Set playback pointer to specified position)
// 以下はファイル関係 (The following are related to files)
BOOL OrgData::InitMusicData(const char *path);
BOOL InitMusicData(const char *path);
} ORGDATA;
ORGDATA org_data;
@ -765,7 +765,7 @@ BOOL QuitMMTimer();
//グローバル変数 (Global variable)
/*■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■*/
static UINT ExactTime = 13; // 最小精度 (Minimum accuracy)
static UINT TimerID = NULL;
static UINT TimerID;
static BOOL nameless_flag;
/*■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■*/
@ -799,7 +799,7 @@ BOOL InitMMTimer()
/*■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■*/
BOOL StartTimer(DWORD dwTimer)
{
MMRESULT ret = NULL;
MMRESULT ret = MMSYSERR_NOERROR;
ExactTime = dwTimer;
// タイマーを生成する (Generate timer)
@ -808,7 +808,7 @@ BOOL StartTimer(DWORD dwTimer)
dwTimer, // タイマー時間 (Timer time)
10, // 許容できるタイマー精度 (Acceptable timer accuracy)
(LPTIMECALLBACK)TimerProc, // コールバックプロシージャ (Callback procedure)
NULL, // ユーザーがコールバック関数のdwUserに送る情報値 (Information value sent by user to dwUser in callback function)
0, // ユーザーがコールバック関数のdwUserに送る情報値 (Information value sent by user to dwUser in callback function)
TIME_PERIODIC // タイマー時間毎にイベントを発生させる (Generate an event every timer time)
);

View file

@ -9,7 +9,6 @@
#include "ArmsItem.h"
#include "BossLife.h"
#include "Fade.h"
#include "File.h"
#include "Flags.h"
#include "Frame.h"
#include "Game.h"