Add popup indicating how sysbot works.

Similar to LiveHex (PKHeX injecting pkm while game is running), this will allow you to r/w your inventory live so that you can quickly swap in items -- example usage: customizing your town with various items :D
This commit is contained in:
Kurt
2020-03-31 19:32:54 -07:00
parent a4ae85ce67
commit f18b013a88
3 changed files with 30 additions and 0 deletions

View File

@@ -59,6 +59,18 @@ internal sealed partial class Settings : global::System.Configuration.Applicatio
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("False")]
public bool SysBotPrompted {
get {
return ((bool)(this["SysBotPrompted"]));
}
set {
this["SysBotPrompted"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("2889584832")]

View File

@@ -11,6 +11,9 @@
<Setting Name="SysBotPort" Type="System.Int32" Scope="User">
<Value Profile="(Default)">6000</Value>
</Setting>
<Setting Name="SysBotPrompted" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
<Setting Name="SysBotPouchOffset" Type="System.UInt32" Scope="User">
<Value Profile="(Default)">2889584832</Value>
</Setting>

View File

@@ -23,6 +23,21 @@ public SysBotUI(Action<byte[]> read, Func<byte[]> write, InjectionType type)
TB_IP.Text = Settings.SysBotIP;
TB_Port.Text = Settings.SysBotPort.ToString();
PopPrompt();
}
private void PopPrompt()
{
if (Settings.SysBotPrompted)
return;
const string info = "This SysBot reads and writes RAM directly to your game when called to Read/Write.";
const string reqd = "Using this functionality requires the sys-botbase sysmodule running on the console." +
"Your console must be on the same network as the PC running this program.";
WinFormsUtil.Alert(info, reqd);
Settings.SysBotPrompted = true;
Settings.Save();
}
private uint GetOffset(InjectionType type)