This commit is contained in:
Bitl 2022-02-20 09:40:09 -07:00
parent cecab706b5
commit 4593eee4ce
4 changed files with 42 additions and 29 deletions

View File

@ -25,7 +25,7 @@ public class ScriptFuncs
if (File.Exists(privateKeyPath)) if (File.Exists(privateKeyPath))
{ {
//init vars //init vars
string format = newSigFormat ? "--rbxsig%{0}%{1}" : "%{0}%{1}"; string format = (newSigFormat ? "--rbxsig" : "") + "%{0}%{1}";
byte[] blob = Encoding.Default.GetBytes(File.ReadAllText(privateKeyPath)); byte[] blob = Encoding.Default.GetBytes(File.ReadAllText(privateKeyPath));
if (encodeInBase64) if (encodeInBase64)
@ -158,12 +158,15 @@ public class ScriptFuncs
public static void GenerateScriptForClient(string ClientName, ScriptType type) public static void GenerateScriptForClient(string ClientName, ScriptType type)
{ {
bool shouldUseLoadFile = GlobalVars.SelectedClientInfo.CommandLineArgs.Contains("%useloadfile%");
string execScriptMethod = shouldUseLoadFile ? "loadfile" : "dofile";
string[] code = { string[] code = {
"--Load Script", "--Load Script",
//scriptcontents, //scriptcontents,
(GlobalVars.SelectedClientInfo.SeperateFolders ? "" + (GlobalVars.SelectedClientInfo.SeperateFolders ? "" +
"dofile('rbxasset://../../content/scripts/" + GlobalPaths.ScriptName + ".lua')" : execScriptMethod + "('rbxasset://../../content/scripts/" + GlobalPaths.ScriptName + ".lua')" :
"dofile('rbxasset://scripts/" + GlobalPaths.ScriptName + ".lua')"), execScriptMethod + "('rbxasset://scripts/" + GlobalPaths.ScriptName + ".lua')"),
GetScriptFuncForType(type), GetScriptFuncForType(type),
!string.IsNullOrWhiteSpace(GlobalPaths.AddonScriptPath) ? "dofile('" + GlobalPaths.AddonScriptPath + "')" : "" !string.IsNullOrWhiteSpace(GlobalPaths.AddonScriptPath) ? "dofile('" + GlobalPaths.AddonScriptPath + "')" : ""
}; };

View File

@ -54,6 +54,7 @@ partial class ClientinfoEditor
this.saveAsTextFileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.saveAsTextFileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.textToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.textToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.iNIToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.iNIToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.signScriptManuallyModernClientsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.addToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.addToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.tagsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.tagsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.clientToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.clientToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@ -79,6 +80,8 @@ partial class ClientinfoEditor
this.validatedextrafilesToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.validatedextrafilesToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.argstringToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.argstringToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.newguiToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.newguiToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.signgeneratedjoinscriptToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.usenewsignformatToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.serverToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem(); this.serverToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
this.limitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.limitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.notificationsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.notificationsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@ -161,9 +164,7 @@ partial class ClientinfoEditor
this.checkBox8 = new System.Windows.Forms.CheckBox(); this.checkBox8 = new System.Windows.Forms.CheckBox();
this.textBox2 = new System.Windows.Forms.TextBox(); this.textBox2 = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label(); this.label3 = new System.Windows.Forms.Label();
this.signScriptManuallyModernClientsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.useloadfileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.signgeneratedjoinscriptToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.usenewsignformatToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.menuStrip1.SuspendLayout(); this.menuStrip1.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
@ -320,17 +321,24 @@ partial class ClientinfoEditor
// textToolStripMenuItem // textToolStripMenuItem
// //
this.textToolStripMenuItem.Name = "textToolStripMenuItem"; this.textToolStripMenuItem.Name = "textToolStripMenuItem";
this.textToolStripMenuItem.Size = new System.Drawing.Size(180, 22); this.textToolStripMenuItem.Size = new System.Drawing.Size(95, 22);
this.textToolStripMenuItem.Text = "Text"; this.textToolStripMenuItem.Text = "Text";
this.textToolStripMenuItem.Click += new System.EventHandler(this.saveAsTextFileToolStripMenuItem_Click); this.textToolStripMenuItem.Click += new System.EventHandler(this.saveAsTextFileToolStripMenuItem_Click);
// //
// iNIToolStripMenuItem // iNIToolStripMenuItem
// //
this.iNIToolStripMenuItem.Name = "iNIToolStripMenuItem"; this.iNIToolStripMenuItem.Name = "iNIToolStripMenuItem";
this.iNIToolStripMenuItem.Size = new System.Drawing.Size(180, 22); this.iNIToolStripMenuItem.Size = new System.Drawing.Size(95, 22);
this.iNIToolStripMenuItem.Text = "INI"; this.iNIToolStripMenuItem.Text = "INI";
this.iNIToolStripMenuItem.Click += new System.EventHandler(this.saveAsINIFileToolStripMenuItem_Click); this.iNIToolStripMenuItem.Click += new System.EventHandler(this.saveAsINIFileToolStripMenuItem_Click);
// //
// signScriptManuallyModernClientsToolStripMenuItem
//
this.signScriptManuallyModernClientsToolStripMenuItem.Name = "signScriptManuallyModernClientsToolStripMenuItem";
this.signScriptManuallyModernClientsToolStripMenuItem.Size = new System.Drawing.Size(294, 22);
this.signScriptManuallyModernClientsToolStripMenuItem.Text = "Sign Script Manually (For Modern Clients)";
this.signScriptManuallyModernClientsToolStripMenuItem.Click += new System.EventHandler(this.signScriptManuallyModernClientsToolStripMenuItem_click);
//
// addToolStripMenuItem // addToolStripMenuItem
// //
this.addToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.addToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
@ -443,7 +451,8 @@ partial class ClientinfoEditor
this.argstringToolStripMenuItem, this.argstringToolStripMenuItem,
this.newguiToolStripMenuItem, this.newguiToolStripMenuItem,
this.signgeneratedjoinscriptToolStripMenuItem, this.signgeneratedjoinscriptToolStripMenuItem,
this.usenewsignformatToolStripMenuItem}); this.usenewsignformatToolStripMenuItem,
this.useloadfileToolStripMenuItem});
this.generalToolStripMenuItem.Name = "generalToolStripMenuItem"; this.generalToolStripMenuItem.Name = "generalToolStripMenuItem";
this.generalToolStripMenuItem.Size = new System.Drawing.Size(180, 22); this.generalToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.generalToolStripMenuItem.Text = "General"; this.generalToolStripMenuItem.Text = "General";
@ -539,6 +548,20 @@ partial class ClientinfoEditor
this.newguiToolStripMenuItem.Text = "%newgui%"; this.newguiToolStripMenuItem.Text = "%newgui%";
this.newguiToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click); this.newguiToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
// //
// signgeneratedjoinscriptToolStripMenuItem
//
this.signgeneratedjoinscriptToolStripMenuItem.Name = "signgeneratedjoinscriptToolStripMenuItem";
this.signgeneratedjoinscriptToolStripMenuItem.Size = new System.Drawing.Size(218, 22);
this.signgeneratedjoinscriptToolStripMenuItem.Text = "%signgeneratedjoinscript%";
this.signgeneratedjoinscriptToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// usenewsignformatToolStripMenuItem
//
this.usenewsignformatToolStripMenuItem.Name = "usenewsignformatToolStripMenuItem";
this.usenewsignformatToolStripMenuItem.Size = new System.Drawing.Size(218, 22);
this.usenewsignformatToolStripMenuItem.Text = "%usenewsignformat%";
this.usenewsignformatToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// serverToolStripMenuItem1 // serverToolStripMenuItem1
// //
this.serverToolStripMenuItem1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.serverToolStripMenuItem1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
@ -1238,26 +1261,12 @@ partial class ClientinfoEditor
this.label3.TabIndex = 37; this.label3.TabIndex = 37;
this.label3.Text = "EXE Name:"; this.label3.Text = "EXE Name:";
// //
// signScriptManuallyModernClientsToolStripMenuItem // useloadfileToolStripMenuItem
// //
this.signScriptManuallyModernClientsToolStripMenuItem.Name = "signScriptManuallyModernClientsToolStripMenuItem"; this.useloadfileToolStripMenuItem.Name = "useloadfileToolStripMenuItem";
this.signScriptManuallyModernClientsToolStripMenuItem.Size = new System.Drawing.Size(294, 22); this.useloadfileToolStripMenuItem.Size = new System.Drawing.Size(218, 22);
this.signScriptManuallyModernClientsToolStripMenuItem.Text = "Sign Script Manually (For Modern Clients)"; this.useloadfileToolStripMenuItem.Text = "%useloadfile%";
this.signScriptManuallyModernClientsToolStripMenuItem.Click += new System.EventHandler(this.signScriptManuallyModernClientsToolStripMenuItem_click); this.useloadfileToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// signgeneratedjoinscriptToolStripMenuItem
//
this.signgeneratedjoinscriptToolStripMenuItem.Name = "signgeneratedjoinscriptToolStripMenuItem";
this.signgeneratedjoinscriptToolStripMenuItem.Size = new System.Drawing.Size(218, 22);
this.signgeneratedjoinscriptToolStripMenuItem.Text = "%signgeneratedjoinscript%";
this.signgeneratedjoinscriptToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// usenewsignformatToolStripMenuItem
//
this.usenewsignformatToolStripMenuItem.Name = "usenewsignformatToolStripMenuItem";
this.usenewsignformatToolStripMenuItem.Size = new System.Drawing.Size(218, 22);
this.usenewsignformatToolStripMenuItem.Text = "%usenewsignformat%";
this.usenewsignformatToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
// //
// ClientinfoEditor // ClientinfoEditor
// //
@ -1428,4 +1437,5 @@ partial class ClientinfoEditor
private System.Windows.Forms.ToolStripMenuItem signScriptManuallyModernClientsToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem signScriptManuallyModernClientsToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem signgeneratedjoinscriptToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem signgeneratedjoinscriptToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem usenewsignformatToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem usenewsignformatToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem useloadfileToolStripMenuItem;
} }

View File

@ -476,7 +476,7 @@ public partial class ClientinfoEditor : Form
{ {
bool newFormat = false; bool newFormat = false;
DialogResult res = MessageBox.Show("Would you like to use the newer client signing format featured in newer clients (2014+)?", "Novetus Client SDK - Use New Format?", MessageBoxButtons.YesNo, MessageBoxIcon.Information); DialogResult res = MessageBox.Show("Would you like to use the newer client signing format featured in newer clients (2014+)?", "Novetus Client SDK - Use New Format?", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Information);
if (res == DialogResult.Yes) if (res == DialogResult.Yes)
{ {

BIN
Novetus/build.zip Normal file

Binary file not shown.