From 9c644ead8f61e0ee4f405433350e4030256b46fd Mon Sep 17 00:00:00 2001 From: lempamo Date: Mon, 30 Oct 2017 22:49:27 -0400 Subject: [PATCH] travel to bad xp works --- Histacom2/OS/Win98/Win98.cs | 9 -- Histacom2/OS/Win98/Win98Apps/Story/Hack3.cs | 128 +++++++++--------- .../Win98Apps/WinClassicTimeDistorter2.cs | 2 +- 3 files changed, 65 insertions(+), 74 deletions(-) diff --git a/Histacom2/OS/Win98/Win98.cs b/Histacom2/OS/Win98/Win98.cs index 26e203c..ce7cd65 100644 --- a/Histacom2/OS/Win98/Win98.cs +++ b/Histacom2/OS/Win98/Win98.cs @@ -484,15 +484,6 @@ private void TimeDistorterToolStripMenuItem_Click(object sender, EventArgs e) startmenu.Hide(); } - private void FTPClientToolStripMenuItem_Click(object sender, EventArgs e) - { - WinClassic app = wm.Init(new WinClassicFTPClient(), "FTP Client", null, true, true); - - AddTaskBarItem(app, app.Tag.ToString(), "FTP Client", null); - app.BringToFront(); - startmenu.Hide(); - } - private void CalculatorToolStripMenuItem_Click(object sender, EventArgs e) { WinClassic app = wm.Init(new WinClassicCalculator(), "Calculator", Properties.Resources.WinClassicCalc, false, false); diff --git a/Histacom2/OS/Win98/Win98Apps/Story/Hack3.cs b/Histacom2/OS/Win98/Win98Apps/Story/Hack3.cs index 6798109..5112565 100644 --- a/Histacom2/OS/Win98/Win98Apps/Story/Hack3.cs +++ b/Histacom2/OS/Win98/Win98Apps/Story/Hack3.cs @@ -14,7 +14,7 @@ public class Hack3 : object { static WindowManager wm = new WindowManager(); - public static async void StartObjective() + public static async void StartObjective(WinClassicTimeDistorter2 td) { Random r = new Random(); @@ -45,9 +45,9 @@ public static async void StartObjective() await Task.Delay(6000); TitleScreen.frm98.webchat.history.AppendText($"12padams: oh hey {SaveSystem.ProfileName}, make sure to keep an eye on the year in case something goes wrong" + Environment.NewLine); TitleScreen.frm98.webchat.receive.Play(); // 10 await Task.Delay(4000); TitleScreen.frm98.webchat.history.AppendText("HiddenHacker: and have a safe trip!" + Environment.NewLine); TitleScreen.frm98.webchat.receive.Play(); // 6 - while (TitleScreen.frm98.distort.secsLeft != 0) { } // 0 + await Task.Delay(td.secsLeft * 1000); // 0 - TitleScreen.frm98.distort.classicLabel4.Text = "Initiating Time Travel..."; + td.classicLabel4.Text = "Initiating Time Travel..."; await Task.Delay(100); Program.Invert(TitleScreen.frm98.webchat); await Task.Delay(100); Program.Invert(TitleScreen.frm98.webchat); await Task.Delay(100); Program.Invert(TitleScreen.frm98.webchat); @@ -93,84 +93,84 @@ public static async void StartObjective() await Task.Delay(100); Program.Invert(TitleScreen.frm98, false); await Task.Delay(100); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); - await Task.Delay(100); TitleScreen.frm98.distort.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); // -5 + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); + await Task.Delay(100); td.ParentForm.Location = new Point(r.Next(TitleScreen.frm98.Width), r.Next(TitleScreen.frm98.Height)); Program.Invert(TitleScreen.frm98, false); // -5 await Task.Delay(100); TitleScreen.frm98.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).BringToFront(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).maximizebutton.Enabled = false; - ((WinClassic)TitleScreen.frm98.distort.ParentForm).WindowState = FormWindowState.Maximized; - ((WinClassic)TitleScreen.frm98.distort.ParentForm).right.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).left.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).bottom.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).top.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).bottomleftcorner.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).bottomrightcorner.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).topleftcorner.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).toprightcorner.Hide(); - ((WinClassic)TitleScreen.frm98.distort.ParentForm).Dock = DockStyle.Fill; - ((WinClassic)TitleScreen.frm98.distort.ParentForm).max = true; - ((WinClassic)TitleScreen.frm98.distort.ParentForm).maximizebutton.Image = Engine.Properties.Resources.WinClassicRestore; - ((WinClassic)TitleScreen.frm98.distort.ParentForm).programtopbar.Hide(); - TitleScreen.frm98.distort.BackColor = Color.Black; - foreach (Control c in TitleScreen.frm98.distort.Controls) { c.BackColor = Color.Black; c.Hide(); } - TitleScreen.frm98.distort.classicLabel1.Show(); - TitleScreen.frm98.distort.classicLabel1.ForeColor = Color.Lime; - TitleScreen.frm98.distort.classicLabel2.Text = "LOL NO"; - TitleScreen.frm98.distort.classicLabel2.ForeColor = Color.MidnightBlue; + ((WinClassic)td.ParentForm).BringToFront(); + ((WinClassic)td.ParentForm).maximizebutton.Enabled = false; + ((WinClassic)td.ParentForm).WindowState = FormWindowState.Maximized; + ((WinClassic)td.ParentForm).right.Hide(); + ((WinClassic)td.ParentForm).left.Hide(); + ((WinClassic)td.ParentForm).bottom.Hide(); + ((WinClassic)td.ParentForm).top.Hide(); + ((WinClassic)td.ParentForm).bottomleftcorner.Hide(); + ((WinClassic)td.ParentForm).bottomrightcorner.Hide(); + ((WinClassic)td.ParentForm).topleftcorner.Hide(); + ((WinClassic)td.ParentForm).toprightcorner.Hide(); + ((WinClassic)td.ParentForm).Dock = DockStyle.Fill; + ((WinClassic)td.ParentForm).max = true; + ((WinClassic)td.ParentForm).maximizebutton.Image = Engine.Properties.Resources.WinClassicRestore; + ((WinClassic)td.ParentForm).programtopbar.Hide(); + td.BackColor = Color.Black; + foreach (Control c in td.Controls) { c.BackColor = Color.Black; c.Hide(); } + td.classicLabel1.Show(); + td.classicLabel1.ForeColor = Color.Lime; + td.classicLabel2.Text = "LOL NO"; + td.classicLabel2.ForeColor = Color.MidnightBlue; // 0 - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "1999"; + await Task.Delay(100); td.classicLabel1.Text = "1999"; await Task.Delay(500); - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "2000"; - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "2000"; TitleScreen.frm98.distort.classicLabel2.Show(); - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "2000"; TitleScreen.frm98.distort.classicLabel2.Hide(); - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "1900"; // 1 + await Task.Delay(100); td.classicLabel1.Text = "2000"; + await Task.Delay(100); td.classicLabel1.Text = "2000"; td.classicLabel2.Show(); + await Task.Delay(100); td.classicLabel1.Text = "2000"; td.classicLabel2.Hide(); + await Task.Delay(100); td.classicLabel1.Text = "1900"; // 1 - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Hide(); - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "2000"; - await Task.Delay(100); TitleScreen.frm98.distort.classicLabel1.Text = "1900"; // 1.4 + await Task.Delay(100); td.classicLabel1.Hide(); + await Task.Delay(100); td.classicLabel1.Show(); + await Task.Delay(100); td.classicLabel1.Text = "2000"; + await Task.Delay(100); td.classicLabel1.Text = "1900"; // 1.4 for (int year = 1901; year < 2000; year++) { await Task.Delay(80); - TitleScreen.frm98.distort.classicLabel1.Text = year.ToString(); + td.classicLabel1.Text = year.ToString(); } // 9.32 - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); // 9.4 - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Text = "2000"; - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); // 9.8 - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Text = "2001"; - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); // 10.2 - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Text = "2002"; - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); // 10.6 - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Hide(); - await Task.Delay(80); TitleScreen.frm98.distort.classicLabel1.Show(); // 10.84 + await Task.Delay(80); td.classicLabel1.Hide(); // 9.4 + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Hide(); + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Text = "2000"; + await Task.Delay(80); td.classicLabel1.Hide(); // 9.8 + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Hide(); + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Text = "2001"; + await Task.Delay(80); td.classicLabel1.Hide(); // 10.2 + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Hide(); + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Text = "2002"; + await Task.Delay(80); td.classicLabel1.Hide(); // 10.6 + await Task.Delay(80); td.classicLabel1.Show(); + await Task.Delay(80); td.classicLabel1.Hide(); + await Task.Delay(80); td.classicLabel1.Show(); // 10.84 await Task.Delay(3000); SaveSystem.CurrentSave.CurrentOS = "xpbad"; SaveSystem.currentTheme = new BadXPTheme(); SaveSystem.CurrentSave.ThemeName = "badxp"; - TitleScreen.frm98.distort.ParentForm.Close(); + td.ParentForm.Close(); foreach (Form frm in Application.OpenForms) if (frm is WinClassic) frm.Close(); Program.title.StartGame(); TitleScreen.frm98.Close(); diff --git a/Histacom2/OS/Win98/Win98Apps/WinClassicTimeDistorter2.cs b/Histacom2/OS/Win98/Win98Apps/WinClassicTimeDistorter2.cs index e48f4ed..a6c52c1 100644 --- a/Histacom2/OS/Win98/Win98Apps/WinClassicTimeDistorter2.cs +++ b/Histacom2/OS/Win98/Win98Apps/WinClassicTimeDistorter2.cs @@ -25,7 +25,7 @@ private void classicButton1_Click(object sender, EventArgs e) classicLabel4.Show(); classicLabel4.Text = "Preparing to travel. ETA: 120 secs."; timer1.Start(); - Story.Hack3.StartObjective(); + Story.Hack3.StartObjective(this); } private void timer1_Tick(object sender, EventArgs e)