diff --git a/ARCHBLOXLauncher1.csproj b/ARCHBLOXLauncherGUI.csproj similarity index 100% rename from ARCHBLOXLauncher1.csproj rename to ARCHBLOXLauncherGUI.csproj diff --git a/ARCHBLOXLauncher1.csproj.user b/ARCHBLOXLauncherGUI.csproj.user similarity index 85% rename from ARCHBLOXLauncher1.csproj.user rename to ARCHBLOXLauncherGUI.csproj.user index 7ac85d8..3494964 100644 --- a/ARCHBLOXLauncher1.csproj.user +++ b/ARCHBLOXLauncherGUI.csproj.user @@ -1,7 +1,7 @@  - <_LastSelectedProfileId>C:\Users\Thomas\source\repos\ARCHBLOXLauncher1\Properties\PublishProfiles\x86.pubxml + <_LastSelectedProfileId>C:\Users\Thomas\source\repos\ARCHBLOXLauncher1\Properties\PublishProfiles\x64.pubxml diff --git a/Form2.cs b/Form2.cs index e99222d..d19d4c1 100644 --- a/Form2.cs +++ b/Form2.cs @@ -19,6 +19,7 @@ namespace ARCHBLOXLauncher1 { public partial class Form2 : Form { + public bool Uri_Installed = false; public bool IsCompleted = false; public bool DontEvenBother = false; private static WebClient wc = new WebClient(); @@ -90,6 +91,7 @@ namespace ARCHBLOXLauncher1 { if (IsCompleted == false) { + IsCompleted = true; byte[] raw = wc.DownloadData("https://archblox.com/client/version.txt"); string webData = Encoding.UTF8.GetString(raw); @@ -99,8 +101,22 @@ namespace ARCHBLOXLauncher1 string filePath = Path.Combine(clientPath, Path.GetFileName(@"https://archblox.com/client/" + version_string + ".zip")); ZipFile.ExtractToDirectory(filePath, clientPath); File.Delete(filePath); - label1.Text = "Install completed!"; - ARCHBLOXProtocol.ARCHBLOXURIProtocol.Register(); + label1.Text = "Installing URi..."; + try + { + System.AppDomain.CurrentDomain.SetPrincipalPolicy(System.Security.Principal.PrincipalPolicy.WindowsPrincipal); + ARCHBLOXProtocol.ARCHBLOXURIProtocol.Register(); + Uri_Installed = true; + } + catch { Uri_Installed = false; } + if (Uri_Installed == true) + { + label1.Text = "ARCHBLOX has been installed!"; + } else + { + label1.Text = "ARCHBLOX has been installed without URI."; + } + } } diff --git a/Properties/PublishProfiles/x64.pubxml.user b/Properties/PublishProfiles/x64.pubxml.user index a596579..3c9a79d 100644 --- a/Properties/PublishProfiles/x64.pubxml.user +++ b/Properties/PublishProfiles/x64.pubxml.user @@ -4,6 +4,6 @@ https://go.microsoft.com/fwlink/?LinkID=208121. --> - True|2022-07-13T06:20:04.4747082Z;True|2022-07-13T00:37:48.5001758+10:00;True|2022-07-13T00:37:23.7218937+10:00;True|2022-07-13T00:35:56.1276705+10:00;True|2022-07-12T20:31:31.4891674+10:00;True|2022-07-12T07:42:57.8030421+10:00;True|2022-07-12T07:24:22.2110673+10:00;True|2022-07-12T07:12:22.1327523+10:00;True|2022-07-12T01:02:07.4142780+10:00;True|2022-07-12T01:01:55.1054218+10:00;True|2022-07-12T00:57:05.7704097+10:00;True|2022-07-11T19:45:06.3965836+10:00;True|2022-07-11T03:03:05.5235378+10:00;True|2022-07-11T01:29:52.2575986+10:00;True|2022-07-11T01:29:03.7081553+10:00;True|2022-07-11T01:07:30.8355486+10:00;True|2022-07-11T00:18:27.1107980+10:00;True|2022-07-10T21:59:11.0753271+10:00;True|2022-07-10T19:15:49.4105023+10:00;True|2022-07-10T19:13:41.3098116+10:00;True|2022-07-10T19:12:41.5715908+10:00; + True|2022-07-13T06:47:01.0681916Z;True|2022-07-13T16:28:49.6060671+10:00;False|2022-07-13T16:28:36.6234772+10:00;True|2022-07-13T16:27:25.2155759+10:00;True|2022-07-13T16:20:04.4747082+10:00;True|2022-07-13T00:37:48.5001758+10:00;True|2022-07-13T00:37:23.7218937+10:00;True|2022-07-13T00:35:56.1276705+10:00;True|2022-07-12T20:31:31.4891674+10:00;True|2022-07-12T07:42:57.8030421+10:00;True|2022-07-12T07:24:22.2110673+10:00;True|2022-07-12T07:12:22.1327523+10:00;True|2022-07-12T01:02:07.4142780+10:00;True|2022-07-12T01:01:55.1054218+10:00;True|2022-07-12T00:57:05.7704097+10:00;True|2022-07-11T19:45:06.3965836+10:00;True|2022-07-11T03:03:05.5235378+10:00;True|2022-07-11T01:29:52.2575986+10:00;True|2022-07-11T01:29:03.7081553+10:00;True|2022-07-11T01:07:30.8355486+10:00;True|2022-07-11T00:18:27.1107980+10:00;True|2022-07-10T21:59:11.0753271+10:00;True|2022-07-10T19:15:49.4105023+10:00;True|2022-07-10T19:13:41.3098116+10:00;True|2022-07-10T19:12:41.5715908+10:00; \ No newline at end of file diff --git a/Properties/Resources.Designer.cs b/Properties/Resources.Designer.cs index fa9477b..5e58009 100644 --- a/Properties/Resources.Designer.cs +++ b/Properties/Resources.Designer.cs @@ -8,7 +8,7 @@ // //------------------------------------------------------------------------------ -namespace ARCHBLOXLauncher1.Properties { +namespace ARCHBLOXLauncherGUI.Properties { using System; @@ -39,7 +39,7 @@ namespace ARCHBLOXLauncher1.Properties { internal static global::System.Resources.ResourceManager ResourceManager { get { if (object.ReferenceEquals(resourceMan, null)) { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ARCHBLOXLauncher1.Properties.Resources", typeof(Resources).Assembly); + global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ARCHBLOXLauncherGUI.Properties.Resources", typeof(Resources).Assembly); resourceMan = temp; } return resourceMan; diff --git a/URI_Maker.cs b/URI_Maker.cs index 674a3f4..241040d 100644 --- a/URI_Maker.cs +++ b/URI_Maker.cs @@ -9,7 +9,6 @@ namespace ARCHBLOXProtocol { public static string Arguments = ""; }; - [PrincipalPermission(SecurityAction.Demand, Role = @"BUILTIN\Administrators")] internal static class ARCHBLOXURIProtocol { private const string _Protocol = "archblox"; @@ -71,6 +70,9 @@ namespace ARCHBLOXProtocol internal static void Unregister() { + PrincipalPermission principalPerm = new PrincipalPermission(null, "Administrators"); + principalPerm.Demand(); + if (!_isWin8) { Registry.ClassesRoot.DeleteSubKeyTree("archblox", false); diff --git a/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll b/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll index 6bc5cf3..cc987f8 100644 Binary files a/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll and b/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll differ diff --git a/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb b/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb index 08c6317..c4e2db1 100644 Binary files a/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb and b/bin/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb differ diff --git a/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll b/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll index 53783d3..3fe3b63 100644 Binary files a/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll and b/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll differ diff --git a/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb b/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb index 78333d8..ffece09 100644 Binary files a/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb and b/bin/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb differ diff --git a/obj/ARCHBLOXLauncherGUI.csproj.nuget.dgspec.json b/obj/ARCHBLOXLauncherGUI.csproj.nuget.dgspec.json new file mode 100644 index 0000000..031a01a --- /dev/null +++ b/obj/ARCHBLOXLauncherGUI.csproj.nuget.dgspec.json @@ -0,0 +1,75 @@ +{ + "format": 1, + "restore": { + "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj": {} + }, + "projects": { + "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj", + "projectName": "ARCHBLOXLauncherGUI", + "projectPath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj", + "packagesPath": "C:\\Users\\Thomas\\.nuget\\packages\\", + "outputPath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\obj\\", + "projectStyle": "PackageReference", + "fallbackFolders": [ + "C:\\Program Files (x86)\\Microsoft Visual Studio\\Shared\\NuGetPackages" + ], + "configFilePaths": [ + "C:\\Users\\Thomas\\AppData\\Roaming\\NuGet\\NuGet.Config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.FallbackLocation.config", + "C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config" + ], + "originalTargetFrameworks": [ + "netcoreapp3.1" + ], + "sources": { + "C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "netcoreapp3.1": { + "targetAlias": "netcoreapp3.1", + "dependencies": { + "DiscordRichPresence": { + "target": "Package", + "version": "[1.0.175, )" + } + }, + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48" + ], + "assetTargetFallback": true, + "warn": true, + "frameworkReferences": { + "Microsoft.NETCore.App": { + "privateAssets": "all" + }, + "Microsoft.WindowsDesktop.App.WindowsForms": { + "privateAssets": "none" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.300\\RuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.props b/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.props new file mode 100644 index 0000000..cfc5f46 --- /dev/null +++ b/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.props @@ -0,0 +1,16 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\Thomas\.nuget\packages\;C:\Program Files (x86)\Microsoft Visual Studio\Shared\NuGetPackages + PackageReference + 6.2.0 + + + + + + \ No newline at end of file diff --git a/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.targets b/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.targets new file mode 100644 index 0000000..3dc06ef --- /dev/null +++ b/obj/ARCHBLOXLauncherGUI.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll b/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll index 6bc5cf3..cc987f8 100644 Binary files a/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll and b/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.dll differ diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb b/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb index 08c6317..c4e2db1 100644 Binary files a/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb and b/obj/Release/netcoreapp3.1/ARCHBLOXLauncher1.pdb differ diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfo.cs b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfo.cs new file mode 100644 index 0000000..8202580 --- /dev/null +++ b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfo.cs @@ -0,0 +1,23 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// Runtime Version:4.0.30319.42000 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("ARCHBLOXLauncherGUI")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Release")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] +[assembly: System.Reflection.AssemblyProductAttribute("ARCHBLOXLauncherGUI")] +[assembly: System.Reflection.AssemblyTitleAttribute("ARCHBLOXLauncherGUI")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfoInputs.cache b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfoInputs.cache new file mode 100644 index 0000000..f02b267 --- /dev/null +++ b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +6f9d16c093487edd1e5a5cc9891c502fd7bc9069 diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.GeneratedMSBuildEditorConfig.editorconfig b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 0000000..3f2c199 --- /dev/null +++ b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,9 @@ +is_global = true +build_property.ApplicationManifest = +build_property.StartupObject = +build_property.ApplicationDefaultFont = +build_property.ApplicationHighDpiMode = +build_property.ApplicationUseCompatibleTextRendering = +build_property.ApplicationVisualStyles = +build_property.RootNamespace = ARCHBLOXLauncherGUI +build_property.ProjectDir = C:\Users\Thomas\source\repos\ARCHBLOXLauncher1\ diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.assets.cache b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.assets.cache new file mode 100644 index 0000000..b2a1404 Binary files /dev/null and b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.assets.cache differ diff --git a/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.csproj.AssemblyReference.cache b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.csproj.AssemblyReference.cache new file mode 100644 index 0000000..3918ef7 Binary files /dev/null and b/obj/Release/netcoreapp3.1/ARCHBLOXLauncherGUI.csproj.AssemblyReference.cache differ diff --git a/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll b/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll index 53783d3..3fe3b63 100644 Binary files a/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll and b/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.dll differ diff --git a/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb b/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb index 78333d8..ffece09 100644 Binary files a/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb and b/obj/Release/netcoreapp3.1/win-x64/ARCHBLOXLauncher1.pdb differ diff --git a/obj/project.assets.json b/obj/project.assets.json index 65df7ba..cc62b3f 100644 --- a/obj/project.assets.json +++ b/obj/project.assets.json @@ -302,9 +302,9 @@ "project": { "version": "1.0.0", "restore": { - "projectUniqueName": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncher1.csproj", - "projectName": "ARCHBLOXLauncher1", - "projectPath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncher1.csproj", + "projectUniqueName": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj", + "projectName": "ARCHBLOXLauncherGUI", + "projectPath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj", "packagesPath": "C:\\Users\\Thomas\\.nuget\\packages\\", "outputPath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\obj\\", "projectStyle": "PackageReference", diff --git a/obj/project.nuget.cache b/obj/project.nuget.cache index 42f5d4e..f922473 100644 --- a/obj/project.nuget.cache +++ b/obj/project.nuget.cache @@ -1,8 +1,8 @@ { "version": 2, - "dgSpecHash": "O1Ougk3yJxkQvs7oFKP4pltYDmC6AJxUN35E+aySNJ5xke83iHDExIGYEN7JQhQohGrIrC2iBD/ywpywpk3b8w==", + "dgSpecHash": "t0oyQbfMoANTqGaJsmMte/09bCaDmn6IYWhmYKJw0YjKNI4GvwZxFHaOWvJfBWK7tMEA10t4oUMUOVR9KO9E7Q==", "success": true, - "projectFilePath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncher1.csproj", + "projectFilePath": "C:\\Users\\Thomas\\source\\repos\\ARCHBLOXLauncher1\\ARCHBLOXLauncherGUI.csproj", "expectedPackageFiles": [ "C:\\Users\\Thomas\\.nuget\\packages\\discordrichpresence\\1.0.175\\discordrichpresence.1.0.175.nupkg.sha512", "C:\\Users\\Thomas\\.nuget\\packages\\microsoft.netcore.platforms\\2.0.0\\microsoft.netcore.platforms.2.0.0.nupkg.sha512",