diff --git a/Directory.Build.props b/Directory.Build.props
new file mode 100644
index 0000000..e54c688
--- /dev/null
+++ b/Directory.Build.props
@@ -0,0 +1,19 @@
+
+
+ net9.0
+ enable
+ enable
+ latest
+ true
+
+
+ true
+ true
+
+
+ false
+
+
+ $(NoWarn);NU1507
+
+
diff --git a/Directory.Packages.props b/Directory.Packages.props
new file mode 100644
index 0000000..a087e29
--- /dev/null
+++ b/Directory.Packages.props
@@ -0,0 +1,16 @@
+
+
+ true
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/MeshUnpacker/MeshUnpacker.csproj b/MeshUnpacker/MeshUnpacker.csproj
index 2f4fc77..7420c8c 100644
--- a/MeshUnpacker/MeshUnpacker.csproj
+++ b/MeshUnpacker/MeshUnpacker.csproj
@@ -2,9 +2,6 @@
Exe
- net8.0
- enable
- enable
diff --git a/MissionDataUnpacker/MissionDataUnpacker.csproj b/MissionDataUnpacker/MissionDataUnpacker.csproj
index 2f4fc77..7420c8c 100644
--- a/MissionDataUnpacker/MissionDataUnpacker.csproj
+++ b/MissionDataUnpacker/MissionDataUnpacker.csproj
@@ -2,9 +2,6 @@
Exe
- net8.0
- enable
- enable
diff --git a/MissionTmaLib/MissionTmaLib.csproj b/MissionTmaLib/MissionTmaLib.csproj
index 3a63532..c632161 100644
--- a/MissionTmaLib/MissionTmaLib.csproj
+++ b/MissionTmaLib/MissionTmaLib.csproj
@@ -1,9 +1,3 @@
-
- net8.0
- enable
- enable
-
-
diff --git a/NLUnpacker/NLUnpacker.csproj b/NLUnpacker/NLUnpacker.csproj
index 1994ce8..23c3a54 100644
--- a/NLUnpacker/NLUnpacker.csproj
+++ b/NLUnpacker/NLUnpacker.csproj
@@ -1,11 +1,11 @@
-
+
Exe
- net8.0
- enable
- enable
- true
+
+
+
+
diff --git a/NLUnpacker/Program.cs b/NLUnpacker/Program.cs
index a1f6171..27bda12 100644
--- a/NLUnpacker/Program.cs
+++ b/NLUnpacker/Program.cs
@@ -1,7 +1,40 @@
-using System.Buffers.Binary;
+using System.Buffers.Binary;
+using System.Text;
-var fileBytes = File.ReadAllBytes("C:\\Program Files (x86)\\Nikita\\Iron Strategy\\gamefont.rlb");
+var fileBytes = File.ReadAllBytes("C:\\Program Files (x86)\\Nikita\\Iron Strategy\\gamefont-1.rlb");
+var header = fileBytes.AsSpan().Slice(0, 32);
+
+var nlHeaderBytes = header.Slice(0, 2);
+var mustBeZero = header[2];
+var mustBeOne = header[3];
+var numberOfEntriesBytes = header.Slice(4, 2);
+var sortingFlagBytes = header.Slice(14, 2);
+var decryptionKeyBytes = header.Slice(20, 2);
+
+var numberOfEntries = BinaryPrimitives.ReadInt16LittleEndian(numberOfEntriesBytes);
+var sortingFlag = BinaryPrimitives.ReadInt16LittleEndian(sortingFlagBytes);
+var decryptionKey = BinaryPrimitives.ReadInt16LittleEndian(decryptionKeyBytes);
+
+var headerSize = numberOfEntries * 32;
+
+var decryptedHeader = new byte[headerSize];
+
+var keyLow = decryptionKeyBytes[0];
+var keyHigh = decryptionKeyBytes[1];
+for (var i = 0; i < headerSize; i++)
+{
+ byte tmp = (byte)((keyLow << 1) ^ keyHigh);
+ keyLow = tmp;
+ keyHigh = (byte)((keyHigh >> 1) ^ tmp);
+ decryptedHeader[i] = (byte)(fileBytes[32 + i] ^ tmp);
+}
+
+var decryptedHeaderString = Encoding.ASCII.GetString(decryptedHeader, 0, headerSize);
+var entries = decryptedHeader.Chunk(32).ToArray();
+var entriesStrings = entries.Select(x => Encoding.ASCII.GetString(x, 0, x.Length)).ToArray();
+
+File.WriteAllBytes("export.nl", decryptedHeader);
var fileCount = BinaryPrimitives.ReadInt16LittleEndian(fileBytes.AsSpan().Slice(4, 2));
var decodedHeader = new byte[fileCount * 32];
diff --git a/NResLib/NResLib.csproj b/NResLib/NResLib.csproj
index 3a63532..c632161 100644
--- a/NResLib/NResLib.csproj
+++ b/NResLib/NResLib.csproj
@@ -1,9 +1,3 @@
-
- net8.0
- enable
- enable
-
-
diff --git a/NResUI/NResUI.csproj b/NResUI/NResUI.csproj
index 17ac16d..e3f4a27 100644
--- a/NResUI/NResUI.csproj
+++ b/NResUI/NResUI.csproj
@@ -2,9 +2,6 @@
Exe
- net8.0
- enable
- enable
@@ -12,10 +9,10 @@
-
-
-
-
+
+
+
+
diff --git a/ParkanPlayground.sln b/ParkanPlayground.sln
deleted file mode 100644
index c437615..0000000
--- a/ParkanPlayground.sln
+++ /dev/null
@@ -1,86 +0,0 @@
-Microsoft Visual Studio Solution File, Format Version 12.00
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ParkanPlayground", "ParkanPlayground\ParkanPlayground.csproj", "{7DB19000-6F41-4BAE-A904-D34EFCA065E9}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TextureDecoder", "TextureDecoder\TextureDecoder.csproj", "{15D1C9ED-1080-417D-A4D1-CFF80BE6A218}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NLUnpacker", "NLUnpacker\NLUnpacker.csproj", "{50C83E6C-23ED-4A8E-B948-89686A742CF0}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NResUI", "NResUI\NResUI.csproj", "{7456A089-0701-416C-8668-1F740BF4B72C}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NResLib", "NResLib\NResLib.csproj", "{9429AEAE-80A6-4EE7-AB66-9161CC4C3A3D}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MeshUnpacker", "MeshUnpacker\MeshUnpacker.csproj", "{F1465FFE-0D66-4A3C-90D7-153A14E226E6}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TexmLib", "TexmLib\TexmLib.csproj", "{40097CB1-B4B8-4D3E-A874-7D46F5C81DB3}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MissionDataUnpacker", "MissionDataUnpacker\MissionDataUnpacker.csproj", "{7BF5C860-9194-4AF2-B5DA-216F98B03DBE}"
-EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "meta", "meta", "{BAF212FE-A0FD-41A2-A1A9-B406FDDFBAF3}"
- ProjectSection(SolutionItems) = preProject
- README.md = README.md
- EndProjectSection
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MissionTmaLib", "MissionTmaLib\MissionTmaLib.csproj", "{773D8EEA-6005-4127-9CB4-5F9F1A028B5D}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ScrLib", "ScrLib\ScrLib.csproj", "{C445359B-97D4-4432-9331-708B5A14887A}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VarsetLib", "VarsetLib\VarsetLib.csproj", "{0EC800E2-1444-40D5-9EDD-93276F4D1FF5}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Visualisator", "Visualisator\Visualisator.csproj", "{667A7E03-5CAA-4591-9980-F6C722911A35}"
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|Any CPU = Debug|Any CPU
- Release|Any CPU = Release|Any CPU
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {7DB19000-6F41-4BAE-A904-D34EFCA065E9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {7DB19000-6F41-4BAE-A904-D34EFCA065E9}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {7DB19000-6F41-4BAE-A904-D34EFCA065E9}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {7DB19000-6F41-4BAE-A904-D34EFCA065E9}.Release|Any CPU.Build.0 = Release|Any CPU
- {15D1C9ED-1080-417D-A4D1-CFF80BE6A218}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {15D1C9ED-1080-417D-A4D1-CFF80BE6A218}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {15D1C9ED-1080-417D-A4D1-CFF80BE6A218}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {15D1C9ED-1080-417D-A4D1-CFF80BE6A218}.Release|Any CPU.Build.0 = Release|Any CPU
- {50C83E6C-23ED-4A8E-B948-89686A742CF0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {50C83E6C-23ED-4A8E-B948-89686A742CF0}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {50C83E6C-23ED-4A8E-B948-89686A742CF0}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {50C83E6C-23ED-4A8E-B948-89686A742CF0}.Release|Any CPU.Build.0 = Release|Any CPU
- {7456A089-0701-416C-8668-1F740BF4B72C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {7456A089-0701-416C-8668-1F740BF4B72C}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {7456A089-0701-416C-8668-1F740BF4B72C}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {7456A089-0701-416C-8668-1F740BF4B72C}.Release|Any CPU.Build.0 = Release|Any CPU
- {9429AEAE-80A6-4EE7-AB66-9161CC4C3A3D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {9429AEAE-80A6-4EE7-AB66-9161CC4C3A3D}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {9429AEAE-80A6-4EE7-AB66-9161CC4C3A3D}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {9429AEAE-80A6-4EE7-AB66-9161CC4C3A3D}.Release|Any CPU.Build.0 = Release|Any CPU
- {F1465FFE-0D66-4A3C-90D7-153A14E226E6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {F1465FFE-0D66-4A3C-90D7-153A14E226E6}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {F1465FFE-0D66-4A3C-90D7-153A14E226E6}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {F1465FFE-0D66-4A3C-90D7-153A14E226E6}.Release|Any CPU.Build.0 = Release|Any CPU
- {40097CB1-B4B8-4D3E-A874-7D46F5C81DB3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {40097CB1-B4B8-4D3E-A874-7D46F5C81DB3}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {40097CB1-B4B8-4D3E-A874-7D46F5C81DB3}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {40097CB1-B4B8-4D3E-A874-7D46F5C81DB3}.Release|Any CPU.Build.0 = Release|Any CPU
- {7BF5C860-9194-4AF2-B5DA-216F98B03DBE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {7BF5C860-9194-4AF2-B5DA-216F98B03DBE}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {7BF5C860-9194-4AF2-B5DA-216F98B03DBE}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {7BF5C860-9194-4AF2-B5DA-216F98B03DBE}.Release|Any CPU.Build.0 = Release|Any CPU
- {773D8EEA-6005-4127-9CB4-5F9F1A028B5D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {773D8EEA-6005-4127-9CB4-5F9F1A028B5D}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {773D8EEA-6005-4127-9CB4-5F9F1A028B5D}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {773D8EEA-6005-4127-9CB4-5F9F1A028B5D}.Release|Any CPU.Build.0 = Release|Any CPU
- {C445359B-97D4-4432-9331-708B5A14887A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {C445359B-97D4-4432-9331-708B5A14887A}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {C445359B-97D4-4432-9331-708B5A14887A}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {C445359B-97D4-4432-9331-708B5A14887A}.Release|Any CPU.Build.0 = Release|Any CPU
- {0EC800E2-1444-40D5-9EDD-93276F4D1FF5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {0EC800E2-1444-40D5-9EDD-93276F4D1FF5}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {0EC800E2-1444-40D5-9EDD-93276F4D1FF5}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {0EC800E2-1444-40D5-9EDD-93276F4D1FF5}.Release|Any CPU.Build.0 = Release|Any CPU
- {667A7E03-5CAA-4591-9980-F6C722911A35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {667A7E03-5CAA-4591-9980-F6C722911A35}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {667A7E03-5CAA-4591-9980-F6C722911A35}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {667A7E03-5CAA-4591-9980-F6C722911A35}.Release|Any CPU.Build.0 = Release|Any CPU
- EndGlobalSection
-EndGlobal
diff --git a/ParkanPlayground.sln.DotSettings.user b/ParkanPlayground.sln.DotSettings.user
deleted file mode 100644
index 780c784..0000000
--- a/ParkanPlayground.sln.DotSettings.user
+++ /dev/null
@@ -1,11 +0,0 @@
-
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
- ForceIncluded
\ No newline at end of file
diff --git a/ParkanPlayground.slnx b/ParkanPlayground.slnx
new file mode 100644
index 0000000..15f65a3
--- /dev/null
+++ b/ParkanPlayground.slnx
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ParkanPlayground/ParkanPlayground.csproj b/ParkanPlayground/ParkanPlayground.csproj
index 527979a..ee8a5ae 100644
--- a/ParkanPlayground/ParkanPlayground.csproj
+++ b/ParkanPlayground/ParkanPlayground.csproj
@@ -2,9 +2,6 @@
Exe
- net8.0
- enable
- enable
@@ -13,8 +10,4 @@
-
-
-
-
diff --git a/ParkanPlayground/Program.cs b/ParkanPlayground/Program.cs
index 367ee58..719f55f 100644
--- a/ParkanPlayground/Program.cs
+++ b/ParkanPlayground/Program.cs
@@ -2,7 +2,6 @@
using System.Numerics;
using System.Text.Json;
using ScrLib;
-using SharpDisasm;
using VarsetLib;
diff --git a/ScrLib/ScrLib.csproj b/ScrLib/ScrLib.csproj
index 3a63532..c632161 100644
--- a/ScrLib/ScrLib.csproj
+++ b/ScrLib/ScrLib.csproj
@@ -1,9 +1,3 @@
-
- net8.0
- enable
- enable
-
-
diff --git a/TexmLib/TexmLib.csproj b/TexmLib/TexmLib.csproj
index a1fcf00..3133310 100644
--- a/TexmLib/TexmLib.csproj
+++ b/TexmLib/TexmLib.csproj
@@ -1,13 +1,7 @@
-
- net8.0
- enable
- enable
-
-
-
+
diff --git a/TextureDecoder/TextureDecoder.csproj b/TextureDecoder/TextureDecoder.csproj
index 50c9527..57fe6d0 100644
--- a/TextureDecoder/TextureDecoder.csproj
+++ b/TextureDecoder/TextureDecoder.csproj
@@ -2,17 +2,10 @@
Exe
- net8.0
- enable
- enable
-
-
-
-
-
+
diff --git a/VarsetLib/VarsetLib.csproj b/VarsetLib/VarsetLib.csproj
index 3a63532..c632161 100644
--- a/VarsetLib/VarsetLib.csproj
+++ b/VarsetLib/VarsetLib.csproj
@@ -1,9 +1,3 @@
-
- net8.0
- enable
- enable
-
-
diff --git a/Visualisator/Visualisator.csproj b/Visualisator/Visualisator.csproj
index b9b125f..17afd97 100644
--- a/Visualisator/Visualisator.csproj
+++ b/Visualisator/Visualisator.csproj
@@ -2,17 +2,14 @@
Exe
- net8.0
- enable
- enable
true
-
-
-
-
+
+
+
+