Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ensata sound register emulation. #851

Merged
merged 3 commits into from
Oct 26, 2024

Conversation

dlbuhtig4096
Copy link

Fix #850.

@dlbuhtig4096
Copy link
Author

This PR should also fix the problem that soft reset is not working when Ensata emulation enabled now.

Please refers to comments on the source file for the details of the fix.

@dlbuhtig4096
Copy link
Author

dlbuhtig4096 commented Oct 24, 2024

Changed the behavior of OpenConsole() on Windows:

  • First, it attempts to AttachConsole(-1) and then uses AllocConsole() in case the first attempt fails.
  • Removed SetConsoleCP(GetACP()) and SetConsoleOutputCP(GetACP()) upon success.

Most first-party games were developed in Japan, where the log is encoded in CP932 (Shift JIS).
For users not using Japanese Windows, setting the output encoding with GetACP() results in corrupted output.
This change will allow users to set a custom code page for the output console beforehand.

@zeromus zeromus merged commit fff5659 into TASEmulators:master Oct 26, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

No Audio when Ensata Emulation Enabled
2 participants