more splash work

This commit is contained in:
Bitl 2021-10-29 18:42:25 -07:00
parent 4d1267aff4
commit 81fec2aca8
8 changed files with 546 additions and 102 deletions

View File

@ -7,45 +7,59 @@ using System.Linq;
using System.Windows.Forms;
#endregion
#region Splash Compatibility Definition
public enum SplashCompatibility
{
None,
Normal,
Stylish
}
#endregion
#region Splash Definition
public class Splash
{
public Splash(string text)
public Splash(string text, bool specialSplashMode = false)
{
if (text.Contains('|'))
{
string[] subs = text.Split('|');
SplashText = subs[0];
SplashContext = subs[1];
TextArray = text.Split('|');
SplashText = TextArray[0];
SplashContext = TextArray[1];
if (SplashText.Contains("[normal]"))
{
Compatibility = SplashCompatibility.Normal;
}
else if (SplashText.Contains("[stylish]"))
{
Compatibility = SplashCompatibility.Stylish;
}
else
{
Compatibility = SplashCompatibility.None;
}
SplashText = SplashText.Replace("[normal]", "").Replace("[stylish]", "");
IsSpecialSplash = specialSplashMode;
}
else
{
SplashText = text;
SplashContext = "";
}
}
//text
public string SplashText { get; set; }
//context
public string SplashContext { get; set; }
}
#endregion
SplashText = DecodeSplashString(SplashText);
SplashContext = DecodeSplashString(SplashContext);
#region Special Splash Definition
public class SpecialSplash : Splash
{
public SpecialSplash(string text) : base(text)
{
if (text.Contains('|'))
if (IsSpecialSplash && text.Contains('|'))
{
string[] subs = text.Split('|');
int index = 2;
string date = "";
if (index >= 0 && index < subs.Length)
if (index >= 0 && index < TextArray.Length)
{
date = subs[index];
date = TextArray[index];
}
else
{
@ -138,13 +152,33 @@ public class SpecialSplash : Splash
return weekday;
}
//date we should start appearing
public static string DecodeSplashString(string text)
{
CryptoRandom random = new CryptoRandom();
DateTime now = DateTime.Now;
return text.Replace("%name%", GlobalVars.UserConfiguration.PlayerName)
.Replace("%randomtext%", SecurityFuncs.RandomString(random.Next(2, (GlobalVars.UserConfiguration.LauncherStyle == Settings.Style.Stylish ? 64 : 32))))
.Replace("%version%", GlobalVars.ProgramInformation.Version)
.Replace("%year%", now.Year.ToString())
.Replace("%day%", now.Day.ToString())
.Replace("%month%", now.Month.ToString())
.Replace("%nextyear%", (now.Year + 1).ToString())
.Replace("%newline%", "\n")
.Replace("%branch%", GlobalVars.ProgramInformation.Branch)
.Replace("%nextbranch%", (Convert.ToDouble(GlobalVars.ProgramInformation.Branch) + 0.1).ToString());
}
public string SplashText { get; set; }
public string SplashContext { get; set; }
public SplashCompatibility Compatibility { get; set; }
public bool IsSpecialSplash { get; set; }
public string[] TextArray { get; }
public DateTime? SplashFirstAppearanceDate { get; set; }
//date we should stop appearing
public DateTime? SplashEndAppearanceDate { get; set; }
public DateTime? SplashDateStopAppearingAllTheTime { get; set; }
public DateTime? SplashDateStartToAppearLess { get; set; }
//weekdays.
public DayOfWeek? SplashWeekday { get; set; }
}
#endregion
@ -152,10 +186,12 @@ public class SpecialSplash : Splash
#region Splash Reader
public static class SplashReader
{
private static string missingno = "missingno|No Splashes Found.";
private static Splash RandomSplash()
{
CryptoRandom random = new CryptoRandom();
Splash missingsplash = new Splash("missingno|No Splashes Found.");
Splash missingsplash = new Splash(missingno);
Splash splash = missingsplash;
try
@ -170,47 +206,11 @@ public static class SplashReader
try
{
bool checkStylishSplash = true;
Splash generatedSplash = splashes[random.Next(0, splashes.Count)];
while (checkStylishSplash)
{
if (generatedSplash.SplashText.Contains("[stylish]"))
{
if (GlobalVars.UserConfiguration.LauncherStyle == Settings.Style.Stylish)
{
generatedSplash.SplashText = generatedSplash.SplashText.Replace("[stylish]", "");
splash = generatedSplash;
checkStylishSplash = false;
}
else
{
generatedSplash = splashes[random.Next(0, splashes.Count)];
}
}
else if (generatedSplash.SplashText.Contains("[normal]"))
{
if (GlobalVars.UserConfiguration.LauncherStyle != Settings.Style.Stylish)
{
generatedSplash.SplashText = generatedSplash.SplashText.Replace("[normal]", "");
splash = generatedSplash;
checkStylishSplash = false;
}
else
{
generatedSplash = splashes[random.Next(0, splashes.Count)];
}
}
else
{
splash = generatedSplash;
checkStylishSplash = false;
}
}
splash = splashes[random.Next(0, splashes.Count)];
}
catch (Exception ex)
{
GlobalFuncs.LogExceptions(ex);
try
{
splash = splashes[0];
@ -241,7 +241,7 @@ public static class SplashReader
private static Splash GetSpecialSplash()
{
Splash missingsplash = new Splash("missingno|No Splashes Found.");
Splash missingsplash = new Splash(missingno);
Splash returnsplash = missingsplash;
DateTime now = DateTime.Now;
@ -254,15 +254,30 @@ public static class SplashReader
}
string[] splashes = File.ReadAllLines(GlobalPaths.ConfigDir + "\\splashes-special.txt");
List<SpecialSplash> specialsplashes = new List<SpecialSplash>();
List<Splash> specialsplashes = new List<Splash>();
foreach (var splash in splashes)
{
specialsplashes.Add(new SpecialSplash(splash));
specialsplashes.Add(new Splash(splash, true));
}
foreach (var specialsplash in specialsplashes)
{
if (specialsplash.Compatibility == SplashCompatibility.Stylish)
{
if (GlobalVars.UserConfiguration.LauncherStyle != Settings.Style.Stylish)
{
continue;
}
}
else if (specialsplash.Compatibility == SplashCompatibility.Normal)
{
if (GlobalVars.UserConfiguration.LauncherStyle == Settings.Style.Stylish)
{
continue;
}
}
if (specialsplash.SplashFirstAppearanceDate != null)
{
if (specialsplash.SplashEndAppearanceDate != null)
@ -315,7 +330,7 @@ public static class SplashReader
return returnsplash;
}
public static Splash GetSplash()
private static Splash GetSpecialOrNormalSplash()
{
Splash splash = GetSpecialSplash();
CryptoRandom random = new CryptoRandom();
@ -326,24 +341,45 @@ public static class SplashReader
splash = RandomSplash();
}
splash.SplashText = EncodeSplashString(splash.SplashText);
splash.SplashContext = EncodeSplashString(splash.SplashContext);
return splash;
}
public static string EncodeSplashString(string text)
public static Splash GetSplash()
{
CryptoRandom random = new CryptoRandom();
DateTime now = DateTime.Now;
Splash generatedSplash = GetSpecialOrNormalSplash();
return text.Replace("%name%", GlobalVars.UserConfiguration.PlayerName)
.Replace("%randomtext%", SecurityFuncs.RandomString(random.Next(2, (GlobalVars.UserConfiguration.LauncherStyle == Settings.Style.Stylish ? 64 : 32))))
.Replace("%version%", GlobalVars.ProgramInformation.Version)
.Replace("%year%", now.Year.ToString())
.Replace("%nextyear%", (now.Year + 1).ToString())
.Replace("%day%", now.Day.ToString())
.Replace("%month%", now.Month.ToString());
bool checkStylishSplash = true;
while (checkStylishSplash)
{
if (generatedSplash.Compatibility == SplashCompatibility.Stylish)
{
if (GlobalVars.UserConfiguration.LauncherStyle == Settings.Style.Stylish)
{
checkStylishSplash = false;
}
else
{
generatedSplash = GetSpecialOrNormalSplash();
}
}
else if (generatedSplash.Compatibility == SplashCompatibility.Normal)
{
if (GlobalVars.UserConfiguration.LauncherStyle != Settings.Style.Stylish)
{
checkStylishSplash = false;
}
else
{
generatedSplash = GetSpecialOrNormalSplash();
}
}
else
{
checkStylishSplash = false;
}
}
return generatedSplash;
}
}
#endregion

View File

@ -266,6 +266,8 @@ namespace NovetusLauncher
if (!string.IsNullOrWhiteSpace(splash.SplashContext))
{
contextToolTip = new ToolTip();
contextToolTip.ToolTipIcon = ToolTipIcon.Info;
contextToolTip.ToolTipTitle = "Context";
contextToolTip.SetToolTip(SplashLabel, splash.SplashContext);
}

View File

@ -36,12 +36,43 @@ partial class SplashTester
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(SplashTester));
this.splashLabelNormal = new System.Windows.Forms.Label();
this.entryBox = new System.Windows.Forms.TextBox();
this.Preview = new System.Windows.Forms.Label();
this.splashLabelStylish = new System.Windows.Forms.Label();
this.changeStylishColor = new System.Windows.Forms.Button();
this.splashScriptMenu = new System.Windows.Forms.MenuStrip();
this.addToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.tagsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.clientToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.serverToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.variablesToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.nameToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.randomtextToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.versionToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.yearToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dayToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.monthToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.nextyearToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.newlineToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.branchToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.nextbranchToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.fromLabel = new System.Windows.Forms.Label();
this.toLabel = new System.Windows.Forms.Label();
this.fromDate = new System.Windows.Forms.Label();
this.toDate = new System.Windows.Forms.Label();
this.persistantToDate = new System.Windows.Forms.Label();
this.persistantFromDate = new System.Windows.Forms.Label();
this.persistantTo = new System.Windows.Forms.Label();
this.persistantFrom = new System.Windows.Forms.Label();
this.persistant = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.specialSplashTesting = new System.Windows.Forms.CheckBox();
this.contextToolTipNormal = new System.Windows.Forms.ToolTip(this.components);
this.contextToolTipStylish = new System.Windows.Forms.ToolTip(this.components);
this.splashScriptMenu.SuspendLayout();
this.SuspendLayout();
//
// splashLabelNormal
@ -51,11 +82,10 @@ partial class SplashTester
this.splashLabelNormal.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.splashLabelNormal.Font = new System.Drawing.Font("Microsoft Sans Serif", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.splashLabelNormal.ForeColor = System.Drawing.Color.Black;
this.splashLabelNormal.Location = new System.Drawing.Point(297, 23);
this.splashLabelNormal.Location = new System.Drawing.Point(301, 23);
this.splashLabelNormal.Name = "splashLabelNormal";
this.splashLabelNormal.Size = new System.Drawing.Size(214, 17);
this.splashLabelNormal.TabIndex = 0;
this.splashLabelNormal.Text = "Novetus!";
this.splashLabelNormal.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// entryBox
@ -63,11 +93,12 @@ partial class SplashTester
this.entryBox.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.entryBox.Location = new System.Drawing.Point(12, 110);
this.entryBox.Location = new System.Drawing.Point(12, 123);
this.entryBox.Multiline = true;
this.entryBox.Name = "entryBox";
this.entryBox.Size = new System.Drawing.Size(795, 96);
this.entryBox.Size = new System.Drawing.Size(795, 117);
this.entryBox.TabIndex = 52;
this.entryBox.Text = "Novetus!";
this.entryBox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
this.entryBox.TextChanged += new System.EventHandler(this.entryBox_TextChanged);
//
@ -75,7 +106,7 @@ partial class SplashTester
//
this.Preview.Anchor = System.Windows.Forms.AnchorStyles.Top;
this.Preview.AutoSize = true;
this.Preview.Location = new System.Drawing.Point(381, 7);
this.Preview.Location = new System.Drawing.Point(385, 7);
this.Preview.Name = "Preview";
this.Preview.Size = new System.Drawing.Size(45, 13);
this.Preview.TabIndex = 53;
@ -88,18 +119,17 @@ partial class SplashTester
this.splashLabelStylish.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.splashLabelStylish.Font = new System.Drawing.Font("Comic Sans MS", 12F, System.Drawing.FontStyle.Bold);
this.splashLabelStylish.ForeColor = System.Drawing.Color.White;
this.splashLabelStylish.Location = new System.Drawing.Point(62, 47);
this.splashLabelStylish.Location = new System.Drawing.Point(64, 60);
this.splashLabelStylish.Name = "splashLabelStylish";
this.splashLabelStylish.Size = new System.Drawing.Size(689, 32);
this.splashLabelStylish.TabIndex = 54;
this.splashLabelStylish.Text = "Novetus!";
this.splashLabelStylish.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.splashLabelStylish.Paint += new System.Windows.Forms.PaintEventHandler(this.splashLabelStylish_Paint);
//
// changeStylishColor
//
this.changeStylishColor.Anchor = System.Windows.Forms.AnchorStyles.Top;
this.changeStylishColor.Location = new System.Drawing.Point(353, 82);
this.changeStylishColor.Location = new System.Drawing.Point(357, 95);
this.changeStylishColor.Name = "changeStylishColor";
this.changeStylishColor.Size = new System.Drawing.Size(103, 22);
this.changeStylishColor.TabIndex = 55;
@ -107,13 +137,254 @@ partial class SplashTester
this.changeStylishColor.UseVisualStyleBackColor = true;
this.changeStylishColor.Click += new System.EventHandler(this.changeStylishColor_Click);
//
// splashScriptMenu
//
this.splashScriptMenu.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.splashScriptMenu.BackColor = System.Drawing.SystemColors.ControlLightLight;
this.splashScriptMenu.Dock = System.Windows.Forms.DockStyle.None;
this.splashScriptMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.addToolStripMenuItem});
this.splashScriptMenu.Location = new System.Drawing.Point(3, 3);
this.splashScriptMenu.Name = "splashScriptMenu";
this.splashScriptMenu.Size = new System.Drawing.Size(123, 24);
this.splashScriptMenu.TabIndex = 56;
this.splashScriptMenu.Text = "menuStrip1";
//
// addToolStripMenuItem
//
this.addToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.tagsToolStripMenuItem,
this.variablesToolStripMenuItem});
this.addToolStripMenuItem.Name = "addToolStripMenuItem";
this.addToolStripMenuItem.Size = new System.Drawing.Size(115, 20);
this.addToolStripMenuItem.Text = "Splash Formatting";
//
// tagsToolStripMenuItem
//
this.tagsToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.clientToolStripMenuItem,
this.serverToolStripMenuItem});
this.tagsToolStripMenuItem.Name = "tagsToolStripMenuItem";
this.tagsToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.tagsToolStripMenuItem.Text = "Add Tags";
//
// clientToolStripMenuItem
//
this.clientToolStripMenuItem.Name = "clientToolStripMenuItem";
this.clientToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.clientToolStripMenuItem.Text = "[stylish]";
this.clientToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// serverToolStripMenuItem
//
this.serverToolStripMenuItem.Name = "serverToolStripMenuItem";
this.serverToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.serverToolStripMenuItem.Text = "[normal]";
this.serverToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// variablesToolStripMenuItem
//
this.variablesToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.nameToolStripMenuItem,
this.randomtextToolStripMenuItem,
this.versionToolStripMenuItem,
this.yearToolStripMenuItem,
this.dayToolStripMenuItem,
this.monthToolStripMenuItem,
this.nextyearToolStripMenuItem,
this.newlineToolStripMenuItem,
this.branchToolStripMenuItem,
this.nextbranchToolStripMenuItem});
this.variablesToolStripMenuItem.Name = "variablesToolStripMenuItem";
this.variablesToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.variablesToolStripMenuItem.Text = "Add Variables";
//
// nameToolStripMenuItem
//
this.nameToolStripMenuItem.Name = "nameToolStripMenuItem";
this.nameToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.nameToolStripMenuItem.Text = "%name%";
this.nameToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// randomtextToolStripMenuItem
//
this.randomtextToolStripMenuItem.Name = "randomtextToolStripMenuItem";
this.randomtextToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.randomtextToolStripMenuItem.Text = "%randomtext%";
this.randomtextToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// versionToolStripMenuItem
//
this.versionToolStripMenuItem.Name = "versionToolStripMenuItem";
this.versionToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.versionToolStripMenuItem.Text = "%version%";
this.versionToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// yearToolStripMenuItem
//
this.yearToolStripMenuItem.Name = "yearToolStripMenuItem";
this.yearToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.yearToolStripMenuItem.Text = "%year%";
this.yearToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// dayToolStripMenuItem
//
this.dayToolStripMenuItem.Name = "dayToolStripMenuItem";
this.dayToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.dayToolStripMenuItem.Text = "%day%";
this.dayToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// monthToolStripMenuItem
//
this.monthToolStripMenuItem.Name = "monthToolStripMenuItem";
this.monthToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.monthToolStripMenuItem.Text = "%month%";
this.monthToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// nextyearToolStripMenuItem
//
this.nextyearToolStripMenuItem.Name = "nextyearToolStripMenuItem";
this.nextyearToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.nextyearToolStripMenuItem.Text = "%nextyear%";
this.nextyearToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// newlineToolStripMenuItem
//
this.newlineToolStripMenuItem.Name = "newlineToolStripMenuItem";
this.newlineToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.newlineToolStripMenuItem.Text = "%newline%";
this.newlineToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// branchToolStripMenuItem
//
this.branchToolStripMenuItem.Name = "branchToolStripMenuItem";
this.branchToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.branchToolStripMenuItem.Text = "%branch%";
this.branchToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// nextbranchToolStripMenuItem
//
this.nextbranchToolStripMenuItem.Name = "nextbranchToolStripMenuItem";
this.nextbranchToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
this.nextbranchToolStripMenuItem.Text = "%nextbranch%";
this.nextbranchToolStripMenuItem.Click += new System.EventHandler(this.variableToolStripMenuItem_Click);
//
// fromLabel
//
this.fromLabel.AutoSize = true;
this.fromLabel.Location = new System.Drawing.Point(554, 23);
this.fromLabel.Name = "fromLabel";
this.fromLabel.Size = new System.Drawing.Size(30, 13);
this.fromLabel.TabIndex = 57;
this.fromLabel.Text = "From";
//
// toLabel
//
this.toLabel.AutoSize = true;
this.toLabel.Location = new System.Drawing.Point(622, 23);
this.toLabel.Name = "toLabel";
this.toLabel.Size = new System.Drawing.Size(20, 13);
this.toLabel.TabIndex = 58;
this.toLabel.Text = "To";
//
// fromDate
//
this.fromDate.AutoSize = true;
this.fromDate.Location = new System.Drawing.Point(554, 38);
this.fromDate.Name = "fromDate";
this.fromDate.Size = new System.Drawing.Size(0, 13);
this.fromDate.TabIndex = 59;
//
// toDate
//
this.toDate.AutoSize = true;
this.toDate.Location = new System.Drawing.Point(619, 38);
this.toDate.Name = "toDate";
this.toDate.Size = new System.Drawing.Size(0, 13);
this.toDate.TabIndex = 61;
//
// persistantToDate
//
this.persistantToDate.AutoSize = true;
this.persistantToDate.Location = new System.Drawing.Point(754, 38);
this.persistantToDate.Name = "persistantToDate";
this.persistantToDate.Size = new System.Drawing.Size(0, 13);
this.persistantToDate.TabIndex = 65;
//
// persistantFromDate
//
this.persistantFromDate.AutoSize = true;
this.persistantFromDate.Location = new System.Drawing.Point(689, 38);
this.persistantFromDate.Name = "persistantFromDate";
this.persistantFromDate.Size = new System.Drawing.Size(0, 13);
this.persistantFromDate.TabIndex = 64;
//
// persistantTo
//
this.persistantTo.AutoSize = true;
this.persistantTo.Location = new System.Drawing.Point(734, 23);
this.persistantTo.Name = "persistantTo";
this.persistantTo.Size = new System.Drawing.Size(63, 13);
this.persistantTo.TabIndex = 63;
this.persistantTo.Text = "Increase on";
//
// persistantFrom
//
this.persistantFrom.AutoSize = true;
this.persistantFrom.Location = new System.Drawing.Point(689, 23);
this.persistantFrom.Name = "persistantFrom";
this.persistantFrom.Size = new System.Drawing.Size(29, 13);
this.persistantFrom.TabIndex = 62;
this.persistantFrom.Text = "Start";
//
// persistant
//
this.persistant.AutoSize = true;
this.persistant.Location = new System.Drawing.Point(694, 7);
this.persistant.Name = "persistant";
this.persistant.Size = new System.Drawing.Size(85, 13);
this.persistant.TabIndex = 66;
this.persistant.Text = "Low Persistance";
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(579, 7);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(43, 13);
this.label1.TabIndex = 67;
this.label1.Text = "Lifetime";
//
// specialSplashTesting
//
this.specialSplashTesting.AutoSize = true;
this.specialSplashTesting.Location = new System.Drawing.Point(18, 31);
this.specialSplashTesting.Name = "specialSplashTesting";
this.specialSplashTesting.Size = new System.Drawing.Size(134, 17);
this.specialSplashTesting.TabIndex = 68;
this.specialSplashTesting.Text = "Special Splash Testing";
this.specialSplashTesting.UseVisualStyleBackColor = true;
//
// SplashTester
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.SystemColors.ControlLightLight;
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(819, 213);
this.ClientSize = new System.Drawing.Size(819, 247);
this.Controls.Add(this.specialSplashTesting);
this.Controls.Add(this.label1);
this.Controls.Add(this.persistant);
this.Controls.Add(this.persistantToDate);
this.Controls.Add(this.persistantFromDate);
this.Controls.Add(this.persistantTo);
this.Controls.Add(this.persistantFrom);
this.Controls.Add(this.toDate);
this.Controls.Add(this.fromDate);
this.Controls.Add(this.toLabel);
this.Controls.Add(this.fromLabel);
this.Controls.Add(this.splashScriptMenu);
this.Controls.Add(this.changeStylishColor);
this.Controls.Add(this.splashLabelStylish);
this.Controls.Add(this.Preview);
@ -125,6 +396,8 @@ partial class SplashTester
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Splash Tester";
this.Load += new System.EventHandler(this.SplashTester_Load);
this.splashScriptMenu.ResumeLayout(false);
this.splashScriptMenu.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
@ -134,4 +407,33 @@ partial class SplashTester
private System.Windows.Forms.Label Preview;
private System.Windows.Forms.Label splashLabelStylish;
private System.Windows.Forms.Button changeStylishColor;
private System.Windows.Forms.MenuStrip splashScriptMenu;
private System.Windows.Forms.ToolStripMenuItem addToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem tagsToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem clientToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem serverToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem variablesToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem nameToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem randomtextToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem versionToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem yearToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem dayToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem monthToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem nextyearToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem newlineToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem branchToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem nextbranchToolStripMenuItem;
private System.Windows.Forms.Label fromLabel;
private System.Windows.Forms.Label toLabel;
private System.Windows.Forms.Label fromDate;
private System.Windows.Forms.Label toDate;
private System.Windows.Forms.Label persistantToDate;
private System.Windows.Forms.Label persistantFromDate;
private System.Windows.Forms.Label persistantTo;
private System.Windows.Forms.Label persistantFrom;
private System.Windows.Forms.Label persistant;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.CheckBox specialSplashTesting;
private System.Windows.Forms.ToolTip contextToolTipNormal;
private System.Windows.Forms.ToolTip contextToolTipStylish;
}

View File

@ -18,8 +18,91 @@ public partial class SplashTester : Form
#region Form Events
private void entryBox_TextChanged(object sender, EventArgs e)
{
splashLabelNormal.Text = entryBox.Text;
splashLabelStylish.Text = entryBox.Text;
try
{
contextToolTipStylish.ToolTipIcon = ToolTipIcon.None;
contextToolTipStylish.ToolTipTitle = "";
contextToolTipStylish.SetToolTip(splashLabelStylish, null);
contextToolTipNormal.ToolTipIcon = ToolTipIcon.None;
contextToolTipNormal.ToolTipTitle = "";
contextToolTipNormal.SetToolTip(splashLabelNormal, null);
fromDate.Text = "";
toDate.Text = "";
persistantFromDate.Text = "";
persistantToDate.Text = "";
Splash splash = new Splash(entryBox.Text, specialSplashTesting.Checked);
bool stylishLabel = true;
bool normalLabel = true;
if (splash.Compatibility == SplashCompatibility.Stylish)
{
normalLabel = false;
splashLabelNormal.Text = "";
}
else if (splash.Compatibility == SplashCompatibility.Normal)
{
stylishLabel = false;
splashLabelStylish.Text = "";
}
if (stylishLabel)
{
splashLabelStylish.Text = splash.SplashText;
if (!string.IsNullOrWhiteSpace(splash.SplashContext))
{
contextToolTipStylish.ToolTipIcon = ToolTipIcon.Info;
contextToolTipStylish.ToolTipTitle = "Context (Stylish)";
contextToolTipStylish.SetToolTip(splashLabelStylish, splash.SplashContext);
}
}
if (normalLabel)
{
splashLabelNormal.Text = splash.SplashText;
if (!string.IsNullOrWhiteSpace(splash.SplashContext))
{
contextToolTipNormal.ToolTipIcon = ToolTipIcon.Info;
contextToolTipNormal.ToolTipTitle = "Context (Normal)";
contextToolTipNormal.SetToolTip(splashLabelNormal, splash.SplashContext);
}
}
if (splash.SplashFirstAppearanceDate != null)
{
if (splash.SplashEndAppearanceDate != null)
{
fromDate.Text = splash.SplashFirstAppearanceDate.Value.Month + "/" + splash.SplashFirstAppearanceDate.Value.Day;
toDate.Text = splash.SplashEndAppearanceDate.Value.Month + "/" + splash.SplashEndAppearanceDate.Value.Day;
if (splash.SplashDateStopAppearingAllTheTime != null && splash.SplashDateStartToAppearLess != null)
{
persistantFromDate.Text = splash.SplashDateStopAppearingAllTheTime.Value.Month + "/" + splash.SplashDateStopAppearingAllTheTime.Value.Day;
persistantToDate.Text = splash.SplashDateStartToAppearLess.Value.Month + "/" + splash.SplashDateStartToAppearLess.Value.Day;
}
}
else
{
fromDate.Text = splash.SplashFirstAppearanceDate.Value.Month + "/" + splash.SplashFirstAppearanceDate.Value.Day;
toDate.Text = splash.SplashFirstAppearanceDate.Value.Month + "/" + (splash.SplashFirstAppearanceDate.Value.Day + 1);
}
}
else if (splash.SplashWeekday != null)
{
fromDate.Text = splash.SplashWeekday.ToString();
toDate.Text = splash.SplashWeekday.ToString();
}
}
catch (Exception ex)
{
GlobalFuncs.LogExceptions(ex);
}
}
private void SplashTester_Load(object sender, EventArgs e)
@ -41,6 +124,8 @@ public partial class SplashTester : Form
splashLabelStylish.BackColor = Color.FromArgb(238, 154, 181);
}
entryBox.Text = "Novetus!|This is placeholder text!";
CenterToScreen();
}
@ -68,6 +153,12 @@ public partial class SplashTester : Form
{
GlobalFuncs.DrawBorderSimple(e.Graphics, splashLabelStylish.DisplayRectangle, Color.White, ButtonBorderStyle.Solid, 1);
}
private void variableToolStripMenuItem_Click(object sender, EventArgs e)
{
ToolStripMenuItem senderitem = (ToolStripMenuItem)sender;
entryBox.Paste(senderitem.Text);
}
#endregion
}
#endregion

View File

@ -117,6 +117,15 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="splashScriptMenu.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="contextToolTipNormal.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>165, 17</value>
</metadata>
<metadata name="contextToolTipStylish.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>338, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>

View File

@ -39,7 +39,10 @@ Changes from Pre-Release 5:
- Clients with seperate Roblox Players and Studios are now supported with the new "Seperate Folders" option.
- This option tells Novetus to load the client from 3 folders in the client: client, studio, and server.
- Items will be broken with this method. However, the client developer may edit the paths for each item loaded through the script by using Lua's string.gsub function and adding an extra "../" after rbxasset:// (string.gsub(itemURL, "rbxasset://", "rbxasset://../").
- "Special splashes" how have a 1 in 10 chance to be overriden with a splash from the splash list.
- Fixed "Special splashes" not working on specific dates.
- "Special splashes" how have a 1 in 5 chance to be overriden with a splash from the splash list.
- Added support for the new splash formatting in the Splash Tester.
- You are now able to add splash formatting through the Splash Formatting menu and see it work in real time.
- Added context for some splashes.
Changes from 1.2.4.1:
- The OBJ2MeshV1GUI, The Asset Localizer, and the Item SDK have been merged to form the Asset SDK!

View File

@ -1,16 +1,16 @@
Happy New Year!|Have a happy %year%!|1/1
RIP Erik Cassel|Erik Cassel, was a co-founder, administrator and former VP of Engineering of Roblox.|2/11
RIP Erik Cassel|Erik Cassel, was a co-founder, administrator%newline%and former VP of Engineering of Roblox.|2/11
smoke weed every day|blaze it|4/20
Happy Birthday, Bitl!|Bitl is the developer of Novetus and RBXLegacy.|6/10
Happy Pride Month!|6/1-6/30-6/7-6/15
And this is the way... of the Bionicle.|August 10th is known as 810icle day, a day where Bionicle fans celebrate Bionicle and its legacy.|8/10
And this is the way... of the Bionicle.|August 10th is known as 810icle day,%newline%a day where Bionicle fans celebrate Bionicle and its legacy.|8/10
Happy Birthday, Roblox!|Roblox was released to the public on September 1st, 2006.|9/1
Happy Leif Erikson Day! HINGA DINGA DURGEN!|10/9
I used to wonder what friendship could be!|10/10
Happy Birthday, Novetus!|Novetus was announced directly after the cancellation of RBXLegacy.|10/27
Adventure Awaits...|The first trailer used to promote Roblox to the public was uploaded by John Shedletsky on November 9th, 2006.|11/9
Adventure Awaits...|The first trailer used to promote Roblox to the public was%newline%uploaded by John Shedletsky on November 9th, 2006.|11/9
Welcome to %version%!|Hi!|11/11
Happy Halloween!|Spooky, scary skeletons send shivers down your spine...|10/31
Merry Christmas!|...and a happy new year!|12/24-12/25
Happy New Year!|Have a happy %nextyear%!|12/31
Happy Out-of-Touch Thursday!|You're out of touch, I'm out of time. But I'm out of my head when you're not around!|Thursday
Happy Out-of-Touch Thursday!|You're out of touch, I'm out of time.%newline%But I'm out of my head when you're not around!|Thursday

View File

@ -1,12 +1,12 @@
Novetus!
From the creator of RBXLegacy!|Bitl is the developer of Novetus and RBXLegacy.
Carrot is a sensitive topic.
Wii Phone|From the classic video titled "future gen. consels wii2 ps4 xbox720?"
Wii Phone|From the classic video titled%newline%"future gen. consels wii2 ps4 xbox720?"
Yay!|LOUDER!
Now 20% cooler!
Blockland is good!
;ec
Check out Finob-oh.|Finobe was an old Roblox Revival ran by RBLXDev/RBLXHue/Novelium developer Raymonf.
Check out Finob-oh.|Finobe was an old Roblox Revival%newline%ran by RBLXDev/RBLXHue/Novelium developer Raymonf.
Check out Graphictoria!|One of the first major old Roblox revivals besides RBLXDev.
Check out FIREFIGHT RELOADED!|Bitl's Half-Life 2 mod, released on Steam.
Check out RBXLe-oh.|RBXLegacy was the precursor to Novetus, released back in 2016!
@ -81,7 +81,7 @@ that's a weapon, not a teleporter|From Doom Eternal
DIE, YOU FILTHY GERM!|From Cells at Work
Endorsed by the PCMasterRace!
%randomtext%
mr beetle can i have novetus 1.4|no.
mr beetle can i have novetus %nextbranch%|no.
Pride and accomplishment!
No lootboxes!
Weeeeeeeeeeee-*static*|From Portal 1.
@ -108,7 +108,7 @@ Runs under Windows XP!|Just install the dependencies!
Check out the Novetus SDK!
MSMSMSMSMSMSMSMSMSMSMSM|RIP SOPHIE.
It's okay to cry.|RIP SOPHIE.
Fin-etus!|Old April Fools joke from 2020 involving Novetus being bought out by Finobe.
Fin-etus!|Old April Fools joke from 2020%newline%involving Novetus being bought out by Finobe.
Check out MAYHEM!|Bitl's co-op top-down horde mode shooter!
Think. Build. Create.|Old Roblox slogan.
Post-Awareness Stage 6 Is without description.|Everywhere at the end of time.
@ -127,11 +127,11 @@ splashes.txt has not been found.|Restart your computer to fix this issue.
Play on Wine or Proton!
Come try Novetus on your Not Phone!
LOAD"*",8 RUN|The Commodore 64 command used to boot up applications from a floppy disk.
Previously 1.2.5!|1.3 was previously known as 1.2.5, but many more additions were made, which made it a newer version.
Previously 1.2.5!|1.3 was previously known as 1.2.5. Many more additions were made,%newline%which made worthy of the increased version.
You are now breathing manually.
Fuck the cynicism, let the colors fly!|Don't care you think it's cringe because it's not your life!
NOVETUS 2.0 WHEN??
Originally known as RBXLegacy 2.0!|Novetus was announced as RBXLegacy 2.0 at first, but Bitl considered the project separate from RBXLegacy. Novetus was the winner of a naming contest.
Originally known as RBXLegacy 2.0!|Novetus was announced as RBXLegacy 2.0 at first,%newline%but Bitl considered the project separate from RBXLegacy.%newline%Novetus was the winner of a naming contest.
Do you like waffles?|Yes, we like waffles!
NYAN CAT!|NYANNYANNYANNYANNYANNYAN!
Been watching =3 until 2 AM.|I ain't got no iPhone but I got a DS!
@ -156,7 +156,7 @@ Is nostalgia my inherent weakness?
Updated localization files.|Team Fortress 2 Update Released
Do you think healing is just magic?
Part of a hearty dinner!
Inspired by JRBX!| The Stylish style was inspired by the style of JRBX, a now-defunct old Roblox revival.
Inspired by JRBX!| The Stylish style was inspired by the%newline%style of JRBX, a now-defunct old Roblox revival.
Arblus, look! It's Unicron!|From the 1986 Transformers movie.
[stylish]THE SHIPS! GET TO THE SHIPS! IT'S OUR ONLY CHANCE!|From the 1986 Transformers movie.
[normal]YOU'VE GOT THE TOUCH!|YOU'VE GOT THE POWER!
@ -169,4 +169,5 @@ Won't run on your 486.|Referencing the Half-Life 2 E3 Demo.
11-11-21!
Crave sanity? I'll make you vegetables.|From Death Grips' Steroids EP.
Not a metaverse!
[stylish]We both know that there are a thousand ways I could destroy you right now.|And 941 of them hurt.
[stylish]We both know that there are a thousand ways I could destroy you right now.|And 941 of them hurt.
IT WAS 99 CENTS!