Convert all Shift_JIS files to UTF-8

This commit is contained in:
kichikuou
2020-02-24 18:06:38 +09:00
parent 9f09c0c2de
commit 7a1cc2a483
27 changed files with 824 additions and 824 deletions
+30 -30
View File
@@ -39,7 +39,7 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
SDL_RenderSetLogicalSize(sdlRenderer, 640, 400);
sdlTexture = SDL_CreateTexture(sdlRenderer, SDL_PIXELFORMAT_ARGB8888, SDL_TEXTUREACCESS_STATIC, 640, 400); // TOOD: pixelformat?
// DIBSection 8bpp * 3 (表, 裏, メニュー)
// DIBSection 8bpp * 3 (表, 裏, メニュー)
for(int i = 0; i < 3; i++) {
hBmpScreen[i] = SDL_CreateRGBSurface(0, 640, 480, 32, 0, 0, 0, 0);
SDL_LockSurface(hBmpScreen[i]);
@@ -47,18 +47,18 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
// TODO: clear surface
// memset(lpBmpScreen[i], 0, 640 * 480 * sizeof(DWORD));
// 仮想VRAMへのポインタ取得
// 仮想VRAMへのポインタ取得
for(int j = 0; j < 480; j++) {
vram[i][j] = surface_line(hBmpScreen[i], j);
}
}
// DIBSection 24bpp * 1 (最終出力先)
// DIBSection 24bpp * 1 (最終出力先)
display_surface = hBmpDest = SDL_CreateRGBSurface(0, 640, 480, 32, 0, 0, 0, 0);
SDL_LockSurface(hBmpDest);
// TODO: clear surface
// フォント
// フォント
TTF_Init();
hFont16 = TTF_OpenFont(fontfile, 16);
hFont24 = TTF_OpenFont(fontfile, 24);
@@ -69,12 +69,12 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
parent->fatal("Cannot open font file %s", fontfile);
}
// カーソル初期化
// カーソル初期化
for(int i = 0; i < 10; i++) {
hCursor[i] = NULL;
}
// GAIJI.DAT読み込み
// GAIJI.DAT読み込み
memset(gaiji, 0, sizeof(gaiji));
FILEIO* fio = new FILEIO();
@@ -105,12 +105,12 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
}
delete fio;
// SYSTEM3 初期化
// SYSTEM3 初期化
// ACG.DAT
strcpy_s(acg, 16, "ACG.DAT");
// パレット
// パレット
memset(program_palette, 0, sizeof(program_palette));
program_palette[0x00] = SETPALETTE16(0x0, 0x0, 0x0);
program_palette[0x01] = SETPALETTE16(0x0, 0x0, 0xa);
@@ -166,9 +166,9 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
memcpy(screen_palette, program_palette, sizeof(program_palette));
// Bコマンド
// Bコマンド
for(int i = 0; i < 10; i++) {
// ウィンドウの初期位置はシステムによって異なる
// ウィンドウの初期位置はシステムによって異なる
switch (nact->crc32) {
case CRC32_BUNKASAI:
SET_TEXT(i, 24, 304, 616, 384, false);
@@ -176,7 +176,7 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
break;
case CRC32_CRESCENT:
SET_TEXT(i, 24, 288, 616, 378, false);
// 本来は横メニュー
// 本来は横メニュー
SET_MENU(i, 464, 50, 623, 240, true);
break;
case CRC32_DPS:
@@ -214,7 +214,7 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
}
// Eコマンド
// Eコマンド
for(int i = 0; i < 20; i++) {
// SET_BOX(i, 0, 0, 0, 631, 399);
SET_BOX(i, 0, 0, 0, 639, 399);
@@ -236,14 +236,14 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
}
}
// 画面選択
// 画面選択
src_screen = dest_screen = 0;
// 画面サイズ
// 画面サイズ
screen_height = 400;
scroll = 400;
// メッセージ表示
// メッセージ表示
text_dest_x = text_w[0].sx;
text_dest_y = text_w[0].sy + 2;
text_space = 2;
@@ -258,7 +258,7 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
text_back_color = 0;
}
// メニュー表示
// メニュー表示
menu_dest_x = 2;
menu_dest_y = 0;
menu_font_size = 16;
@@ -276,7 +276,7 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
draw_hankaku = false;
draw_menu = false;
// CG表示
// CG表示
set_cg_dest = false;
cg_dest_x = cg_dest_y = 0;
for(int i = 0; i < MAX_CG; i++) {
@@ -285,18 +285,18 @@ AGS::AGS(NACT* parent, const char* fontfile) : nact(parent)
get_palette = extract_palette = extract_cg = true;
palette_bank = -1;
// マウスカーソル
// マウスカーソル
cursor_color = 15;
cursor_index = 0;
// フェード状態
// フェード状態
fader = false;
memset(fader_screen, 0, sizeof(fader_screen));
}
AGS::~AGS()
{
// 退避領域の開放
// 退避領域の開放
for(int i = 0; i < 10; i++) {
if(menu_w[i].screen) {
free(menu_w[i].screen);
@@ -312,21 +312,21 @@ AGS::~AGS()
}
}
// カーソル開放
// カーソル開放
for(int i = 0; i < 10; i++) {
if(hCursor[i]) {
SDL_FreeCursor(hCursor[i]);
}
}
// フォント開放
// フォント開放
TTF_CloseFont(hFont16);
TTF_CloseFont(hFont24);
TTF_CloseFont(hFont32);
TTF_CloseFont(hFont48);
TTF_CloseFont(hFont64);
// surface開放
// surface開放
for(int i = 0; i < 3; i++) {
SDL_FreeSurface(hBmpScreen[i]);
}
@@ -369,7 +369,7 @@ void AGS::fade_end()
void AGS::fade_out(int depth, bool white)
{
// 通常画面 → 白黒画面
// 通常画面 → 白黒画面
int fx = fade_x[depth];
int fy = fade_y[depth];
fader = true;
@@ -381,13 +381,13 @@ void AGS::fade_out(int depth, bool white)
}
}
// 画面更新
// 画面更新
invalidate_screen(0, 0, 640, screen_height);
}
void AGS::fade_in(int depth)
{
// 白黒画面 → 通常画面
// 白黒画面 → 通常画面
int fx = fade_x[depth];
int fy = fade_y[depth];
fader = (depth == 15) ? false : true;
@@ -400,7 +400,7 @@ void AGS::fade_in(int depth)
}
}
// 画面更新
// 画面更新
invalidate_screen(0, 0, 640, screen_height);
}
@@ -412,7 +412,7 @@ void AGS::flush_screen(bool update)
uint32* dest = surface_line(hBmpDest, y);
for(int x = 0; x < 640; x++) {
if (nact->sys_ver == 3 && src[x] & 0x80000000) {
// あゆみちゃん物語 フルカラー実写版
// あゆみちゃん物語 フルカラー実写版
dest[x] = src[x] & 0xffffff;
} else {
dest[x] = screen_palette[src[x] & 0xff];
@@ -432,7 +432,7 @@ void AGS::draw_screen(int sx, int sy, int width, int height)
for(int x = sx; x < (sx + width) && x < 640; x++) {
uint32 a=src[x];
if (nact->sys_ver == 3 && src[x] & 0x80000000) {
// あゆみちゃん物語 フルカラー実写版
// あゆみちゃん物語 フルカラー実写版
dest[x] = src[x] & 0xffffff;
} else {
dest[x] = screen_palette[src[x] & 0xff];
@@ -446,7 +446,7 @@ void AGS::draw_screen(int sx, int sy, int width, int height)
for(int x = sx; x < (sx + width) && x < 640; x++) {
uint32 a=src[x];
if (nact->sys_ver == 3 && src[x] & 0x80000000) {
// あゆみちゃん物語 フルカラー実写版
// あゆみちゃん物語 フルカラー実写版
dest[x] = src[x] & 0xffffff;
} else {
dest[x] = screen_palette[src[x] & 0xff];