Commit Graph
235 Commits
Author SHA1 Message Date
kichikuou 56bb588ca7 Support building with Microsoft Visual Studio 2021-01-02 09:10:51 +09:00
kichikuou a12fbcf906 Android: Update SDL2 to 2.0.14 2021-01-01 12:37:22 +09:00
kichikuou 75cbb2bcef Windows: Add "Save Screenshot" menu command 2020-12-31 14:17:55 +09:00
kichikuou 297ce20a83 Warn if crc32 is unknown and -game is not specified 2020-12-30 22:22:18 +09:00
kichikuou fab3b2eaa0 Support propotional fonts 2020-12-30 22:21:59 +09:00
kichikuou d3d820d727 emscripten: Support message skip
Also add flags that control message skip behavior.
2020-12-29 12:09:34 +09:00
kichikuou 46827f35ef Use common menu selection function in all systems 2020-12-24 22:55:33 +09:00
kichikuou 958e922d54 Apply NACT_Sys3 changes to NACT_Sys1, NACT_Sys2
Some fixes / improvements were made only in NACT_Sys3 but not in
NACT_Sys1 and NACT_Sys2. This applies the followings to NACT_Sys[12]:

f680fb3e Add savedir option
ba359b4b Performance tweak
bde689ea Text hook

Especially, this fixes a bug where save files were created not in save
directory, but in game directory.
2020-12-24 22:19:37 +09:00
kichikuou e091bd9c1c Improve message skip
When message skip is enabled while executing cmd_a(), skip starts
immediately.

This also makes messages displayed during skip visible for a moment.
2020-12-24 22:18:52 +09:00
kichikuou c2ff6de675 Stop message skip on unseen text
This makes System3-sdl2 stop message skip when it sees text that has not
been read by the player. Seen / unseen flags are stored in MSGSKIP.DAT
file in the save folder.
2020-12-24 17:12:47 +09:00
kichikuou 3a2d345521 Introduce NACT::message() 2020-12-24 16:54:09 +09:00
kichikuou 067e1e23bd Refectoring: Add is_[12]byte_message() helper functions 2020-12-20 14:44:08 +09:00
kichikuou 33a0595016 Windows: Add "MIDI Sound" menu item
Now "FM Sound" really means FM sound, not MIDI.
2020-12-11 17:15:12 +09:00
kichikuou 2de55f9f4d Windows: FM sound support 2020-12-11 16:49:48 +09:00
kichikuou 6d1a8f7987 Fix an operator precedence bug in nact_sys3.cpp 2020-12-06 15:39:37 +09:00
kichikuou 32448652c9 Fix unsequenced modification and access in nact_sys2.cpp 2020-12-06 15:36:34 +09:00
kichikuou 700927fccb Tweak FM/SSG volume balance 2020-12-06 15:30:10 +09:00
kichikuou 8808dec847 README: Update build instructions 2020-12-05 14:08:03 +09:00
kichikuou 0b729b62e3 Android, emscripten: Stop music before playing next track 2020-12-05 13:58:01 +09:00
kichikuou d2a60ae9d9 MakoFMgen: Take audio sampling rate as a ctor argument 2020-12-03 15:47:06 +09:00
kichikuou 6587460298 Update android/README.md android-0.5.0 2020-11-29 19:47:26 +09:00
kichikuou 15fdee52a8 Android: Bump version to 0.5.0 2020-11-29 19:30:56 +09:00
kichikuou a4133c219d Android: Save sound preference 2020-11-29 19:30:17 +09:00
kichikuou c575fb303f Android: Add system menu items for switching FM / MIDI 2020-11-29 18:27:53 +09:00
kichikuou 602c309c47 Android: Add system menu
The system menu opens with 3-finger touch. Currently, it can only exit
the game.
2020-11-29 18:27:50 +09:00
kichikuou 04206abb77 Android: FM sound support 2020-11-29 18:27:46 +09:00
kichikuou 07da17a00e Pump events in sys_sleep()
This allows handling window events while fading etc.
2020-11-29 12:06:17 +09:00
kichikuou f2139440b6 Defer rendering to idle time
SDL_RenderCopy / SDL_RenderPresent was called too often, which sometimes
caused screen update to fail on Mac.
2020-11-29 12:06:08 +09:00
kichikuou 89d5fdcbc6 CI: Fix emscripten build 2020-11-23 16:38:05 +09:00
kichikuou 0f4f5d2e0d emscripten: Add function for switching FM / MIDI synthesizer 2020-11-23 16:27:08 +09:00
kichikuou d6640b338a MakoFM: optionally take ownership of music data buffer 2020-11-23 14:26:39 +09:00
kichikuou b6a47d8db7 emscripten: FM sound support 2020-11-23 13:51:25 +09:00
kichikuou 4b4053cf1e Add -fm command line option 2020-11-21 14:01:38 +09:00
kichikuou 893f716ef3 Add FM synthesizer support
This adds support for "real" FM sound that can be used instead of MIDI
sound. (Currently only available on platforms where SDL_mixer is used.)

The MakoFM class interprets AMUS.DAT to create a write sequence to the
OPNA registers, from which fmgen generates an audio stream.
2020-11-21 13:40:21 +09:00
kichikuou f4f8b7d104 Fix use-after-free in MCIThread::close() 2020-10-26 18:39:43 +09:00
kichikuou 79b4efa63e MIDI: Generate at least 60 seconds of MIDI data 2020-10-25 14:52:52 +09:00
kichikuou f426bf87e1 Update emscripten to 2.0.7 2020-10-24 18:56:02 +09:00
kichikuou 17ef39abed emscripten: Add SDL_Delay() to ASYNCIFY_REMOVE
This is safe because we use SDL_HINT_EMSCRIPTEN_ASYNCIFY = 0. This
significantly reduces the number of Asyncified functions and reduces the
wasm code size by 47kb.
2020-10-24 18:55:24 +09:00
kichikuou c4c17854f9 MAKO: select_sound() sets title-dependent values in cd_track
Fixes #6.
2020-10-24 18:15:11 +09:00
kichikuou 9ddbf01d23 Minor refactoring of MAKO
- Move select_sound() from NACT to MAKO
- Make cd_track private
2020-10-24 17:53:07 +09:00
kichikuou 4c5ee008cb Android: Fix StringIndexOutOfBoundsException in text input dialog 2020-10-18 15:15:16 +09:00
kichikuou 01608c8fd5 Generate just right amount of MIDI data
Before this, MIDI data was generated until a fixed number of bytes was
reached. After this, MIDI data is generated for the duration of one
playback of the entire music, plus 1-second fade out.
2020-10-17 16:18:02 +09:00
kichikuou bb9fc273ac Windows: Move MCI operation to a background thread
MCI is very slow to open a MIDI file. Not to block the main thread for
hundreds of milliseconds, this moves MCI calls to a separate thread.
2020-10-17 15:59:28 +09:00
kichikuou 932df7e6a3 Windows: Adjust window size after adding menubar 2020-10-11 14:04:07 +09:00
kichikuou b618d61ca5 CI: Address deprecation of add-path and set-env 2020-10-10 16:19:12 +09:00
kichikuou 9637701340 Windows: Implement reset menu command
A bit hacky but works.
2020-10-10 15:26:01 +09:00
kichikuou da53cda5ab Windows: Add menubar
This ressurects the window menubar that was in the original System3 for
Win32.

The reset feature is not implemented yet because it needs more work.
2020-10-10 15:26:01 +09:00
kichikuou 520b542fcc Introduce NACT::on_syswmevent()
This is in preparation for adding more handlers for platform-specific
window messages (e.g. menu commands).
2020-10-10 15:26:01 +09:00
kichikuou 7f94312c58 Rename {initialize,release}_console to platform_{initialize,finalize}
So that other platform-specific setups (e.g. menus) can be done there.
2020-10-10 15:26:01 +09:00
kichikuou 47ac7a81aa Android: Implement string length limit for input dialog 2020-09-06 12:55:14 +09:00