mirror of
https://github.com/HistacomUnity/Histacom2-old.git
synced 2025-01-22 09:02:01 -05:00
Merge branch 'master' of https://github.com/TimeHACKDevs/TimeHACK.git
This commit is contained in:
commit
75d4f6c762
14 changed files with 558 additions and 32 deletions
|
@ -28,8 +28,6 @@ TimeHACK has a YouTube channel at https://www.youtube.com/channel/UCU3uiIgHdLaNv
|
|||
TimeHACK's documentation can be found on the TimeHACK Wiki: https://github.com/TimeHACKDevs/TimeHACK/wiki
|
||||
|
||||
## Other Repositories
|
||||
* A completely discontinued project called "HistacomVB".
|
||||
The idea of it being that it was the old game except being built upon. In the end, however, we stopped it because having "HistacomVB" and "TimeHACK" was unnecessary. If you REALLY want to see the repo, click here: http://www.github.com/TimeHACKDevs/HistacomVB
|
||||
* An unofficial project called "Histacom.AU".
|
||||
This is a rewrite of Histacom in Python, and has a place [here](https://github.com/TimeHACKDevs/histacom-au).
|
||||
|
||||
|
|
|
@ -652,6 +652,15 @@ public class Save
|
|||
[Order]
|
||||
public bool FTime95 { get; set; }
|
||||
|
||||
[Order]
|
||||
public int mineSweepE { get; set; } = 999;
|
||||
|
||||
[Order]
|
||||
public int mineSweepI { get; set; } = 999;
|
||||
|
||||
[Order]
|
||||
public int mineSweepH { get; set; } = 999;
|
||||
|
||||
[Order]
|
||||
public string ThemeName { get; set; }
|
||||
|
||||
|
|
10
TimeHACK.Engine/Template/WinClassic.Designer.cs
generated
10
TimeHACK.Engine/Template/WinClassic.Designer.cs
generated
|
@ -155,11 +155,13 @@ private void InitializeComponent()
|
|||
//
|
||||
this.toprightcorner.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.toprightcorner.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("toprightcorner.BackgroundImage")));
|
||||
this.toprightcorner.Cursor = System.Windows.Forms.Cursors.SizeNESW;
|
||||
this.toprightcorner.Location = new System.Drawing.Point(296, 0);
|
||||
this.toprightcorner.Name = "toprightcorner";
|
||||
this.toprightcorner.Size = new System.Drawing.Size(4, 4);
|
||||
this.toprightcorner.TabIndex = 6;
|
||||
this.toprightcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.border_MouseDown);
|
||||
this.toprightcorner.MouseMove += new System.Windows.Forms.MouseEventHandler(this.toprightcorner_MouseMove);
|
||||
//
|
||||
// bottomrightcorner
|
||||
//
|
||||
|
@ -171,29 +173,35 @@ private void InitializeComponent()
|
|||
this.bottomrightcorner.Size = new System.Drawing.Size(4, 4);
|
||||
this.bottomrightcorner.TabIndex = 4;
|
||||
this.bottomrightcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.border_MouseDown);
|
||||
this.bottomrightcorner.MouseMove += new System.Windows.Forms.MouseEventHandler(this.bottomrightcorner_MouseMove);
|
||||
//
|
||||
// bottomleftcorner
|
||||
//
|
||||
this.bottomleftcorner.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
|
||||
this.bottomleftcorner.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("bottomleftcorner.BackgroundImage")));
|
||||
this.bottomleftcorner.Cursor = System.Windows.Forms.Cursors.SizeNESW;
|
||||
this.bottomleftcorner.Location = new System.Drawing.Point(0, 296);
|
||||
this.bottomleftcorner.Name = "bottomleftcorner";
|
||||
this.bottomleftcorner.Size = new System.Drawing.Size(4, 4);
|
||||
this.bottomleftcorner.TabIndex = 2;
|
||||
this.bottomleftcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.border_MouseDown);
|
||||
this.bottomleftcorner.MouseMove += new System.Windows.Forms.MouseEventHandler(this.bottomleftcorner_MouseMove);
|
||||
//
|
||||
// topleftcorner
|
||||
//
|
||||
this.topleftcorner.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("topleftcorner.BackgroundImage")));
|
||||
this.topleftcorner.Cursor = System.Windows.Forms.Cursors.SizeNWSE;
|
||||
this.topleftcorner.Location = new System.Drawing.Point(0, 0);
|
||||
this.topleftcorner.Name = "topleftcorner";
|
||||
this.topleftcorner.Size = new System.Drawing.Size(4, 4);
|
||||
this.topleftcorner.TabIndex = 1;
|
||||
this.topleftcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.border_MouseDown);
|
||||
this.topleftcorner.MouseMove += new System.Windows.Forms.MouseEventHandler(this.topleftcorner_MouseMove);
|
||||
//
|
||||
// left
|
||||
//
|
||||
this.left.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("left.BackgroundImage")));
|
||||
this.left.Cursor = System.Windows.Forms.Cursors.SizeWE;
|
||||
this.left.Dock = System.Windows.Forms.DockStyle.Left;
|
||||
this.left.Location = new System.Drawing.Point(0, 4);
|
||||
this.left.Name = "left";
|
||||
|
@ -231,12 +239,14 @@ private void InitializeComponent()
|
|||
//
|
||||
this.top.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("top.BackgroundImage")));
|
||||
this.top.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
|
||||
this.top.Cursor = System.Windows.Forms.Cursors.SizeNS;
|
||||
this.top.Dock = System.Windows.Forms.DockStyle.Top;
|
||||
this.top.Location = new System.Drawing.Point(0, 0);
|
||||
this.top.Name = "top";
|
||||
this.top.Size = new System.Drawing.Size(300, 4);
|
||||
this.top.TabIndex = 8;
|
||||
this.top.MouseDown += new System.Windows.Forms.MouseEventHandler(this.border_MouseDown);
|
||||
this.top.MouseMove += new System.Windows.Forms.MouseEventHandler(this.top_MouseMove);
|
||||
//
|
||||
// WinClassic
|
||||
//
|
||||
|
|
|
@ -67,6 +67,7 @@ private void WinClassic_Deactivate(object sender, EventArgs e)
|
|||
Title.ForeColor = SaveSystem.currentTheme.inactiveTitleTextColor;
|
||||
}
|
||||
|
||||
|
||||
private void right_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
|
@ -79,18 +80,67 @@ private void left_MouseMove(object sender, MouseEventArgs e)
|
|||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Size = new Size(this.Size.Width + (this.Location.X - MousePosition.X), this.Size.Height);
|
||||
if (resizable) this.Location = new Point(MousePosition.X, this.Location.Y);
|
||||
if (resizable) this.Width = ((this.Width + this.Location.X) - Cursor.Position.X);
|
||||
if (resizable)this.Location = new Point(Cursor.Position.X, this.Location.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void bottom_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left) {
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Size = new Size(this.Size.Width, MousePosition.Y - this.Location.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void bottomrightcorner_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Size = new Size(MousePosition.X - this.Location.X, MousePosition.Y - this.Location.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void bottomleftcorner_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Width = ((this.Width + this.Location.X) - Cursor.Position.X);
|
||||
if (resizable) this.Height = (Cursor.Position.Y - this.Location.Y);
|
||||
if (resizable) this.Location = new Point(Cursor.Position.X, this.Location.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void topleftcorner_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Width = ((this.Width + this.Location.X) - Cursor.Position.X);
|
||||
if (resizable) this.Location = new Point(Cursor.Position.X, this.Location.Y);
|
||||
if (resizable) this.Height = ((this.Height + this.Location.Y) - Cursor.Position.Y);
|
||||
if (resizable) this.Location = new Point(this.Location.X, Cursor.Position.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void top_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if(e.Button == MouseButtons.Left)
|
||||
{
|
||||
if(resizable) this.Height = ((this.Height + this.Location.Y) - Cursor.Position.Y);
|
||||
if(resizable) this.Location = new Point(this.Location.X, Cursor.Position.Y);
|
||||
}
|
||||
}
|
||||
|
||||
private void toprightcorner_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Left)
|
||||
{
|
||||
if (resizable) this.Width = (Cursor.Position.X - this.Location.X);
|
||||
if (resizable) this.Height = ((this.Location.Y - Cursor.Position.Y) + this.Height);
|
||||
if (resizable) this.Location = new Point(this.Location.X, Cursor.Position.Y);
|
||||
}
|
||||
}
|
||||
|
||||
public bool max = false;
|
||||
|
||||
private void maximizebutton_Click(object sender, EventArgs e)
|
||||
|
|
|
@ -125,7 +125,7 @@
|
|||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAABw
|
||||
CwAAAk1TRnQBSQFMAgEBAgEAASABAAEgAQABIAEAASABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
CwAAAk1TRnQBSQFMAgEBAgEAATABAAEwAQABIAEAASABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
AwABgAMAASADAAEBAQABCAYAARAYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
|
||||
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
|
||||
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
|
||||
|
|
|
@ -16,10 +16,11 @@ public class Game
|
|||
private int _mines;
|
||||
private Panel _panel;
|
||||
private Square[,] _squares;
|
||||
private Timer _timer;
|
||||
public Timer _timer;
|
||||
private int _width;
|
||||
public bool ftime = true;
|
||||
public int Time;
|
||||
public bool win = false;
|
||||
|
||||
public Game(Panel panel, int width, int height, int mines)
|
||||
{
|
||||
|
@ -27,15 +28,12 @@ public Game(Panel panel, int width, int height, int mines)
|
|||
_width = width;
|
||||
_height = height;
|
||||
_mines = mines;
|
||||
win = false;
|
||||
}
|
||||
|
||||
private void Dismantle(object sender, EventArgs e)
|
||||
{
|
||||
if(ftime == true)
|
||||
{
|
||||
ftime = false;
|
||||
OnTick();
|
||||
}
|
||||
|
||||
Square s = (Square)sender;
|
||||
if (s.Dismantled)
|
||||
{
|
||||
|
@ -66,6 +64,7 @@ private void Dismantle(object sender, EventArgs e)
|
|||
{
|
||||
_timer.Enabled = false;
|
||||
Panel.Enabled = false;
|
||||
win = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -77,7 +76,6 @@ public int DismantledMines
|
|||
private void Explode(object sender, EventArgs e)
|
||||
{
|
||||
_timer.Enabled = false;
|
||||
|
||||
foreach (Square s in _squares)
|
||||
{
|
||||
s.RemoveEvents();
|
||||
|
@ -114,6 +112,7 @@ public int Mines
|
|||
|
||||
protected void OnDismantledMinesChanged()
|
||||
{
|
||||
|
||||
if (DismantledMinesChanged != null)
|
||||
{
|
||||
DismantledMinesChanged(this, new EventArgs());
|
||||
|
@ -184,14 +183,9 @@ public void Start()
|
|||
}
|
||||
|
||||
OnDismantledMinesChanged();
|
||||
|
||||
_timer = new Timer();
|
||||
_timer.Interval = 1000;
|
||||
_timer.Tick += new EventHandler(TimerTick);
|
||||
_timer.Enabled = true;
|
||||
}
|
||||
|
||||
private void TimerTick(object sender, EventArgs e)
|
||||
public void TimerTick(object sender, EventArgs e)
|
||||
{
|
||||
Time++;
|
||||
OnTick();
|
||||
|
|
201
TimeHACK.Main/OS/Win95/Win95Apps/MineSweeper/MineBestTimes.Designer.cs
generated
Normal file
201
TimeHACK.Main/OS/Win95/Win95Apps/MineSweeper/MineBestTimes.Designer.cs
generated
Normal file
|
@ -0,0 +1,201 @@
|
|||
namespace TimeHACK.OS.Win95.Win95Apps.MineSweeper
|
||||
{
|
||||
partial class MineBestTimes
|
||||
{
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Component Designer generated code
|
||||
|
||||
/// <summary>
|
||||
/// Required method for Designer support - do not modify
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.label7 = new System.Windows.Forms.Label();
|
||||
this.label8 = new System.Windows.Forms.Label();
|
||||
this.label9 = new System.Windows.Forms.Label();
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.button2 = new System.Windows.Forms.Button();
|
||||
this.timer1 = new System.Windows.Forms.Timer(this.components);
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label1.Location = new System.Drawing.Point(20, 23);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(103, 25);
|
||||
this.label1.TabIndex = 0;
|
||||
this.label1.Text = "Begginner:";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label2.Location = new System.Drawing.Point(20, 71);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(123, 25);
|
||||
this.label2.TabIndex = 1;
|
||||
this.label2.Text = "Intermediate:";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label3.Location = new System.Drawing.Point(20, 124);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(69, 25);
|
||||
this.label3.TabIndex = 2;
|
||||
this.label3.Text = "Expert:";
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label4.Location = new System.Drawing.Point(95, 23);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(115, 25);
|
||||
this.label4.TabIndex = 3;
|
||||
this.label4.Text = "999 seconds";
|
||||
//
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label5.Location = new System.Drawing.Point(95, 71);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(115, 25);
|
||||
this.label5.TabIndex = 4;
|
||||
this.label5.Text = "999 seconds";
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label6.Location = new System.Drawing.Point(95, 124);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(115, 25);
|
||||
this.label6.TabIndex = 5;
|
||||
this.label6.Text = "999 seconds";
|
||||
//
|
||||
// label7
|
||||
//
|
||||
this.label7.AutoSize = true;
|
||||
this.label7.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label7.Location = new System.Drawing.Point(160, 23);
|
||||
this.label7.Name = "label7";
|
||||
this.label7.Size = new System.Drawing.Size(112, 25);
|
||||
this.label7.TabIndex = 6;
|
||||
this.label7.Text = "Anonymous";
|
||||
//
|
||||
// label8
|
||||
//
|
||||
this.label8.AutoSize = true;
|
||||
this.label8.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label8.Location = new System.Drawing.Point(160, 71);
|
||||
this.label8.Name = "label8";
|
||||
this.label8.Size = new System.Drawing.Size(112, 25);
|
||||
this.label8.TabIndex = 7;
|
||||
this.label8.Text = "Anonymous";
|
||||
//
|
||||
// label9
|
||||
//
|
||||
this.label9.AutoSize = true;
|
||||
this.label9.Font = new System.Drawing.Font("Segoe UI", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label9.Location = new System.Drawing.Point(160, 124);
|
||||
this.label9.Name = "label9";
|
||||
this.label9.Size = new System.Drawing.Size(112, 25);
|
||||
this.label9.TabIndex = 8;
|
||||
this.label9.Text = "Anonymous";
|
||||
//
|
||||
// button1
|
||||
//
|
||||
this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.button1.Location = new System.Drawing.Point(193, 167);
|
||||
this.button1.Name = "button1";
|
||||
this.button1.Size = new System.Drawing.Size(75, 23);
|
||||
this.button1.TabIndex = 9;
|
||||
this.button1.Text = "OK";
|
||||
this.button1.UseVisualStyleBackColor = true;
|
||||
this.button1.Click += new System.EventHandler(this.button1_Click);
|
||||
//
|
||||
// button2
|
||||
//
|
||||
this.button2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.button2.Location = new System.Drawing.Point(45, 167);
|
||||
this.button2.Name = "button2";
|
||||
this.button2.Size = new System.Drawing.Size(98, 23);
|
||||
this.button2.TabIndex = 10;
|
||||
this.button2.Text = "Reset Scores";
|
||||
this.button2.UseVisualStyleBackColor = true;
|
||||
this.button2.Click += new System.EventHandler(this.button2_Click);
|
||||
//
|
||||
// timer1
|
||||
//
|
||||
this.timer1.Interval = 1;
|
||||
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
|
||||
//
|
||||
// MineBestTimes
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.Controls.Add(this.button2);
|
||||
this.Controls.Add(this.button1);
|
||||
this.Controls.Add(this.label9);
|
||||
this.Controls.Add(this.label8);
|
||||
this.Controls.Add(this.label7);
|
||||
this.Controls.Add(this.label6);
|
||||
this.Controls.Add(this.label5);
|
||||
this.Controls.Add(this.label4);
|
||||
this.Controls.Add(this.label3);
|
||||
this.Controls.Add(this.label2);
|
||||
this.Controls.Add(this.label1);
|
||||
this.Name = "MineBestTimes";
|
||||
this.Size = new System.Drawing.Size(299, 209);
|
||||
this.Load += new System.EventHandler(this.MineBestTimes_Load);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Label label2;
|
||||
private System.Windows.Forms.Label label3;
|
||||
private System.Windows.Forms.Label label4;
|
||||
private System.Windows.Forms.Label label5;
|
||||
private System.Windows.Forms.Label label6;
|
||||
private System.Windows.Forms.Label label7;
|
||||
private System.Windows.Forms.Label label8;
|
||||
private System.Windows.Forms.Label label9;
|
||||
private System.Windows.Forms.Button button1;
|
||||
private System.Windows.Forms.Button button2;
|
||||
private System.Windows.Forms.Timer timer1;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,71 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Drawing;
|
||||
using System.Data;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using TimeHACK.Engine;
|
||||
|
||||
namespace TimeHACK.OS.Win95.Win95Apps.MineSweeper
|
||||
{
|
||||
public partial class MineBestTimes : UserControl
|
||||
{
|
||||
public MineBestTimes()
|
||||
{
|
||||
InitializeComponent();
|
||||
foreach (Control c in Controls)
|
||||
{
|
||||
if (c is Button)
|
||||
{
|
||||
c.Font = new Font(TitleScreen.pfc.Families[0], 16F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(0)));
|
||||
c.Paint += (sender, args) => Paintbrush.PaintClassicBorders(sender, args, 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
c.Font = new Font(TitleScreen.pfc.Families[0], 16F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void MineBestTimes_Load(object sender, EventArgs e)
|
||||
{
|
||||
timer1.Start();
|
||||
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
ParentForm.Close();
|
||||
}
|
||||
|
||||
private void button2_Click(object sender, EventArgs e)
|
||||
{
|
||||
SaveSystem.CurrentSave.mineSweepE = 999;
|
||||
SaveSystem.CurrentSave.mineSweepI = 999;
|
||||
SaveSystem.CurrentSave.mineSweepH = 999;
|
||||
SaveSystem.SaveGame();
|
||||
}
|
||||
|
||||
private void timer1_Tick(object sender, EventArgs e)
|
||||
{
|
||||
label4.Text = (SaveSystem.CurrentSave.mineSweepE.ToString()) + " seconds";
|
||||
label5.Text = (SaveSystem.CurrentSave.mineSweepI.ToString()) + " seconds";
|
||||
label6.Text = (SaveSystem.CurrentSave.mineSweepH.ToString()) + " seconds";
|
||||
if(SaveSystem.CurrentSave.mineSweepE != 999)
|
||||
{
|
||||
label7.Text = SaveSystem.ProfileName;
|
||||
}
|
||||
if(SaveSystem.CurrentSave.mineSweepI != 999)
|
||||
{
|
||||
label8.Text = SaveSystem.ProfileName;
|
||||
};
|
||||
if(SaveSystem.CurrentSave.mineSweepH != 999)
|
||||
{
|
||||
label9.Text = SaveSystem.ProfileName;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
123
TimeHACK.Main/OS/Win95/Win95Apps/MineSweeper/MineBestTimes.resx
Normal file
123
TimeHACK.Main/OS/Win95/Win95Apps/MineSweeper/MineBestTimes.resx
Normal file
|
@ -0,0 +1,123 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
|
@ -1,5 +1,6 @@
|
|||
using System;
|
||||
using System.Drawing;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using TimeHACK.Engine;
|
||||
|
||||
|
@ -51,6 +52,7 @@ public Button Button
|
|||
|
||||
private void Click(object sender, System.EventArgs e)
|
||||
{
|
||||
|
||||
if (!Dismantled)
|
||||
{
|
||||
if (Minded)
|
||||
|
@ -63,6 +65,14 @@ private void Click(object sender, System.EventArgs e)
|
|||
this.Open();
|
||||
}
|
||||
}
|
||||
if (_game.ftime == true)
|
||||
{
|
||||
_game.ftime = false;
|
||||
_game._timer = new Timer();
|
||||
_game._timer.Interval = 1000;
|
||||
_game._timer.Tick += new EventHandler(_game.TimerTick);
|
||||
_game._timer.Enabled = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void DismantleClick(object sender, MouseEventArgs e)
|
||||
|
@ -75,9 +85,17 @@ private void DismantleClick(object sender, MouseEventArgs e)
|
|||
Button.BackgroundImage = null;
|
||||
Button.Text = "?";
|
||||
}
|
||||
else if(Button.Text == "?")
|
||||
{
|
||||
_dismantled = false;
|
||||
Button.BackgroundImage = null;
|
||||
Button.Text = "";
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
_dismantled = true;
|
||||
Button.Text = "";
|
||||
Button.BackgroundImage = Properties.Resources.WinClassicMinesweeperFlag;
|
||||
}
|
||||
OnDismantle();
|
||||
|
|
|
@ -28,6 +28,7 @@ protected override void Dispose(bool disposing)
|
|||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
this.labelBombs = new System.Windows.Forms.Label();
|
||||
this.labelTime = new System.Windows.Forms.Label();
|
||||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
|
@ -51,6 +52,7 @@ private void InitializeComponent()
|
|||
this.toolStripSeparator5 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.aboutMinesweeperToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.timer1 = new System.Windows.Forms.Timer(this.components);
|
||||
this.menuStrip1.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
|
@ -209,6 +211,7 @@ private void InitializeComponent()
|
|||
this.bestTimesToolStripMenuItem.Text = "Best Times";
|
||||
this.bestTimesToolStripMenuItem.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.bestTimesToolStripMenuItem.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
|
||||
this.bestTimesToolStripMenuItem.Click += new System.EventHandler(this.bestTimesToolStripMenuItem_Click);
|
||||
//
|
||||
// toolStripSeparator4
|
||||
//
|
||||
|
@ -223,6 +226,7 @@ private void InitializeComponent()
|
|||
this.exitToolStripMenuItem.Text = "Exit";
|
||||
this.exitToolStripMenuItem.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
this.exitToolStripMenuItem.TextImageRelation = System.Windows.Forms.TextImageRelation.TextBeforeImage;
|
||||
this.exitToolStripMenuItem.Click += new System.EventHandler(this.exitToolStripMenuItem_Click);
|
||||
//
|
||||
// helpToolStripMenuItem
|
||||
//
|
||||
|
@ -264,6 +268,11 @@ private void InitializeComponent()
|
|||
this.button1.UseVisualStyleBackColor = true;
|
||||
this.button1.Click += new System.EventHandler(this.button1_Click);
|
||||
//
|
||||
// timer1
|
||||
//
|
||||
this.timer1.Interval = 1;
|
||||
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
|
||||
//
|
||||
// WinClassicMinesweeper
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
|
@ -308,5 +317,6 @@ private void InitializeComponent()
|
|||
private System.Windows.Forms.ToolStripSeparator toolStripSeparator5;
|
||||
private System.Windows.Forms.ToolStripMenuItem aboutMinesweeperToolStripMenuItem;
|
||||
private System.Windows.Forms.Button button1;
|
||||
private System.Windows.Forms.Timer timer1;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using TimeHACK.OS.Win95.Win95Apps.MineSweeper;
|
||||
using TimeHACK.Engine;
|
||||
|
||||
namespace TimeHACK.OS.Win95.Win95Apps
|
||||
{
|
||||
|
@ -56,36 +57,65 @@ private void expertToolStripMenuItem_Click(object sender, EventArgs e)
|
|||
}
|
||||
private void button1_Click(object sender, EventArgs e)
|
||||
{
|
||||
labelTime.Text = "0";
|
||||
switch (level)
|
||||
{
|
||||
case ("easy"):
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
_game = new Game(this.panel1, 8, 8, 10);
|
||||
_game.Tick += new EventHandler(GameTick);
|
||||
_game.DismantledMinesChanged += new EventHandler(GameDismantledMinesChanged);
|
||||
_game.Start();
|
||||
return;
|
||||
break;
|
||||
case ("medium"):
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
_game = new Game(this.panel1, 16, 16, 46);
|
||||
_game.Tick += new EventHandler(GameTick);
|
||||
_game.DismantledMinesChanged += new EventHandler(GameDismantledMinesChanged);
|
||||
_game.Start();
|
||||
return;
|
||||
_game = new Game(this.panel1, 16, 16, 40);
|
||||
break;
|
||||
case ("hard"):
|
||||
Cursor.Current = Cursors.WaitCursor;
|
||||
_game = new Game(this.panel1, 30, 16, 99);
|
||||
_game.Tick += new EventHandler(GameTick);
|
||||
_game.DismantledMinesChanged += new EventHandler(GameDismantledMinesChanged);
|
||||
_game.Start();
|
||||
return;
|
||||
break;
|
||||
}
|
||||
_game.Tick += new EventHandler(GameTick);
|
||||
_game.DismantledMinesChanged += new EventHandler(GameDismantledMinesChanged);
|
||||
_game.Start();
|
||||
|
||||
}
|
||||
|
||||
private void WinClassicMinesweeper_Load(object sender, EventArgs e)
|
||||
{
|
||||
begginnerToolStripMenuItem.PerformClick();
|
||||
timer1.Start();
|
||||
}
|
||||
|
||||
private void bestTimesToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
WindowManager wm = new WindowManager();
|
||||
wm.StartWin95(new MineBestTimes(), "Best Times", null, false, false, true, false);
|
||||
|
||||
}
|
||||
|
||||
private void timer1_Tick(object sender, EventArgs e)
|
||||
{
|
||||
if(_game.win == true)
|
||||
{
|
||||
switch (level)
|
||||
{
|
||||
case ("easy"):
|
||||
SaveSystem.CurrentSave.mineSweepE = _game.Time;
|
||||
break;
|
||||
case ("medium"):
|
||||
SaveSystem.CurrentSave.mineSweepI = _game.Time;
|
||||
break;
|
||||
case ("hard"):
|
||||
SaveSystem.CurrentSave.mineSweepH = _game.Time;
|
||||
break;
|
||||
|
||||
}
|
||||
SaveSystem.SaveGame();
|
||||
}
|
||||
}
|
||||
|
||||
private void exitToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.ParentForm.Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -120,6 +120,9 @@
|
|||
<metadata name="menuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>132, 17</value>
|
||||
</metadata>
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>48</value>
|
||||
</metadata>
|
||||
|
|
|
@ -163,6 +163,12 @@
|
|||
<DependentUpon>IE4Start.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OS\Win95\Win95Apps\MineSweeper\Game.cs" />
|
||||
<Compile Include="OS\Win95\Win95Apps\MineSweeper\MineBestTimes.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
<Compile Include="OS\Win95\Win95Apps\MineSweeper\MineBestTimes.Designer.cs">
|
||||
<DependentUpon>MineBestTimes.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OS\Win95\Win95Apps\MineSweeper\Square.cs" />
|
||||
<Compile Include="OS\Win95\Win95Apps\Story\Hack1.cs" />
|
||||
<Compile Include="OS\Win95\Win95Apps\Story\Hack2.cs" />
|
||||
|
@ -357,6 +363,9 @@
|
|||
<EmbeddedResource Include="OS\Win95\Win95Apps\IE4Sites\IE4Start.resx">
|
||||
<DependentUpon>IE4Start.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="OS\Win95\Win95Apps\MineSweeper\MineBestTimes.resx">
|
||||
<DependentUpon>MineBestTimes.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="OS\Win95\Win95Apps\WinClassicIE4.resx">
|
||||
<DependentUpon>WinClassicIE4.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
|
|
Loading…
Reference in a new issue