MaKiPL / OpenVIII-monogame

Open source Final Fantasy VIII engine implementation in C# working on Windows and Linux (Android and iOS planned too!) [Monogame]
MIT License
630 stars 58 forks source link

Linux game path finding is just awful #181

Open MaKiPL opened 3 years ago

MaKiPL commented 3 years ago

Currently it looks for pre-configured pathes that lead only to specific user (in this case DEVs). This is a giant no-no We either need to introduce some user-friendly config (or forcing the user to type path on first use) or at least change /home/{user}/... to actually grab from whoami or $(USER)

Task: Replace content of https://github.com/MaKiPL/OpenVIII-monogame/blob/22eb63edcf69b3dda40610bd4d7d401363cbe579/Core/GameDirectoryFinder.cs#L94-L109 with suggestions above

This should be really easy- any junior want to take the challenge? :D

Sebanisu commented 3 years ago

Yeah I figure it'd be replaced with a config file. I was thinking we'd have a launcher like game does that wouldn't let you launch till it was set with the path to the game. You'd be able to set like res and such at the same time.

Though this maybe could be done inside the engine without a launcher maybe using imgui to choose the paths. Though that sounds harder.

I think I had a command line option so you could choose a path by adding it as an argument. Though I'm not sure if that change was ever made live.

Sebanisu commented 3 years ago

I did put in code to pass the arguments to game1.Arguments https://github.com/MaKiPL/OpenVIII-monogame/blob/22eb63edcf69b3dda40610bd4d7d401363cbe579/Core/Game1.cs#L80

That line I'm parsing to check for log=true or log=false. You could use that to grab a path as well.

MaKiPL commented 3 years ago

have a launcher like game does that wouldn't let you launch till it was set with the path to the game. You'd be able to set like res and such at the same time.

Yes and no. No and yes. I'm totally confused- I hate launchers, they make things harder, but.... we also need some user-friendly application for users to config their game, so...

Though this maybe could be done inside the engine without a launcher maybe using imgui to choose the paths. Though that sounds harder.

and this is a perfect solution IMO. We could also add commandline parameter for overwriting pre-found value or saved value

I'll try to implement this either tomorrow or next day after tomorrow