aboutsummaryrefslogtreecommitdiff
path: root/TimeHACK.Engine
diff options
context:
space:
mode:
authorlempamo <[email protected]>2017-08-01 13:05:37 -0400
committerlempamo <[email protected]>2017-08-01 13:05:37 -0400
commitc0fd6c4d1b176d44f05d2f20c4d4439f3278f632 (patch)
tree5b0ef118aa352bb7a452a1618ddb35fd9a5256fb /TimeHACK.Engine
parent554fc5e2b3027f104fceda0421fed4352749d0f8 (diff)
downloadhistacom2-c0fd6c4d1b176d44f05d2f20c4d4439f3278f632.tar.gz
histacom2-c0fd6c4d1b176d44f05d2f20c4d4439f3278f632.tar.bz2
histacom2-c0fd6c4d1b176d44f05d2f20c4d4439f3278f632.zip
added more "files"
Diffstat (limited to 'TimeHACK.Engine')
-rw-r--r--TimeHACK.Engine/SaveSystem.cs28
-rw-r--r--TimeHACK.Engine/Template/Infobox95.Designer.cs14
2 files changed, 25 insertions, 17 deletions
diff --git a/TimeHACK.Engine/SaveSystem.cs b/TimeHACK.Engine/SaveSystem.cs
index f328144..32e2661 100644
--- a/TimeHACK.Engine/SaveSystem.cs
+++ b/TimeHACK.Engine/SaveSystem.cs
@@ -186,10 +186,14 @@ namespace TimeHACK.Engine
SaveDirectoryInfo(ProfileWindowsDirectory, "Temp", true, "Temp", true);
SaveDirectoryInfo(ProfileWindowsDirectory, "Desktop", true, "Desktop", true);
+ CreateWindowsFile(ProfileWindowsDirectory, "c", "", 8, 515);
CreateWindowsFile(ProfileWindowsDirectory, "calc.exe", "calc", 13, 59392);
+ CreateWindowsFile(ProfileWindowsDirectory, "emm386.exe", "emm386", 10, 125495);
CreateWindowsFile(ProfileWindowsDirectory, "explorer.exe", "explorer", 0, 204288);
CreateWindowsFile(ProfileWindowsDirectory, "notepad.exe", "notepad", 14, 34034);
CreateWindowsFile(ProfileWindowsDirectory, "regedit.exe", "regedit", 15, 120320);
+ CreateWindowsFile(ProfileWindowsDirectory, "win.com", "", 10, 22679);
+ CreateWindowsFile(ProfileWindowsDirectory, "write.exe", "wordpad", 16, 5120);
}
public static void CreateWindowsFile(string filepath, string filename, string contents, int fileicon = 8, int bytes = 512)
@@ -206,18 +210,22 @@ namespace TimeHACK.Engine
public static void UpdateDirectoryInfo(string path, THFileInfo newfile)
{
newfile.DOSName = newfile.Name.ToUpper().Replace("*", "").Replace("+", "").Replace(":", "").Replace(";", "").Replace(" ", "");
- string[] dos = newfile.DOSName.Split('.');
-
- if (dos.Count() > 2)
+ if (newfile.DOSName.Contains("."))
{
- List<string> dosb = dos.ToList();
- dosb.RemoveRange(1, dos.Count() - 2);
- dos = dosb.ToArray();
- }
- dos[1] = dos[1].Substring(0, 3);
- if (dos[0].Length > 8) dos[0] = dos[0].Substring(0, 6) + "~1";
+ string[] dos = newfile.DOSName.Split('.');
+
+ if (dos.Count() > 2)
+ {
+ List<string> dosb = dos.ToList();
+ dosb.RemoveRange(1, dos.Count() - 2);
+ dos = dosb.ToArray();
+ }
+ dos[1] = dos[1].Substring(0, 3);
+ if (dos[0].Length > 8) dos[0] = dos[0].Substring(0, 6) + "~1";
- newfile.DOSName = dos[0] + "." + dos[1];
+ newfile.DOSName = dos[0] + "." + dos[1];
+ }
+ else if (newfile.DOSName.Length > 8) newfile.DOSName = newfile.DOSName.Substring(0, 6) + "~1";
if (File.ReadAllText(Path.Combine(path, "_data.info")).Contains(newfile.DOSName)) return;
FileSystemFolderInfo fsfi = JsonConvert.DeserializeObject<FileSystemFolderInfo>(File.ReadAllText(Path.Combine(path, "_data.info")));
diff --git a/TimeHACK.Engine/Template/Infobox95.Designer.cs b/TimeHACK.Engine/Template/Infobox95.Designer.cs
index 56d6568..f9d89c7 100644
--- a/TimeHACK.Engine/Template/Infobox95.Designer.cs
+++ b/TimeHACK.Engine/Template/Infobox95.Designer.cs
@@ -51,7 +51,7 @@
this.programContent.Dock = System.Windows.Forms.DockStyle.Fill;
this.programContent.Location = new System.Drawing.Point(0, 0);
this.programContent.Name = "programContent";
- this.programContent.Size = new System.Drawing.Size(413, 138);
+ this.programContent.Size = new System.Drawing.Size(413, 118);
this.programContent.TabIndex = 10;
this.programContent.Tag = "gnoreFormOnTaskbar";
//
@@ -61,7 +61,7 @@
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
- this.button1.Location = new System.Drawing.Point(150, 104);
+ this.button1.Location = new System.Drawing.Point(150, 84);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(80, 23);
this.button1.TabIndex = 5;
@@ -75,7 +75,7 @@
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.button3.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
- this.button3.Location = new System.Drawing.Point(323, 104);
+ this.button3.Location = new System.Drawing.Point(323, 84);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(80, 23);
this.button3.TabIndex = 4;
@@ -99,7 +99,7 @@
this.panel1.Controls.Add(this.infoText);
this.panel1.Location = new System.Drawing.Point(62, 16);
this.panel1.Name = "panel1";
- this.panel1.Size = new System.Drawing.Size(341, 82);
+ this.panel1.Size = new System.Drawing.Size(341, 62);
this.panel1.TabIndex = 2;
//
// infoText
@@ -107,7 +107,7 @@
this.infoText.Dock = System.Windows.Forms.DockStyle.Fill;
this.infoText.Location = new System.Drawing.Point(0, 0);
this.infoText.Name = "infoText";
- this.infoText.Size = new System.Drawing.Size(341, 82);
+ this.infoText.Size = new System.Drawing.Size(341, 62);
this.infoText.TabIndex = 0;
this.infoText.Text = "label1";
//
@@ -117,7 +117,7 @@
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.button2.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
- this.button2.Location = new System.Drawing.Point(236, 104);
+ this.button2.Location = new System.Drawing.Point(236, 84);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(80, 23);
this.button2.TabIndex = 1;
@@ -131,7 +131,7 @@
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.programContent);
this.Name = "Infobox95";
- this.Size = new System.Drawing.Size(413, 138);
+ this.Size = new System.Drawing.Size(413, 118);
this.programContent.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.panel1.ResumeLayout(false);