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

Remaining Cleanup Work #1

Open
Sewer56 opened this issue May 19, 2024 · 0 comments
Open

Remaining Cleanup Work #1

Sewer56 opened this issue May 19, 2024 · 0 comments

Comments

@Sewer56
Copy link

Sewer56 commented May 19, 2024

Currently DOOMSona has a few leftover general compatibility problems.

I've addressed them to Jack before release, and added another reminder after release, but I might aswell make sure it gets delivered directly, just in case.

Version & Compatibility with Other Mods:

High Priority:

  • The addresses are hardcoded to the latest Steam version of the game.
    • This causes issue reports from users using the Microsoft Store versions of the game.
    • Please use signature scans.
  • For the Linux users, please check if dotnet (.NET Framework) is installed. That's not guaranteed.
    • Option 1, Avoid the Problem (Maybe Better):

      • Ideally though upgrade the project.
      • Set TargetFramework to net8.0-windows.
      • Set RollForward to Major directly below. (This will let it run on .NET 9,10 etc. down the road)
      • So you use the same .NET version as the R-II launcher, which is guaranteed to exist.
    • Option 2: Detect Missing Framework

  • Hook up the signature scanner to the startup scanner.
    • There is an issue with modding in general where if there are 2 mods scanning for the same signature, one of them will fail because the other mod hooked the place another mod is looking for.
    • Pretty much all R-II mods use IStartupScanner to prevent this (and speed up boot times, as it can scan at 240GB/s+ on modern hardware in parallel).
    • You'll need to load DOOMSona.dll via ReloadedDOOMSonaInstallerLauncher (just copy the ReloadedModStuff as part of its build), inside the Mod.cs file.
    • Then provide an export in DOOMSona.dll. This export would set a sig scanning function to use consisting of pattern and callback. (Callback handles the scan result).
    • And use that export from the C# side to hook it up with IStartupScanner.
    • This already manifested itself in an issue report on my end.

Low Priority:

  • Use a hooking library that performs non-destructive hooks.
    • The mid-function hooks taken from 13AG's Widescreen Fixes Pack (I assume that's the origin) [injector::MakeInline ] don't seem to pay attention to existing hooks.
    • You're asking for compatibility issues here, but at least they're mid-functions, so conflicts are unlikely.
    • Also MakeAbsJMP need to be replaced but that's already noted in source.

Note: I know some of these things are really unnecessarily tedious for native mods. That's why I've been spending 25-30 hours every weekend working on Reloaded-II's replacement. For almost around a year now 😅.

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

No branches or pull requests

1 participant