aboutsummaryrefslogtreecommitdiff
path: root/TimeHACK.Main
diff options
context:
space:
mode:
authorlempamo <[email protected]>2017-04-01 12:18:36 -0400
committerlempamo <[email protected]>2017-04-01 12:18:36 -0400
commita02ef083865152de3a5d99090e5e15cf30ff3fe7 (patch)
treefce0da1bf4d06d831fbe0e36f048b5acd1c2ce56 /TimeHACK.Main
parentf75639a00c5b006756886ddd55c7ca6e34c35e51 (diff)
downloadhistacom2-a02ef083865152de3a5d99090e5e15cf30ff3fe7.tar.gz
histacom2-a02ef083865152de3a5d99090e5e15cf30ff3fe7.tar.bz2
histacom2-a02ef083865152de3a5d99090e5e15cf30ff3fe7.zip
a little more conversation
Diffstat (limited to 'TimeHACK.Main')
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.Designer.cs3
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.cs65
-rw-r--r--TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.resx28
3 files changed, 81 insertions, 15 deletions
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.Designer.cs b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.Designer.cs
index 545a796..af44554 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.Designer.cs
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.Designer.cs
@@ -233,6 +233,7 @@
this.button2.TabIndex = 8;
this.button2.Text = "Speak";
this.button2.UseVisualStyleBackColor = true;
+ this.button2.Click += new System.EventHandler(this.Button2_Click);
//
// button3
//
@@ -242,6 +243,7 @@
this.button3.TabIndex = 9;
this.button3.Text = "Paul";
this.button3.UseVisualStyleBackColor = true;
+ this.button3.Click += new System.EventHandler(this.Button3_Click);
//
// button4
//
@@ -251,6 +253,7 @@
this.button4.TabIndex = 10;
this.button4.Text = "Bill";
this.button4.UseVisualStyleBackColor = true;
+ this.button4.Click += new System.EventHandler(this.Button4_Click);
//
// WebChat1998
//
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.cs b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.cs
index fa0837f..c18ba20 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.cs
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.cs
@@ -16,6 +16,7 @@ namespace TimeHACK.OS.Win95.Win95Apps
{
int chat_index = 0;
WCMessageParser wcmp = new WCMessageParser();
+ bool correctname = false;
public WebChat1998()
{
@@ -36,6 +37,7 @@ namespace TimeHACK.OS.Win95.Win95Apps
wm.startInfobox95("Invalid Username", "Your username cannot be blank.");
return;
}
+ ParentForm.AcceptButton = button2;
TitleScreen.username = txtscreenname.Text;
login.Hide();
listBox1.Items.Add(TitleScreen.username);
@@ -45,24 +47,57 @@ namespace TimeHACK.OS.Win95.Win95Apps
private void Chat_Tick(object sender, EventArgs e)
{
- history.Text += wcmp.ParseMessage(resources.GetString("convo"), chat_index, TitleScreen.username) + Environment.NewLine;
- switch (wcmp.GetSpecial(resources.GetString("convo"), chat_index))
+ if (chat_index != 6)
{
- case "addsh":
- listBox1.Items.Add("SkyHigh");
- break;
- case "nameguess":
- typechat.Hide();
- button2.Hide();
- button3.Show();
- button4.Show();
- Chat.Stop();
- break;
- default:
- break;
+ history.Text += wcmp.ParseMessage(resources.GetString("convo"), chat_index, TitleScreen.username) + Environment.NewLine;
+ switch (wcmp.GetSpecial(resources.GetString("convo"), chat_index))
+ {
+ case "addsh":
+ listBox1.Items.Add("SkyHigh");
+ break;
+ case "nameguess":
+ typechat.Hide();
+ button2.Hide();
+ button3.Show();
+ button4.Show();
+ Chat.Stop();
+ break;
+ case "addrain":
+ listBox1.Items.Add("rain49");
+ break;
+ default:
+ break;
+ }
+ Chat.Interval = wcmp.GetMessageDelay(resources.GetString("convo"), chat_index);
+ }
+ else
+ {
+ if (correctname)
+ {
+ history.Text += "SkyHigh: yay you got it right!" + Environment.NewLine;
+ }
+ else
+ {
+ history.Text += "SkyHigh: sorry, my name is actually bill" + Environment.NewLine;
+ }
+ Chat.Interval = wcmp.GetMessageDelay(resources.GetString("convo"), chat_index);
}
- Chat.Interval = wcmp.GetMessageDelay(resources.GetString("convo"), chat_index);
chat_index++;
}
+
+ private void Button2_Click(object sender, EventArgs e)
+ {
+ if (typechat.Text != "") history.Text += TitleScreen.username + ": " + typechat.Text + Environment.NewLine;
+ }
+
+ private void Button3_Click(object sender, EventArgs e)
+ {
+ correctname = true; Chat.Start();
+ }
+
+ private void Button4_Click(object sender, EventArgs e)
+ {
+ correctname = false; Chat.Start();
+ }
}
}
diff --git a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.resx b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.resx
index 6734aab..7ab7db0 100644
--- a/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.resx
+++ b/TimeHACK.Main/OS/Win95/Win95Apps/WebChat1998.resx
@@ -165,6 +165,34 @@
"message": "ill make 2 buttons pop up, you click the one you want to guess",
"special": "nameguess",
"userchat": true
+ },
+ {
+ "user": "SkyHigh",
+ "delay": 5000,
+ "message": "actually, if ya dont wanna do that its fine, i guess",
+ "special": null,
+ "userchat": true
+ },
+ {
+ "user": "System",
+ "delay": 3000,
+ "message": "rain49 has joined the chat.",
+ "special": "addrain",
+ "userchat": true
+ },
+ {
+ "user": "SkyHigh",
+ "delay": 6000,
+ "message": "hey man",
+ "special": null,
+ "userchat": true
+ },
+ {
+ "user": "SkyHigh",
+ "delay": 6000,
+ "message": "ive sort of been waiting",
+ "special": null,
+ "userchat": true
}
]
}</value>