Heroic-Games-Launcher / HeroicGamesLauncher

A games launcher for GOG, Amazon and Epic Games for Linux, Windows and macOS.
https://heroicgameslauncher.com
GNU General Public License v3.0
8.3k stars 439 forks source link

Relax restrictions on sideloaded game titles #3757

Open mtkennerly opened 6 months ago

mtkennerly commented 6 months ago

Problem description

Right now, sideloaded game titles cannot contain several special characters:

https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/blob/ac0a8efc5f529a173608d8aca8ea42c3040fdc0e/src/frontend/screens/Library/components/InstallModal/SideloadDialog/index.tsx#L69

This is a bit surprising since non-sideloaded games don't have that restriction. For example, + is not allowed, even though my non-sideloaded copy of Cave Story+ is listed without issue.

Feature description

It would be nice to lift this restriction. The title can always be sanitized elsewhere as needed, like for folder names (or that could use the auto-generated app_name).

Alternatives

No response

Additional information

No response

yoanhg421 commented 6 months ago

Also I want to add that the game Title for Sideloaded games has a character limit, which makes it hard to add games like:

"Shadow Tactics: Blades of the Shogun - Aiko's Choice" "Half Minute Hero: Super Mega Neo Climax Ultimate Boy"

Can the prefix folder and the game Title be different?

casasfernando commented 6 months ago

I faced both problems mentioned above. Would love to see this improvement implemented.

casasfernando commented 6 months ago

Can the prefix folder and the game Title be different?

I wondering about the same. I found that the title value is limited to 40 characters:

https://github.com/Heroic-Games-Launcher/HeroicGamesLauncher/blob/ac0a8efc5f529a173608d8aca8ea42c3040fdc0e/src/frontend/screens/Library/components/InstallModal/SideloadDialog/index.tsx#L314

Not sure if there is a strong reason for this or if it was an arbitrary value selected at the time of implementing the sideload games feature (the title must have a max length although 40 seems to be a bit low to me) and was not revisited.

I suppose the idea of having the game directory name matching the game title make things more intuitive for the user, although it has the problems mentioned in this issue.

It would be great to hear from the team about this, based on their feedback I can work on a PR to address the problems reported in this issue.