Skip to content

Commit

Permalink
Seed is now loaded from the save file directly instead of using the c…
Browse files Browse the repository at this point in the history
…ustom logic to track seed. Added a new About form to display license/thanks.
  • Loading branch information
Peter Corcoran committed Oct 10, 2019
1 parent 8bddc33 commit 6d329bb
Show file tree
Hide file tree
Showing 10 changed files with 1,807 additions and 23 deletions.
7 changes: 4 additions & 3 deletions Build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ function Build-NSM {
Clean-Up
Build-Solution "NoitaSaveManager.sln"
Delete-Xml-And-Pdb
Copy-License
Copy-License-And-Thanks
Create-Release-Installer
Create-Release-Zip

Expand Down Expand Up @@ -49,10 +49,11 @@ function Delete-Xml-And-Pdb
rm "NoitaSaveManager\bin\Release\*.pdb"
}

function Copy-License
function Copy-License-And-Thanks
{
Write-Host "Copying GPL license" -foregroundcolor green
Write-Host "Copying GPL license and thank you notes" -foregroundcolor green
Copy-Item -Path LICENSE -Destination "NoitaSaveManager\bin\Release"
Copy-Item -Path THANKS -Destination "NoitaSaveManager\bin\Release"
}

function Create-Release-Installer
Expand Down
123 changes: 123 additions & 0 deletions NoitaSaveManager/AboutForm.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

50 changes: 50 additions & 0 deletions NoitaSaveManager/AboutForm.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace NoitaSaveManager
{
public partial class AboutForm : Form
{
public AboutForm()
{
InitializeComponent();
}

private void AboutForm_Load(object sender, EventArgs e)
{
label1.Text = FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion;
label1.Text += " by R4wizard";

if(File.Exists("THANKS"))
textBox1.Text = File.ReadAllText("THANKS");

if (File.Exists("LICENSE"))
textBox2.Text = File.ReadAllText("LICENSE");
}

private void button1_Click(object sender, EventArgs e)
{
Close();
}

private void textBox1_Click(object sender, EventArgs e)
{
textBox1.SelectAll();
}

private void textBox2_Click(object sender, EventArgs e)
{
textBox2.SelectAll();
}
}
}
Loading

0 comments on commit 6d329bb

Please sign in to comment.