Commit Graph

34922 Commits

Author SHA1 Message Date
Lioncash 0df7908025 VideoCommon/Present: Remove use of g_presenter inside Presenter class
There's no need to self reference a global of the class itself when we
can just call the function directly.
2023-12-09 20:15:32 -05:00
Mai dd227fea5a
Merge pull request #12364 from JosJuice/android-emulation-settings-reload
Android: Fix crash after process recreation
2023-12-08 21:24:05 -05:00
Mai 636b892b7c
Merge pull request #12360 from TryTwo/bugfix_wiimote_signal_spam
WiimoteDevice. Bugfix. Remove signal spam while starting a game.
2023-12-08 21:07:51 -05:00
timetravelthree 3b8737d2d7
Fix out of bound write in EfbCopy::ClearEfb 2023-12-09 02:15:42 +01:00
JosJuice a4eff2acc1 Android: Don't call Run before directory initialization
Combined with the previous commits, this finally fixes the bug where
Dolphin had a chance of crashing if you returned to it after Android
killed the Dolphin process.
2023-12-08 19:36:11 +01:00
JosJuice a31214b8c6 Android: Fix EmulationActivity's handling of process recreation 2023-12-08 19:31:12 +01:00
JosJuice 5aa80603d7 Android: Reload EmulationActivity settings on title change
This way, we ensure that game INI settings are properly applied. I don't
think we actually expose the affected settings on a per-game basis in
the UI, but still.
2023-12-08 17:57:30 +01:00
JosJuice 11041e950d Android: Combine reading cutout setting with updateOrientation 2023-12-08 17:56:29 +01:00
LillyJadeKatrin e992225b88 Bugfix - small square in bottom right corner
Fixed a bug in OSUI created by the challenge icons that caused a small rectangle to appear in the bottom right corner of the screen.
2023-12-08 00:33:29 -05:00
Mai e0f4111561
Merge pull request #11663 from JosJuice/android-config-change-callback
Android: Use config changed callback for tracking recursive scan setting
2023-12-07 16:48:02 -05:00
Mai 3a4cf579ff
Merge pull request #12247 from LillyJadeKatrin/retroachievements-challenges
RetroAchievements - Challenge Icons
2023-12-07 16:46:43 -05:00
LillyJadeKatrin caa729f84a Display Active Challenges On Screen
The active challenges, aka the primed achievements, are displayed on screen as a series of icons in the bottom right corner of the screen via OnScreenUI.
2023-12-07 16:02:15 -05:00
JosJuice 4203632c93 Android: Improve GameFileCacheManager comments 2023-12-07 21:09:17 +01:00
JosJuice 3e7a16f225 Android: Use config changed callback for tracking recursive scan setting
This way the Settings class doesn't contain a hardcoded reference to
a specific setting. And Settings.loadSettings no longer calls
getBoolean, which is a step towards fixing the crash when recreating
EmulationActivity after process death.
2023-12-07 21:09:17 +01:00
JosJuice d80f9d53fc Android: Expose config changed callbacks 2023-12-07 21:09:17 +01:00
TryTwo 6bd9488e0a WiimoteDevice. bugfix. Remove signal spam while starting a game.
Emulation state changed signals also update the wiimote connection. The signal here is only needed for wiimote connects/disconnects.

Can fix erroneous debugger behavior during booting, as dolphin will sometimes incorrectly report the state as paused, which leads the debugger widgets to run when they shouldn't.
2023-12-07 12:15:57 -07:00
Mai 2ece642cf8
Merge pull request #12357 from AdmiralCurtiss/ipl-bounds
Core/Boot: Check bounds in Load_BS2().
2023-12-06 19:57:26 -05:00
LillyJadeKatrin 8fbc5960e7 Handle Achievement Un/Primed Events
When an achievement is "primed", a challenge is active, for example completing a portion of the game in under a time limit or without taking damage or using certain items. This is stored in a map in the Achievement Manager (and removed when the achievement is unprimed) so a later commit can display it on screen.
2023-12-06 08:21:06 -05:00
Admiral H. Curtiss fff538e563
Core/Boot: Check bounds in Load_BS2(). 2023-12-05 22:34:35 +01:00
LillyJadeKatrin 2bf6ebcb90 Added achievement hash to non-disc boot paths. 2023-12-05 16:17:18 -05:00
LillyJadeKatrin ebf2ef1d82 Refactored hash process to check prior game ID
If the new game ID is a different title than the previous game ID, the achievement manager is compromised.
2023-12-05 16:17:18 -05:00
LillyJadeKatrin c8d8ca2ff7 Added Disabled flag to Achievement Manager
The Disabled state sits between Game Closed and completely Shutdown - stronger than the former, as it refuses to let a game be opened again until AchievementManager is restored (which only happens upon a fresh core boot) but it isn't completely shut down and will still allow the player to be logged in and access the achievement settings and their (global) achievement header.
2023-12-05 16:17:17 -05:00
LillyJadeKatrin 148c2f3c0d Refactored AchievementManager hash code to take a volume.
This change splits LoadGameAsync into three methods: two HashGame methods to accept either a string filepath or a volume, and a common LoadGameSync that both HashGames call to actually process the code. In the process, some minor cleanup, and the hash resolution now takes place on the work queue asynchronously.
2023-12-05 16:17:11 -05:00
Mai a65246ec3f
Merge pull request #11988 from JosJuice/jit-feature-flags
Jit: Replace "msrBits" with "featureFlags" and use for performance monitor
2023-12-05 03:13:50 -05:00
Mai 2199dd26bb
Merge pull request #12345 from minhaferzz/startup-handler
Android: Fix issue when launching a game when Dolphin is not open
2023-12-05 03:10:41 -05:00
Mai 6e6695c24b
Merge pull request #11904 from LillyJadeKatrin/retroachievements-hardcore-v2
RetroAchievements - Hardcore Mode (V2)
2023-12-05 01:31:54 -05:00
Tilka 7dfea144b9
Merge pull request #12324 from Pokechu22/vertex-loader-dummy-tex-coords
VertexLoader: Fixes and cleanup related to skipped components
2023-12-04 13:06:19 +00:00
Pokechu22 1c62ebc9fb Use ExtensionNumber in Movie.cpp 2023-12-03 11:36:54 -08:00
Mai 27be8c087e
Merge pull request #12295 from sepalani/arp-check
BBA/HLE: Fix GC homebrew if_config not working
2023-12-03 11:26:00 -05:00
Mai 98eda4dc9f
Merge pull request #12351 from TryTwo/bugfix_data_symbols
PPCSymbolDB. Bugfix. Fix .data symbols not loading
2023-12-03 11:17:44 -05:00
JosJuice 05864ceddd PPCAnalyst: Clear crInUse on HLE
This should have been done when rebasing 6cc4f593e5 after the merge of
3a00ff625e. There are no correctness implications as far as I know,
only very minor performance implications.
2023-12-03 14:20:45 +01:00
TryTwo 92532c8d3a PPCSymbolDB. Bugfix. Fix .data symbols not loading, unless they were aligned to 4 bytes.
.data symbols point to memory values and can be any byte or length of bytes (such as a string).
2023-12-03 00:03:28 -07:00
Pokechu22 69cf8b3470 VertexLoader: Use Common::SmallVector 2023-12-02 15:54:52 -08:00
Pokechu22 4116344785 VertexLoader: Remove unnecessary calls to VertexLoader_TextCoord::GetDummyFunction 2023-12-02 15:54:52 -08:00
Pokechu22 36796abc08 VertexLoader: Fix wrong array being used if color 1 is present but color 0 isn't
This worked correctly on the JIT vertex loaders, and for the equivalent case with texture coordinates. I'm not aware of any games this affects (but libogc does mention a semi-related scenario at 6bc0317c7d/gc/ogc/gx.h (L1855-L1857).)
2023-12-02 15:54:52 -08:00
Pokechu22 1ee6824324 VertexLoaderTest: Add test for skipped texture coordinates
Jimmie Johnson's Anything with an Engine is known to use texture coordinate 7 (and only texture coordinate 7) in some cases. There are a lot of possible edge-cases, so this test brute-forces all combinations with coordinates 0, 1, and 2.
2023-12-02 15:54:52 -08:00
Pokechu22 530590d162 VertexLoaderTest: Add test for skipped colors
This test fails with the non-JIT vertex loader due to an issue fixed in a later commit in this PR. (Note that the non-JIT vertex loader is only used on machines where no JIT is available or if COMPARE_VERTEXLOADERS is enabled in VertexLoaderBase.cpp.)
2023-12-02 15:53:59 -08:00
Mai 4f3f208fe4
Merge pull request #12348 from JosJuice/jitarm64-imm-msr-fastmem
JitArm64: Fix updating MEM_REG with imm MSR without fastmem
2023-12-02 17:53:28 -05:00
LillyJadeKatrin 2cb14edafa Add Hardcore switch to Achievement Settings dialog
This adds the actual switch to turn on Hardcore Mode to the settings tab of the Achievements dialog. It is accompanied by a large tooltip warning explaining what it does and when it can be enabled.
The switch is only enabled to be turned on when no game is running, so that games are started in hardcore mode and can only be loaded via the console's memory card, as in the original hardware. Hardcore may be turned off while a game is running, but cannot be turned back on until the game is disabled.
The toggle trigger for hardcore mode also automatically disables the settings that are not allowed during hardcore mode.
Finally, the original flag in AchievementSettingsWidget to set whether things are enabled in hardcore mode (primarily Leaderboards) is replaced with the actual Hardcore Mode setting.
2023-12-02 16:41:17 -05:00
LillyJadeKatrin 6f7e02e201 Disable TAS recording playback in hardcore mode
Play Input Recording would potentially unlock achievements without any player input and needs to be disabled. If a recording is already playing, hardcore mode cannot be enabled.
2023-12-02 16:41:17 -05:00
LillyJadeKatrin 3aebbbb3e7 Disable cheats in hardcore mode
RetroAchievements does not allow cheats such as Action Replay or Gecko in hardcore mode, for fairness.
2023-12-02 16:41:17 -05:00
LillyJadeKatrin 0abfa94bc8 Disable Freelook in hardcore mode
The player getting a better view of their surroundings than the game would normally allow could possibly give the player an advantage over the original hardware, so Freelook is disabled in hardcore mode. To do this, I disable the config flag for Freelook when it is accessed, to make sure that it is disabled whether it was enabled before or after hardcore mode was enabled.
2023-12-02 16:41:16 -05:00
LillyJadeKatrin 1a19a92943 Disable memory patches in hardcore mode
Memory patches would be an easy way to manipulate the memory needed to calculate achievement logic, so they must be disabled. Riivolution patches that do not affect memory are allowed, as they will be hashed with the game file.
2023-12-02 16:41:16 -05:00
LillyJadeKatrin cb2fa9a1f2 Disable Debug Mode in hardcore mode
Debug Mode gives players direct read and write access to memory, which could be used to completely manipulate RetroAchievements logic and therefore is not allowed in hardcore mode.
2023-12-02 16:41:16 -05:00
LillyJadeKatrin c20258d782 Disable slowdown in hardcore mode
Slowing down the emulator would artificially improve reaction times and is therefore disallowed in hardcore mode. Speeds faster than 1x are allowed, but any speed below 1x is scaled back up to 1x.
2023-12-02 16:41:16 -05:00
LillyJadeKatrin 45105822f3 Disable frame advance in hardcore mode
Frame advancing is easily exploitable for slowing down a game and artificially improving reaction times and is not allowed in RetroAchievements hardcore mode.
2023-12-02 16:41:16 -05:00
LillyJadeKatrin 2c40d6ba31 Disable loading state in hardcore mode
While saving states is allowed (especially for the purpose of debugging), RetroAchievements does not allow loading saved states when hardcore mode is on.
2023-12-02 16:41:15 -05:00
LillyJadeKatrin 71f3039f96 Added Hardcore Warning Widget
This widget will be used in several places to notify the player that a feature has been disabled because hardcore mode is on. It includes a button to open the Achievement Settings so that Hardcore Mode may be turned off. Also included is the framework required to open AchievementsWindow specifically on the Settings tab.
2023-12-02 16:41:15 -05:00
LillyJadeKatrin 138e68ef9f Added Hardcore flag to Achievement Settings
Hardcore Mode is a RetroAchievements feature for enabling as close to original hardware as possible, to keep a fair, challenging, and competitive playing field for achievements (which get tallied differently and emphasized more in hardcore) and leaderboards (where it is mandatory) at the cost of several common emulator features that provide advantages, such as state loading and slower emulation speeds.
This commit just adds the flag to the AchievementSettings, with more to come.
2023-12-02 16:41:15 -05:00
JosJuice 253afee315 JitArm64: Fix updating MEM_REG with imm MSR without fastmem
Dolphin would crash when running with a fastmem arena but without
fastmem. This regression was caused by merging 9192128c50 without
adapting it after the merge of 0606433404.
2023-12-02 17:26:33 +01:00