added new gui swapping

This commit is contained in:
Bitl 2021-11-20 19:14:43 -07:00
parent fea4bc709e
commit 59e3c0dfb8
8 changed files with 56 additions and 15 deletions

View File

@ -71,6 +71,7 @@ public class FileFormat
Priority = ProcessPriorityClass.RealTime;
InitialBootup = true;
FirstServerLaunch = true;
NewGUI = false;
}
public string SelectedClient { get; set; }
@ -101,6 +102,7 @@ public class FileFormat
public ProcessPriorityClass Priority { get; set; }
public bool InitialBootup { get; set; }
public bool FirstServerLaunch { get; set; }
public bool NewGUI { get; set; }
}
#endregion

View File

@ -155,6 +155,7 @@ public class GlobalFuncs
ini.IniWriteValue(section, "ClientLaunchPriority", ((int)GlobalVars.UserConfiguration.Priority).ToString());
ini.IniWriteValue(section, "InitialBootup", GlobalVars.UserConfiguration.InitialBootup.ToString());
ini.IniWriteValue(section, "FirstServerLaunch", GlobalVars.UserConfiguration.FirstServerLaunch.ToString());
ini.IniWriteValue(section, "NewGUI", GlobalVars.UserConfiguration.NewGUI.ToString());
}
else
{
@ -166,7 +167,7 @@ public class GlobalFuncs
disablehelpmessage, discord, mappath, mapsnip,
graphics, reshade, qualitylevel, style, savebackups, altIP,
disReshadeDel, showNotifs, SB_Name, SB_Address, priority, initialBootup,
firstServerLaunch;
firstServerLaunch, newgui;
INIFile ini = new INIFile(cfgpath);
@ -197,6 +198,7 @@ public class GlobalFuncs
priority = ini.IniReadValue(section, "ClientLaunchPriority", ((int)GlobalVars.UserConfiguration.Priority).ToString());
initialBootup = ini.IniReadValue(section, "InitialBootup", GlobalVars.UserConfiguration.InitialBootup.ToString());
firstServerLaunch = ini.IniReadValue(section, "FirstServerLaunch", GlobalVars.UserConfiguration.FirstServerLaunch.ToString());
newgui = ini.IniReadValue(section, "NewGUI", GlobalVars.UserConfiguration.NewGUI.ToString());
GlobalVars.UserConfiguration.CloseOnLaunch = Convert.ToBoolean(closeonlaunch);
@ -232,6 +234,7 @@ public class GlobalFuncs
GlobalVars.UserConfiguration.Priority = (ProcessPriorityClass)Convert.ToInt32(priority);
GlobalVars.UserConfiguration.InitialBootup = Convert.ToBoolean(initialBootup);
GlobalVars.UserConfiguration.FirstServerLaunch = Convert.ToBoolean(firstServerLaunch);
GlobalVars.UserConfiguration.NewGUI = Convert.ToBoolean(newgui);
string oldMapath = Path.GetDirectoryName(GlobalVars.UserConfiguration.MapPath);
//update the map path if the file doesn't exist and write to config.

View File

@ -58,7 +58,8 @@ public class ScriptFuncs
+ GlobalVars.Loadout + ","
+ md5s + ",'"
+ GlobalVars.UserConfiguration.PlayerTripcode
+ ((GlobalVars.ValidatedExtraFiles > 0) ? "'," + GlobalVars.ValidatedExtraFiles.ToString() + ");" : "',0);");
+ ((GlobalVars.ValidatedExtraFiles > 0) ? "'," + GlobalVars.ValidatedExtraFiles.ToString() + "," : "',0,")
+ GlobalVars.UserConfiguration.NewGUI.ToString().ToLower() + ");";
case ScriptType.Server:
return "_G.CSServer("
+ GlobalVars.UserConfiguration.RobloxPort + ","
@ -71,7 +72,8 @@ public class ScriptFuncs
return "_G.CSSolo("
+ (info.UsesID ? GlobalVars.UserConfiguration.UserID : 0) + ",'"
+ (info.UsesPlayerName ? GlobalVars.UserConfiguration.PlayerName : "Player") + "',"
+ GlobalVars.soloLoadout + ");";
+ GlobalVars.soloLoadout + ","
+ GlobalVars.UserConfiguration.NewGUI.ToString().ToLower() + ");";
case ScriptType.Studio:
return "_G.CSStudio();";
default:

View File

@ -43,6 +43,7 @@
this.groupBox3 = new System.Windows.Forms.GroupBox();
this.label1 = new System.Windows.Forms.Label();
this.comboBox3 = new System.Windows.Forms.ComboBox();
this.NewGUI2011MBox = new System.Windows.Forms.CheckBox();
this.groupBox1.SuspendLayout();
this.groupBox2.SuspendLayout();
this.groupBox3.SuspendLayout();
@ -149,7 +150,7 @@
this.label9.BackColor = System.Drawing.SystemColors.ControlLightLight;
this.label9.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label9.ForeColor = System.Drawing.Color.Red;
this.label9.Location = new System.Drawing.Point(91, 114);
this.label9.Location = new System.Drawing.Point(90, 136);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(234, 13);
this.label9.TabIndex = 84;
@ -176,7 +177,7 @@
this.groupBox2.Controls.Add(this.comboBox1);
this.groupBox2.Controls.Add(this.button1);
this.groupBox2.Controls.Add(this.comboBox2);
this.groupBox2.Location = new System.Drawing.Point(12, 1);
this.groupBox2.Location = new System.Drawing.Point(12, 11);
this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(205, 110);
this.groupBox2.TabIndex = 86;
@ -186,11 +187,12 @@
// groupBox3
//
this.groupBox3.BackColor = System.Drawing.SystemColors.ControlLightLight;
this.groupBox3.Controls.Add(this.NewGUI2011MBox);
this.groupBox3.Controls.Add(this.label1);
this.groupBox3.Controls.Add(this.comboBox3);
this.groupBox3.Location = new System.Drawing.Point(223, 72);
this.groupBox3.Name = "groupBox3";
this.groupBox3.Size = new System.Drawing.Size(172, 39);
this.groupBox3.Size = new System.Drawing.Size(172, 61);
this.groupBox3.TabIndex = 87;
this.groupBox3.TabStop = false;
this.groupBox3.Text = "Other";
@ -198,7 +200,7 @@
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(6, 16);
this.label1.Location = new System.Drawing.Point(3, 15);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(38, 13);
this.label1.TabIndex = 1;
@ -215,18 +217,29 @@
"Above normal",
"High",
"Realtime"});
this.comboBox3.Location = new System.Drawing.Point(50, 12);
this.comboBox3.Location = new System.Drawing.Point(46, 12);
this.comboBox3.Name = "comboBox3";
this.comboBox3.Size = new System.Drawing.Size(120, 21);
this.comboBox3.TabIndex = 0;
this.comboBox3.SelectedIndexChanged += new System.EventHandler(this.comboBox3_SelectedIndexChanged);
//
// NewGUI2011MBox
//
this.NewGUI2011MBox.AutoSize = true;
this.NewGUI2011MBox.Location = new System.Drawing.Point(6, 39);
this.NewGUI2011MBox.Name = "NewGUI2011MBox";
this.NewGUI2011MBox.Size = new System.Drawing.Size(161, 17);
this.NewGUI2011MBox.TabIndex = 76;
this.NewGUI2011MBox.Text = "Toggle 2011L GUI in 2011M";
this.NewGUI2011MBox.UseVisualStyleBackColor = true;
this.NewGUI2011MBox.CheckedChanged += new System.EventHandler(this.NewGUI2011MBox_CheckedChanged);
//
// LauncherFormSettings
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.SystemColors.ControlLightLight;
this.ClientSize = new System.Drawing.Size(407, 134);
this.ClientSize = new System.Drawing.Size(407, 154);
this.Controls.Add(this.groupBox3);
this.Controls.Add(this.groupBox2);
this.Controls.Add(this.groupBox1);
@ -268,5 +281,6 @@
private System.Windows.Forms.GroupBox groupBox3;
private System.Windows.Forms.ComboBox comboBox3;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.CheckBox NewGUI2011MBox;
}
}

View File

@ -46,6 +46,11 @@ namespace NovetusLauncher
GlobalVars.UserConfiguration.ReShade = checkBox5.Checked;
}
private void NewGUI2011MBox_CheckedChanged(object sender, EventArgs e)
{
GlobalVars.UserConfiguration.NewGUI = NewGUI2011MBox.Checked;
}
private void checkBox6_CheckedChanged(object sender, EventArgs e)
{
GlobalVars.UserConfiguration.ReShadeFPSDisplay = checkBox6.Checked;
@ -130,6 +135,7 @@ namespace NovetusLauncher
checkBox5.Checked = GlobalVars.UserConfiguration.ReShade;
checkBox6.Checked = GlobalVars.UserConfiguration.ReShadeFPSDisplay;
checkBox7.Checked = GlobalVars.UserConfiguration.ReShadePerformanceMode;
NewGUI2011MBox.Checked = GlobalVars.UserConfiguration.NewGUI;
comboBox1.SelectedIndex = (int)GlobalVars.UserConfiguration.GraphicsMode;
comboBox2.SelectedIndex = (int)GlobalVars.UserConfiguration.QualityLevel;

View File

@ -23,6 +23,7 @@ Enhancements:
- The master server security warning will now show up once for every Novetus session.
- Novetus now bases your tripcode off of your computer's hardware information. (Powered by https://github.com/davcs86/csharp-uhwid)
- 2011M's GUI is now more accurate to when it released (Mid June 2011).
- You can re-enable the previous GUI by going into Novetus' settings.
Fixes:
- Fixed the URL Override box in the Asset SDK not being functional.

View File

@ -655,9 +655,15 @@ function CSServer(Port,PlayerLimit,ClientEXEMD5,LauncherMD5,ClientScriptMD5,Noti
pcall(function() game.Close:connect(function() NetworkServer:Stop() end) end)
end
function CSConnect(UserID,ServerIP,ServerPort,PlayerName,Hat1ID,Hat2ID,Hat3ID,HeadColorID,TorsoColorID,LeftArmColorID,RightArmColorID,LeftLegColorID,RightLegColorID,TShirtID,ShirtID,PantsID,FaceID,HeadID,IconType,ItemID,ClientEXEMD5,LauncherMD5,ClientScriptMD5,Tripcode,ValidatedScripts,Ticket)
function CSConnect(UserID,ServerIP,ServerPort,PlayerName,Hat1ID,Hat2ID,Hat3ID,HeadColorID,TorsoColorID,LeftArmColorID,RightArmColorID,LeftLegColorID,RightLegColorID,TShirtID,ShirtID,PantsID,FaceID,HeadID,IconType,ItemID,ClientEXEMD5,LauncherMD5,ClientScriptMD5,Tripcode,ValidatedScripts,NewGUI,Ticket)
pcall(function()
id = -1
if NewGUI == true then
id = 1337
end
game:SetPlaceID(id, false)
end)
dofile("rbxasset://scripts\\cores\\StarterScript.lua")
pcall(function() game:SetPlaceID(-1, false) end)
pcall(function() game:GetService("Players"):SetChatStyle(Enum.ChatStyle.ClassicAndBubble) end)
game:GetService("RunService"):Run()
assert((ServerIP~=nil and ServerPort~=nil),"CSConnect Error: ServerIP and ServerPort must be defined.")
@ -761,7 +767,14 @@ function CSConnect(UserID,ServerIP,ServerPort,PlayerName,Hat1ID,Hat2ID,Hat3ID,He
InitalizeTripcode(Player,Tripcode)
end
function CSSolo(UserID,PlayerName,Hat1ID,Hat2ID,Hat3ID,HeadColorID,TorsoColorID,LeftArmColorID,RightArmColorID,LeftLegColorID,RightLegColorID,TShirtID,ShirtID,PantsID,FaceID,HeadID,IconType,ItemID)
function CSSolo(UserID,PlayerName,Hat1ID,Hat2ID,Hat3ID,HeadColorID,TorsoColorID,LeftArmColorID,RightArmColorID,LeftLegColorID,RightLegColorID,TShirtID,ShirtID,PantsID,FaceID,HeadID,IconType,ItemID,NewGUI)
pcall(function()
id = -1
if NewGUI == true then
id = 1337
end
game:SetPlaceID(id, false)
end)
dofile("rbxasset://scripts\\cores\\StarterScript.lua")
game:GetService("RunService"):Run()
local plr = game.Players:CreateLocalPlayer(UserID)

View File

@ -1714,7 +1714,7 @@ local hasGraphicsSlider = false
local recordingVideo = false
local useNewGui = false
local newGuiPlaces = {0,41324860}
local newGuiPlaces = {1337}
-- Hotkeys
local escKey = string.char(27)
@ -2923,12 +2923,12 @@ if UserSettings then
end
delay(0, function()
--[[for i = 1, #newGuiPlaces do
for i = 1, #newGuiPlaces do
if game.PlaceId == newGuiPlaces[i] then
useNewGui = true
break
end
end]]--
end
if useNewGui then
createSettingsDialog().Parent = gui