aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAShifter <[email protected]>2017-06-18 18:39:27 -0700
committerAShifter <[email protected]>2017-06-18 18:39:27 -0700
commitbf7fcf52ad5373e25fbe399f4f1dd1091f53c159 (patch)
tree858cc86e8f02535ff7ec081fb290611d0ff0705f
parent15f2e1a7e3ec5d85aee4a126144722feeff4682f (diff)
downloadhistacom2-bf7fcf52ad5373e25fbe399f4f1dd1091f53c159.tar.gz
histacom2-bf7fcf52ad5373e25fbe399f4f1dd1091f53c159.tar.bz2
histacom2-bf7fcf52ad5373e25fbe399f4f1dd1091f53c159.zip
Some more terminal work
IT WORKS! IT WWOOOOORRRKKKSS!!! YOu can now use Thread.Sleep(); without issues.
-rw-r--r--TimeHACK.Engine/TimeHACK.Engine.csproj5
-rw-r--r--TimeHACK.Engine/packages.config2
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/Story/Hack1.cs28
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.Designer.cs1
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.cs4
-rw-r--r--TimeHACK.Main/TimeHACK.Main.csproj4
-rw-r--r--TimeHACK.Main/packages.config2
7 files changed, 26 insertions, 20 deletions
diff --git a/TimeHACK.Engine/TimeHACK.Engine.csproj b/TimeHACK.Engine/TimeHACK.Engine.csproj
index 980f7fb..7ee8e6e 100644
--- a/TimeHACK.Engine/TimeHACK.Engine.csproj
+++ b/TimeHACK.Engine/TimeHACK.Engine.csproj
@@ -30,8 +30,8 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
- <Reference Include="Newtonsoft.Json">
- <HintPath>..\TimeHACK.Main\bin\Release\Newtonsoft.Json.dll</HintPath>
+ <Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
+ <HintPath>..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
@@ -46,6 +46,7 @@
</ItemGroup>
<ItemGroup>
<Compile Include="BSODCreator.cs" />
+ <None Include="packages.config" />
<None Include="Resources\WinClassic\Window\pjBg6mKP.bin" />
<Compile Include="FileDialogBoxManager.cs" />
<Compile Include="SaveSystem.cs" />
diff --git a/TimeHACK.Engine/packages.config b/TimeHACK.Engine/packages.config
index f54866f..810e559 100644
--- a/TimeHACK.Engine/packages.config
+++ b/TimeHACK.Engine/packages.config
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
- <package id="Newtonsoft.Json" version="10.0.1" targetFramework="net452" />
+ <package id="Newtonsoft.Json" version="10.0.3" targetFramework="net452" />
</packages> \ No newline at end of file
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/Story/Hack1.cs b/TimeHACK.Main/OS/Win95/Win95Apps/Story/Hack1.cs
index 2310af4..faafdea 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/Story/Hack1.cs
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/Story/Hack1.cs
@@ -14,35 +14,39 @@ namespace TimeHACK.OS.Win95.Win95Apps.Story
{
static class Hack1 : Object
{
- static WinClassicTerminal term = new WinClassicTerminal();
+ static WinClassicTerminal Console = new WinClassicTerminal();
static WindowManager wm = new WindowManager();
static Boolean ended = false;
static Thread soundThread = new Thread(dialup_sound_play);
+ static Boolean devMode = false;
// This is the very first story script!
public static void startObjective()
{
System.Windows.Forms.Timer tmr = new System.Windows.Forms.Timer();
- wm.startWin95(term, "MS-DOS Prompt", null, true, true);
- term.WriteLine("192.168.0.1 Connecting...");
-
- term.Invalidate();
- Application.DoEvents();
+ wm.startWin95(Console, "MS-DOS Prompt", null, true, true);
+ Console.WriteLine("telnet> 104.27.135.159 Connecting...");
tmr.Interval = 1;
tmr.Tick += new EventHandler(CheckIfSoundFinished);
- soundThread.Start();
-
- tmr.Start();
+ if (devMode == true)
+ {
+ continueObjective();
+ }
+ else
+ {
+ soundThread.Start();
+ tmr.Start();
+ }
}
public static void continueObjective()
{
- term.WriteLine("192.168.0.1 Connected.");
-
- Application.DoEvents();
+ Console.WriteLine("telnet> 104.27.135.159 Connected.");
+ Thread.Sleep(2500);
+ Console.WriteLine("telnet> 104.27.135.159 set hostname to 'TheHiddenHacker'.");
}
public static void CheckIfSoundFinished(Object sender, EventArgs e)
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.Designer.cs b/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.Designer.cs
index d7e9781..ddae557 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.Designer.cs
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.Designer.cs
@@ -35,6 +35,7 @@
//
this.richTextBox1.BackColor = System.Drawing.Color.Black;
this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.richTextBox1.Font = new System.Drawing.Font("Lucida Console", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.richTextBox1.ForeColor = System.Drawing.Color.White;
this.richTextBox1.Location = new System.Drawing.Point(0, 0);
this.richTextBox1.Name = "richTextBox1";
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.cs b/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.cs
index d25b409..174c5b4 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.cs
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/WinClassicTerminal.cs
@@ -20,9 +20,7 @@ namespace TimeHACK.OS.Win95.Win95Apps
public WinClassicTerminal()
{
InitializeComponent();
- this.richTextBox1.Font = new Font(TitleScreen.pfc.Families[0], 16F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
}
- private SoundPlayer startsound;
/// <summary>
/// Write text to the Terminal and create a new line. Very similar to the Win32 Console.WriteLine Function.
/// </summary>
@@ -30,6 +28,7 @@ namespace TimeHACK.OS.Win95.Win95Apps
public void WriteLine(string Text)
{
richTextBox1.AppendText(Text + "\n");
+ richTextBox1.Update();
}
/// <summary>
@@ -39,6 +38,7 @@ namespace TimeHACK.OS.Win95.Win95Apps
public void Write(String Text)
{
richTextBox1.AppendText(Text);
+ richTextBox1.Update();
}
}
}
diff --git a/TimeHACK.Main/TimeHACK.Main.csproj b/TimeHACK.Main/TimeHACK.Main.csproj
index 0378561..fe54247 100644
--- a/TimeHACK.Main/TimeHACK.Main.csproj
+++ b/TimeHACK.Main/TimeHACK.Main.csproj
@@ -106,8 +106,7 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
- <SpecificVersion>False</SpecificVersion>
- <HintPath>bin\Release\Newtonsoft.Json.dll</HintPath>
+ <HintPath>..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
@@ -345,6 +344,7 @@
<EmbeddedResource Include="TitleScreen.resx">
<DependentUpon>TitleScreen.cs</DependentUpon>
</EmbeddedResource>
+ <None Include="packages.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
diff --git a/TimeHACK.Main/packages.config b/TimeHACK.Main/packages.config
index f54866f..810e559 100644
--- a/TimeHACK.Main/packages.config
+++ b/TimeHACK.Main/packages.config
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
- <package id="Newtonsoft.Json" version="10.0.1" targetFramework="net452" />
+ <package id="Newtonsoft.Json" version="10.0.3" targetFramework="net452" />
</packages> \ No newline at end of file