Esempio n. 1
0
    def run(self) -> None:
        try:
            from grapejuice_common.ipc.dbus_client import dbus_connection
            dbus_connection().extract_fast_flags()

        except DBusException:
            pass

        self.finish()
Esempio n. 2
0
    def player_main():
        from grapejuice_common.features.settings import settings

        if settings.n_player_dialogs_remain > 0:
            settings.n_player_dialogs_remain = settings.n_player_dialogs_remain - 1
            settings.save()

            gtk_stuff.dialog("Currently, the Roblox Player is not confirmed to be working properly with Wine and "
                             "therefore is not supported by the Grapejuice project. Grapejuice will still launcher the "
                             "player, but it will most likely not work.")

        dbus_connection().play_game(grapejuice_common.util.prepare_uri(args.uri))
Esempio n. 3
0
def wine_ok(system_wine: str = None, show_dialog=True):
    from grapejuice_common.features.settings import settings
    if settings.ignore_wine_version.value:
        return True

    from grapejuice_common.ipc.dbus_client import dbus_connection
    from grapejuice_common.gtk.gtk_stuff import dialog

    def prepare_version(s):
        from packaging import version

        if "-" in s:
            match = re.match(r"(wine-.*?)-.*", s)
            if match:
                s = match.group(1)

        if space in s:
            match = space_version_ptn.match(s)

        else:
            match = non_space_version_ptn.match(s)

        assert match is not None

        return version.parse(match.group(1))

    if system_wine is None:
        system_wine = prepare_version(dbus_connection().wine_version())

    else:
        system_wine = prepare_version(system_wine)

    required_wine = prepare_version(variables.required_wine_version())

    def version_to_string(v):
        if v.public:
            return v.public

        if v.base_version:
            return v.base_version

        return repr(v)

    if system_wine < required_wine:
        if show_dialog:
            msg = "Your system has Wine version {} installed, you need at least Wine version {} in order to run Roblox." \
                .format(version_to_string(system_wine), version_to_string(required_wine))

            dialog(msg)

        return False

    return True
Esempio n. 4
0
def func_studio(args):
    uri = grapejuice_common.util.prepare_uri(args.uri)
    if uri:
        is_local = False
        if not uri.startswith("roblox-studio:"):
            uri = "Z:" + uri.replace("/", "\\")
            is_local = True

        if is_local:
            dbus_connection().edit_local_game(uri)
        else:
            dbus_connection().edit_cloud_game(uri)

    else:
        dbus_connection().launch_studio()
Esempio n. 5
0
 def run(self) -> None:
     from grapejuice_common.ipc.dbus_client import dbus_connection
     dbus_connection().launch_studio()
     self.finish()
Esempio n. 6
0
def install_roblox():
    from grapejuice_common.ipc.dbus_client import dbus_connection
    dbus_connection().install_roblox()