13 Commits

Author SHA1 Message Date
Kawe Mazidjatari
56aba36b8c Codecs: disable Miles bank patch validation
The validation code uses internal structures of the Miles Sound System which is different for each version of the sound engine versions we support, which makes switching banks impossible without recompiling the SDK. The bank patches rarely fail, but if we decide to keep this we should seek for an alternative approach i.e. using the DLL interfaces directly.
2025-02-02 14:58:41 +01:00
Kawe Mazidjatari
2f618bbe04 Miles: use stack buffer for stream file path
Stack buffer of MAX_PATH is more then enough for this, avoid allocating the string to heap. Also made the return value of v_Miles_Initialize const.
2024-11-20 17:24:56 +01:00
Kawe Mazidjatari
328d88213c Miles: fix voice comm bus regression
Regression was caused in commit 3bb4ee625863c1dd503f07e0d480f4b3fd302c48. The new sound engine has breaking changes in its exports. Added shim layer to fix incompatibilities on the export 'MilesSampleSetSourceRaw'.
2024-06-01 02:23:55 +02:00
Kawe Mazidjatari
3bb4ee6258 Miles: upgrade sound engine to v10.0.47.7
Internal structure 'IntProjectData_t' has changed, padding size adjusted to accommodate changes.
Sound engine taken from retail build R5pc_r5-61_J318_CL651503_2020_10_14_18_51.
2024-05-29 17:56:55 +02:00
Kawe Mazidjatari
11f6ec7633 Ebisu: allow overriding global game language setting
The code originally fetches available and selected languages from Origin/EADesktop. The issue however is that its hard to change the language through the Origin/EADesktop app. The second issue is that the languages returned by Origin/EADesktop isn't necvesarily supported by our version of the game, for example, the original implementation of EbisuSDK_GetLanguage() also returns ar_SA, which is supported by the retail version of the game, but our version doesn't have the code to render this language. The code has been rewritten to allow the user to easily change the language using the command line '-language' parameter. The miles code has also been slightly adjusted to fetch the language directly from HEbisuSDK_GetLanguage() instead of miles_language since otherwise we would still error out in engine code as miles_language will be out of sync.
2024-05-07 16:05:57 +02:00
Kawe Mazidjatari
1d36f0aa89 Miles: refer to 'MILES_DEFAULT_LANGUAGE' instead of 'english'
Enforce 'MILES_DEFAULT_LANGUAGE' as the default rather than "english", even though "english" will always be the default. Also marked cvar 'miles_debug' as FCVAR_DEVELOPMENTONLY.
2024-04-23 00:27:01 +02:00
Kawe Mazidjatari
065f86391e Miles: put event queue warnings behind a cvar
These warnings can get verbose, especially if events from the map itself are missing. Put behind a cvar and enabled it by default in development configurations.
2024-04-23 00:15:02 +02:00
Kawe Mazidjatari
c13d323469 Miles: fix bug, add bank patch debug logs and add reversed miles types 2024-04-04 20:19:33 +02:00
Kawe Mazidjatari
fcbf285b80 Miles: add global type and prevent non-existent banks from loading
This patch adds miles globals and additional code to prevent banks from loading that don't exist. It falls back to "english" if requested language isn't installed.
2024-03-16 11:47:59 +01:00
Kawe Mazidjatari
6828901815 Tier1: static construction of ConVar objects during link time
Fully implemented ConVar class so we could statically construct all SDK convars, this avoids a level of indirection, and allows for creating ConVar's everywhere in the project.

This patch also removed the settings tab of the ImGui server browser, as it has threading issues, while it technically never caused a crash yet, it has been removed as there was no point keeping it vs the work required to make it thread save (it only managed 2 convars which are perfectly manageable through cfg's or the in-game console).

Also temporarily disabled the creation of ConVar's in the mod system due to a memory leak, we would allocate and register a convar based on details parsed out of a mod file definition, but never unregister and free it.
2024-02-24 02:15:09 +01:00
Kawe Mazidjatari
e825a1e7a8 IDetour: remove extraneous pointer assignments
Originally, we store the search results in a CMemory instance which we then assign to the actual function pointer. CMemory is just a pointer class; we can assign the results directly to the actual function pointer. This commit reduces a lot of code verbosity, and also reduced roughly 2KiB worth of static pointers in the resulting executable. This commit also officially deprecates the support for any GameDLL's below S3 (Season 3), since it makes more sense to port the assets from earlier/later games back to the version this SDK supports.
2024-01-02 15:21:36 +01:00
Kawe Mazidjatari
e541814482 IDetour: code refactor
Utilize the new IDetour::DetourSetup() code, IDetour::Attach and IDetour::Detach have been removed in favor of this (significantly reduces chance of user error). Since the template check happens in the idetour header, it is much more aggressive on type mismatches, such as a difference in parameter types, between the function and detour, will now raise a compile time error. As a result, some type mismatches have been fixed in this commit as well.
2023-11-26 13:21:20 +01:00
Kawe Mazidjatari
fd3e227a86 Align folder structure with p4 2023-09-19 22:13:22 +02:00