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

Game management improvements #13008

Merged
merged 5 commits into from
Dec 9, 2022
Merged

Game management improvements #13008

merged 5 commits into from
Dec 9, 2022

Conversation

elad335
Copy link
Contributor

@elad335 elad335 commented Dec 3, 2022

  • Add an option to create a desktop and start menu shortcut when installing PKG of a bootable game.
  • Make game shortcuts not using hardcoded file paths but instead use game serial in order to resolve the boot path. So it works even if the disc game directory has been moved. This is done using the feature detailed below.
  • Add CLI support for booting games using PS3 filesystem paths and TITLE ID.
    • Boot by TITLE_ID example: rpcs3.exe --no-gui "%RPCS3_GAMEID%:BCES01584"
    • Boot using PS3 filesystem example: rpcs3.exe --no-gui "%RPCS3_VFS%:dev_hdd0/game/NPUB30695/USRDIR/EBOOT.BIN"
  • Windows only: Create the directory RPCS3/game/shortcuts/ where shortcuts are created when installing PKGs regardless of user consent. Allows simulating a game library without even opening RPCS3 UI. Also allows searching games by title and booting it from the file explorer.
  • Savestates: fix Emulator::m_dir state on savestate load.
  • Fixed the creation of "RPCS3/games/Disc Games Can Be Put Here For Automatic Detection.txt" file.

@elad335 elad335 force-pushed the games-gui branch 3 times, most recently from e881c90 to 2a76753 Compare December 3, 2022 10:59
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
rpcs3/main.cpp Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
@Megamouse Megamouse added GUI CLI Anything that involves starting RPCS3 through the command line interface labels Dec 3, 2022
@elad335
Copy link
Contributor Author

elad335 commented Dec 3, 2022

image

Ignore the 0 it's just for internal test.

rpcs3/Crypto/unpkg.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/main_window.cpp Outdated Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
rpcs3/Emu/System.cpp Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
@elad335 elad335 force-pushed the games-gui branch 8 times, most recently from a141ec8 to b558672 Compare December 3, 2022 17:13
@elad335 elad335 requested a review from Megamouse December 3, 2022 17:13
@elad335 elad335 force-pushed the games-gui branch 5 times, most recently from 005004a to 0c8940f Compare December 3, 2022 17:47
};


for (const auto& [location_string, location, to_install] : installing_locations)
Copy link
Contributor

Choose a reason for hiding this comment

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

Use the struct here.
This notation shouldn't be used if a proper type exists

@@ -280,6 +280,7 @@ class Emulator final

void SetUsr(const std::string& user);

static std::string GetBackgroundPicturePath(const std::string& sfo_dir, const std::string& title_id);
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think this is the correct function.
This one gets the background for the shader dialogs

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed.

Allowing to move of game directories without having to update the shortcut path. (as long as it is registered within RPCS3 UI).
@elad335 elad335 force-pushed the games-gui branch 2 times, most recently from 49b91a7 to 3ab206a Compare December 9, 2022 08:52
@Nekotekina Nekotekina merged commit a18b46d into RPCS3:master Dec 9, 2022
Comment on lines +1016 to +1024
const QIcon icon = gui::utils::get_app_icon_from_path(rpcs3::utils::get_sfo_dir_from_game_path(boot_path + "/../../"), std_title_id);
QPixmap pix = icon.pixmap(icon.actualSize(QSize(1000, 1000)));
QByteArray bytes;
QBuffer buffer(&bytes);
buffer.open(QIODevice::ReadWrite);
pix.save(&buffer, "PNG");
tmp_file.write(bytes.data(), bytes.size());

std::string icon_path = sstr(tmp_file.fileName());
Copy link
Contributor

Choose a reason for hiding this comment

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

why?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLI Anything that involves starting RPCS3 through the command line interface GUI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants