mirror of
https://ghfast.top/https://github.com/StarCitizenToolBox/app.git
synced 2025-06-28 05:34:45 +08:00
能效核心屏蔽功能应用到 RSI启动器,以让开发板使用此功能。
This commit is contained in:
@ -537,7 +537,7 @@ class HomeUIModel extends BaseUIModel {
|
||||
dPrint('stdout: ${result.stdout}');
|
||||
dPrint('stderr: ${result.stderr}');
|
||||
} else {
|
||||
dPrint("set Affinity === $processorAffinity ");
|
||||
dPrint("set Affinity === $processorAffinity launchExe === $launchExe");
|
||||
ProcessResult result = await Process.run("cmd.exe", [
|
||||
'/C',
|
||||
'Start',
|
||||
|
@ -220,14 +220,9 @@ class LoginDialogModel extends BaseUIModel {
|
||||
await Future.delayed(const Duration(seconds: 1));
|
||||
|
||||
await Future.delayed(const Duration(seconds: 3));
|
||||
final confBox = await Hive.openBox("app_conf");
|
||||
final inputGameLaunchECore = int.tryParse(
|
||||
confBox.get("gameLaunch_eCore_count", defaultValue: "0")) ??
|
||||
0;
|
||||
final processorAffinity =
|
||||
await SystemHelper.getCpuAffinity(inputGameLaunchECore);
|
||||
await SystemHelper.getCpuAffinity();
|
||||
|
||||
// TODO 更新启动方式
|
||||
homeUIModel.doLaunchGame(
|
||||
'$installPath\\$executable',
|
||||
["-no_login_dialog", ...launchOptions.toString().split(" ")],
|
||||
|
@ -17,14 +17,14 @@ class SettingUI extends BaseUI<SettingUIModel> {
|
||||
subTitle:
|
||||
"启用:${model.isEnableAutoLogin ? "已启用" : "已禁用"} 设备支持:${model.isDeviceSupportWinHello ? "支持" : "不支持"} 邮箱:${model.autoLoginEmail} 密码:${model.isEnableAutoLoginPwd ? "已加密保存" : "未保存"}",
|
||||
onTap: model.onResetAutoLogin),
|
||||
const SizedBox(height: 12),
|
||||
makeSettingsItem(const Icon(FontAwesomeIcons.microchip),
|
||||
"启动游戏时忽略能效核心( 适用于Intel 12th+ 处理器 ) [实验性功能,请随时反馈]",
|
||||
subTitle:
|
||||
"已设置的核心数量:${model.inputGameLaunchECore} ( 设置需要忽略的处理器的能效心数量,盒子将在使用启动游戏功能时为您修改游戏所运行的CPU参数,当为 0 时不启用此功能 )",
|
||||
onTap: model.setGameLaunchECore),
|
||||
const SizedBox(height: 12),
|
||||
],
|
||||
const SizedBox(height: 12),
|
||||
makeSettingsItem(const Icon(FontAwesomeIcons.microchip),
|
||||
"启动游戏时忽略能效核心( 适用于Intel 12th+ 处理器 ) [实验性功能,请随时反馈]",
|
||||
subTitle:
|
||||
"已设置的核心数量:${model.inputGameLaunchECore} (此功能适用于首页的盒子一键启动 或 工具中的RSI启动器管理员模式,当为 0 时不启用此功能 )",
|
||||
onTap: model.setGameLaunchECore),
|
||||
const SizedBox(height: 12),
|
||||
makeSettingsItem(
|
||||
const Icon(FluentIcons.folder_open), "设置启动器文件(RSI Launcher.exe)",
|
||||
subTitle: model.customLauncherPath != null
|
||||
|
@ -56,7 +56,8 @@ class SettingUIModel extends BaseUIModel {
|
||||
userBox.get("gameLaunch_eCore_count", defaultValue: "0");
|
||||
final input = await showInputDialogs(context!,
|
||||
title: "请输入要忽略的 CPU 核心数",
|
||||
content: "tip:您的设备拥有几个能效核心就输入几,非大小核设备请保持0",
|
||||
content:
|
||||
"Tip:您的设备拥有几个能效核心就输入几,非大小核设备请保持 0\n\n此功能适用于首页的盒子一键启动 或 工具中的 RSI启动器管理员模式,当为 0 时不启用此功能。",
|
||||
initialValue: defaultInput,
|
||||
inputFormatters: [FilteringTextInputFormatter.digitsOnly]);
|
||||
if (input == null) return;
|
||||
|
@ -68,7 +68,7 @@ class ToolsUIModel extends BaseUIModel {
|
||||
_ToolsItemData(
|
||||
"rsilauncher_admin_mode",
|
||||
"RSI Launcher 管理员模式",
|
||||
"在某些情况下 RSI启动器 无法正确获得管理员权限,您可尝试使用该功能以管理员模式运行启动器。",
|
||||
"以管理员身份运行RSI启动器,可能会解决一些问题。\n\n若设置了能效核心屏蔽参数,也会在此应用。",
|
||||
const Icon(FluentIcons.admin, size: 28),
|
||||
onTap: _adminRSILauncher,
|
||||
)
|
||||
|
Reference in New Issue
Block a user