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

Added fix for Gothic Playable Teaser #141

Merged
merged 2 commits into from
Oct 8, 2024

Conversation

Root-Core
Copy link
Contributor

The game is unplayable slow without these settings.
It also creates gigabytes of logs, which this fix cleans up.

@Root-Core Root-Core marked this pull request as ready for review September 23, 2024 01:04

def modify_settings() -> None:
# Assure that the settings folder exists
path = Path('GothicRemake/Saved/Config/WindowsNoEditor/')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For sanity, I would use util.get_game_install_path as STEAM_COMPAT_INSTALL_PATH is a Steam property so we can have some guarantees of the path and the files that will be removed. I know the Steam client changes to the base game's directory before running the game, but, unfortunately, some users run GE-Proton outside Steam and its runtime, so we might not even be in the expected directory. At worst, this fix would be creating/removing files in their home directory.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we make sure we are in the right directory before running the fix?
For example, by checking and possibly correcting it in fix.py?

This would make all fixes cleaner, easier to read and implement.

Copy link
Member

@R1kaB3rN R1kaB3rN Sep 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should continue depending on the client to change to the correct directory and in the case of Steam, it's STEAM_COMPAT_INSTALL_PATH. Only the developers can know with certainty what the correct directories are for the game and they typically make it available to the client in some way (e.g., environment variables, configuration files, etc.). I think protonfixes shouldn't attempt to change directories or attempt to find the correct one, unless the developer had failed to inform the client that metadata somehow or if we want to enforce running the 64-bit executable, which typically require to change to a subdirectory of the base game's directory. Therefore, if a client like Lutris or Heroic fails to change to the correct directory, it's on them.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the context of this fix, I think it would be better to use util.get_game_install_path as it would avoid hardcoding any paths specific to the game and support non-Steam clients as they would be able to override STEAR_COMPAT_INSTALL_PATH.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, but yeah. Maybe there should be a prerequisite before applying any fixes if some are going to be manipulating or creating files. Perhaps we can skip applying Steam fixes all together if STEAR_COMPAT_INSTALL_PATH isn't set in the environment...?

def main() -> None:
"""Performance fixes and cleanup of excessive logs"""
modify_settings()
clear_logs()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hard to say if we should do this. Clearing the logs would be a plus, but wouldn't make the game more playable compared to the modify_settings.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personally, though, I would want the logs removed to save some space. 1GB+ of generated logs would be a problem for me and I'd hate it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My thinking was to "fix" what the game was doing wrong. So it could be seen as a kind of "game fix." 😊

It's pretty unlikely to cause any harm, but it might also be seen as outside the scope of what we're aiming for.

@R1kaB3rN
Copy link
Member

R1kaB3rN commented Sep 23, 2024

Also, this game appears to have a 64-bit executable at GothicRemake/Binaries/Win64/GothicRemake.exe and Steam doesn't appear to have a launch option to use it like other titles. Not sure why the file is significantly larger though. Have you already tried running it?

See https://steamdb.info/depot/950671/

@Root-Core
Copy link
Contributor Author

I will check out the 64bit executable when I find the time. Looks interesting.

@Root-Core
Copy link
Contributor Author

The 64-bit executable is actually used, according to btop.

@R1kaB3rN R1kaB3rN merged commit 840e735 into Open-Wine-Components:master Oct 8, 2024
2 checks passed
@Root-Core Root-Core deleted the gothic_pt branch October 8, 2024 17:41
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.

2 participants