kichikuou
cfa9dc3502
Make BGM setup easy
...
This changes the default value of cdrom_device to "playlist.txt" so that
users can prepare BGM simply by putting a file named "playlist.txt" in
the game directory.
Also, if the playlist file is not found but there is a "_inmm.ini" file
in the game directory, load it as a playlist (but unlike the normal
playlist format, the first line corresponds to track 2). This makes some
archived games work without any configuration.
2020-08-06 17:20:27 +09:00
kichikuou
f978c43ee1
Move mmap-related code to mmap.{h,c}
...
And add Windows implementation.
2020-08-06 15:09:51 +09:00
kichikuou
7871bb9328
Fix DEBUG_COMMAND macro
2020-08-06 14:59:33 +09:00
kichikuou
ab32b1792f
Do not display message argument of System 3.9 H/HH/X commands
...
This matches the behavior of System39.exe.
2020-08-02 15:38:12 +09:00
kichikuou
98d0a13a20
Change the underlying type of boolean to C99 _Bool
2020-08-02 14:07:51 +09:00
kichikuou
5456ac4219
Remove unused ERROR constant
2020-08-02 13:46:44 +09:00
kichikuou
f258ae42b1
Windows: Remember last selected game folder in registry
2020-08-02 13:41:34 +09:00
kichikuou
6580b864c0
Windows: Localize game-folder chooser dialog
2020-08-02 13:41:34 +09:00
kichikuou
bfd8e3e55a
Windows: Add app icon
2020-08-02 13:41:34 +09:00
kichikuou
d2c861ad53
Windows: Let the user select a game folder when launched without arguments
2020-08-01 21:43:20 +09:00
kichikuou
8a395a57e4
Windows: Load profile from registry
...
This allows xsystem35 to use the font paths written to the registry by
the installer.
2020-08-01 21:43:20 +09:00
kichikuou
6706348c11
Make DWORD definition not to conflict with windows.h
2020-08-01 21:43:20 +09:00
kichikuou
730b15dfca
Refactor debug output macros
2020-07-25 22:01:21 +09:00
kichikuou
ad6c84db4d
Clean up xsys35rc.sample
2020-07-25 17:57:49 +09:00
kichikuou
9053583517
Do UTF-8 conversion for filenames in cmd*.c
2020-07-25 17:09:08 +09:00
kichikuou
07f8f8a5f8
initGameResourceFromDir: Stop prepending CWD to filenames
2020-07-25 14:48:41 +09:00
kichikuou
9f244c3dee
Fix filecheck.c issues
...
- Use _wfopen on Windows, to avoid garbled filenames.
- The -savekanji option is removed. Now character encoding of file paths
is assumed to be UTF-8 on non-windows.
- On all platforms, data files are also searched for in current
directory.
2020-07-25 13:17:03 +09:00
kichikuou
2e895ed3ae
Fix a compiler warning
2020-07-24 20:09:29 +09:00
kichikuou
b5010df10d
Add helper functions for number formatting
...
And use it from H, HH, MH, and MHH commands.
2020-07-24 17:06:30 +09:00
kichikuou
fc5f89912e
Fix zen2han
...
To match the behavior of "ZH 1" in System 3.9.
2020-07-24 16:30:03 +09:00
kichikuou
70ea305ca9
Refactor hankaku.c
2020-07-24 16:17:18 +09:00
kichikuou
b4eb18c938
Add test for hankaku.c
2020-07-24 15:42:48 +09:00
kichikuou
b9e0d97156
Fix utf2sjis() for KATAKANA MIDDLE DOT character
2020-07-24 14:53:59 +09:00
kichikuou
350d8bb367
Remove unused sys_getConvString()
2020-07-24 13:21:48 +09:00
kichikuou
fb10cbc52d
Add unittest.h with some assertion macros
2020-07-24 12:46:14 +09:00
kichikuou
55976a5816
Merge hankana2sjis.c into hankaku.c
2020-07-24 11:30:07 +09:00
kichikuou
827f98d24a
Remove ttfont_{gothic,mincho}_code .xys35rc parameters
...
These are no longer effective as we have dropped SJIS charmap support.
This also removes the codeconv field from FONT struct.
2020-07-24 10:00:43 +09:00
kichikuou
50b3812364
Convert gametitle.h to utf-8
2020-07-23 22:50:43 +09:00
kichikuou
616534621e
Fix ShString.ExchangeString
...
And add a test.
2020-07-23 18:08:58 +09:00
kichikuou
1f5ec7a9a9
Simplify string functions
2020-07-23 17:04:37 +09:00
kichikuou
d15c770b4b
Fix strGetCharType and strGetLengthASCII
2020-07-23 16:55:49 +09:00
kichikuou
60bb70c456
Fix strCheckASCII and strCheckSJIS
...
They were referencing wrong string variables.
2020-07-23 16:36:03 +09:00
kichikuou
52322345b5
Fix MG7 command
...
This fixes a regression bug introduced by 86470e5 .
2020-07-23 16:31:35 +09:00
kichikuou
66693ad39a
font_freetype2: Drop support for SJIS character map
...
Nowadays, it's safe to assume that fonts have a Unicode character map.
2020-07-23 15:01:46 +09:00
kichikuou
73fab9b628
Remove unused functions in utfsjis.c
2020-07-23 13:53:25 +09:00
kichikuou
bdfe0e8077
Remove sjis2lang and lang2sjis macros
...
There's no plan to use any other "native" character encodings than
UTF-8.
2020-07-23 13:53:08 +09:00
kichikuou
03f8af2241
Simplify registerGameFiles()
2020-07-12 14:25:34 +09:00
kichikuou
c03b6cf6b5
Embed GameResource in NACTINFO
2020-07-12 14:17:31 +09:00
kichikuou
1a3b779ace
Use const strings for file names
2020-07-12 13:41:57 +09:00
kichikuou
4c58510a37
CMake: Introduce src_lib library
...
To avoid compiling test targets twice.
2020-07-12 13:01:31 +09:00
kichikuou
b4c729a1f6
initGameResourceFromDir: Detect non-{ald,ain} files too
...
Now BGI, WAI and other files can be used without writing a .gr file.
2020-07-12 12:09:01 +09:00
kichikuou
daf5098530
Add test for initGameResourceFromDir
2020-07-12 11:46:39 +09:00
kichikuou
3d70d00bce
Add unit test for gameresource.c
2020-07-11 19:12:45 +09:00
kichikuou
f2fbf54c32
Move registerGameFiles to xsystem35.c
2020-07-11 18:34:27 +09:00
kichikuou
b4d2c0832e
Clean up gameresource.c
2020-07-11 18:34:24 +09:00
kichikuou
d777b18b55
Game Resource: Allow file names containing spaces
2020-07-11 18:23:39 +09:00
kichikuou
7b3efd9aaa
Move *.gr reader code to gameresource.c
2020-07-11 18:22:05 +09:00
Nunuhara Cabbage
aa87e3e8c0
Fix segfault when non-existent font specified
2020-07-10 23:43:46 -07:00
kichikuou
1cd949f597
CMake: Fix X11 + SDL_mixer build
...
Stop using SDL2_FOUND to determine if SDL2 should be used or not,
because it may be defined as a side effect of
pkg_check_modules(SDL2_mixer).
2020-06-27 15:05:56 +09:00
kichikuou
426cdaa836
Fix compatibility issues around maximum index of array variables
...
The second argument of DC command specifies the maximum index of the new
array. That means, `DC _,n,_:` allocates an array of size n+1 (a[0] to
a[n]).
This patch makes sure various D commands work with a[n], and a[n] is
correctly saved and loaded.
Now loadSysVar() does not shrink array variables using the data count in
the save file, so that files saved by old xsystem35 binary can be safely
loaded. This also matches the behavior of System3.9.
2020-06-27 13:16:22 +09:00