Skip to content

Cogmind support #303

@aronson

Description

@aronson

Hello, I updated the spreadsheet with my findings, and wanted to chime in on some issues I've faced, and also present some solutions I have that could be adapted to this upstream project.

I have been running the closed-source, MSVC++ Windows 32-bit game Cogmind with sdl12-compat and have run into a few issues. The game ships an old SDL 1.2.14 DLL. It will not accept drop-in replacements of new SDL 1.2 DLLs unless you build with mingw or clang, or apply a manual hack in SDL_FreeWAV.

Issues I've found in sdl12-compat but not fixed:

  • The scroll wheel does not function
  • Pressing/holding right shift on macOS CrossOver Wine will not register the keypress

I've looked into these issues myself, but my ability to debug the scan codes and input hooks is limited and I could use some help.

Issues I've found and fixed with a crude solution:

  • The game crashes with heap corruption a few seconds after firing a weapon
    • This specifically crashes in SDL_FreeWAV because of a hack the developer used long ago
    • One can intercept calls to SDL_FreeWAV, find msvcrt.dll!free, and call that to satisfy the game's behavior. I've tried to apply solutions with the developer a few times, but we have not figured out the correct way for his game's source to allocate the buffer.
    • I'm not sure how this could be selectively applied to only this game. I have a solution here in my fork.
  • The game has ear-splitting audio corruption with the default SDL2 audio driver
    • Manually setting the driver to winmm by setting an environment variable before loading the SDL2 library gets around this issue.
    • This also begs the question of is it within the scope of this project to auto configure this for only one game.

I maintain an sdl12-compat fork, builds, and install instructions for the Cogmind community at the moment. Your project has breathed new life into the game on Apple Silicon platforms where we saw speedups from sub-30 FPS to over 120 FPS by installing the mod. I can provide a gifted copy of the game to an sdl12-compat maintainer in the interest of fixing bugs if needed. Thank you all for contributing to this project :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions