├── .gitattributes ├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ └── feature_request.md └── workflows │ ├── codeql-analysis.yml │ └── dotnet-desktop.yml ├── .gitignore ├── .vscode ├── launch.json ├── settings.json └── tasks.json ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── Languages ├── frenchREADME.md └── spanishREADME.md ├── README.md ├── archive └── .gitignore ├── cli ├── makefile ├── out │ └── HyperMc-cli-1-0-0.o └── src │ ├── hmc.c │ ├── includer.h │ └── userSettings.c ├── docs ├── howToInstall.md └── howToUse.md ├── installer.nsi ├── license.txt ├── renovate.json └── src └── HyperMC ├── Api └── fetchMod.cs ├── Data ├── ModpackData.cs └── VersionData.cs ├── HyperMC.csproj ├── HyperMcView.Designer.cs ├── HyperMcView.cs ├── HyperMcView.resx ├── Mod.cs ├── ModDownloadEventArgs.cs ├── Program.cs ├── Properties ├── Resources.Designer.cs └── Resources.resx ├── Resources ├── DefaultModpackImage.png ├── HyperMc32x32.png ├── logo.png └── testImg.jpg ├── Services ├── FileDataAccess.cs └── IDataAccess.cs ├── Settings ├── ApplicationSettings.cs ├── IUserSettings.cs └── UserSettings.cs ├── UI ├── Components │ ├── DraggablePanel.cs │ └── HoverButton.cs ├── Dialogs │ ├── CreateModpackDialog.Designer.cs │ ├── CreateModpackDialog.cs │ └── CreateModpackDialog.resx ├── UserControls │ ├── ModpackBox.Designer.cs │ ├── ModpackBox.cs │ └── ModpackBox.resx └── Views │ ├── ControlView.cs │ ├── IView.cs │ ├── IViewHost.cs │ ├── SettingView.Designer.cs │ ├── SettingView.cs │ └── SettingView.resx ├── Utility ├── MessageDialog.cs └── Utils.cs ├── appsettings.json └── lib ├── Main.cs └── notifications └── SendNotification.cs /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Describe the bug** 11 | A clear and concise description of what the bug is. 12 | 13 | **To Reproduce** 14 | Steps to reproduce the behavior: 15 | 1. Go to '...' 16 | 2. Click on '....' 17 | 3. Scroll down to '....' 18 | 4. See error 19 | 20 | **Expected behavior** 21 | A clear and concise description of what you expected to happen. 22 | 23 | **Screenshots** 24 | If applicable, add screenshots to help explain your problem. 25 | 26 | **Desktop (please complete the following information):** 27 | - OS: [e.g. iOS] 28 | - Browser [e.g. chrome, safari] 29 | - Version [e.g. 22] 30 | 31 | **Smartphone (please complete the following information):** 32 | - Device: [e.g. iPhone6] 33 | - OS: [e.g. iOS8.1] 34 | - Browser [e.g. stock browser, safari] 35 | - Version [e.g. 22] 36 | 37 | **Additional context** 38 | Add any other context about the problem here. 39 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Is your feature request related to a problem? Please describe.** 11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 12 | 13 | **Describe the solution you'd like** 14 | A clear and concise description of what you want to happen. 15 | 16 | **Describe alternatives you've considered** 17 | A clear and concise description of any alternative solutions or features you've considered. 18 | 19 | **Additional context** 20 | Add any other context or screenshots about the feature request here. 21 | -------------------------------------------------------------------------------- /.github/workflows/codeql-analysis.yml: -------------------------------------------------------------------------------- 1 | # For most projects, this workflow file will not need changing; you simply need 2 | # to commit it to your repository. 3 | # 4 | # You may wish to alter this file to override the set of languages analyzed, 5 | # or to provide custom queries or build logic. 6 | # 7 | # ******** NOTE ******** 8 | # We have attempted to detect the languages in your repository. Please check 9 | # the `language` matrix defined below to confirm you have the correct set of 10 | # supported CodeQL languages. 11 | # 12 | name: "CodeQL" 13 | 14 | on: 15 | push: 16 | branches: [ Windows ] 17 | pull_request: 18 | # The branches below must be a subset of the branches above 19 | branches: [ Windows ] 20 | schedule: 21 | - cron: '39 15 * * 3' 22 | 23 | jobs: 24 | analyze: 25 | name: Analyze 26 | runs-on: ubuntu-latest 27 | permissions: 28 | actions: read 29 | contents: read 30 | security-events: write 31 | 32 | strategy: 33 | fail-fast: false 34 | matrix: 35 | language: [ 'csharp' ] 36 | # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ] 37 | # Learn more: 38 | # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed 39 | 40 | steps: 41 | - name: Checkout repository 42 | uses: actions/checkout@v2 43 | 44 | # Initializes the CodeQL tools for scanning. 45 | - name: Initialize CodeQL 46 | uses: github/codeql-action/init@v1 47 | with: 48 | languages: ${{ matrix.language }} 49 | # If you wish to specify custom queries, you can do so here or in a config file. 50 | # By default, queries listed here will override any specified in a config file. 51 | # Prefix the list here with "+" to use these queries and those in the config file. 52 | # queries: ./path/to/local/query, your-org/your-repo/queries@main 53 | 54 | # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). 55 | # If this step fails, then you should remove it and run the build manually (see below) 56 | - name: Autobuild 57 | uses: github/codeql-action/autobuild@v1 58 | 59 | # ℹ️ Command-line programs to run using the OS shell. 60 | # 📚 https://git.io/JvXDl 61 | 62 | # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines 63 | # and modify them (or add more) to build your code if your project 64 | # uses a compiled language 65 | 66 | #- run: | 67 | # make bootstrap 68 | # make release 69 | 70 | - name: Perform CodeQL Analysis 71 | uses: github/codeql-action/analyze@v1 72 | -------------------------------------------------------------------------------- /.github/workflows/dotnet-desktop.yml: -------------------------------------------------------------------------------- 1 | # This workflow uses actions that are not certified by GitHub. 2 | # They are provided by a third-party and are governed by 3 | # separate terms of service, privacy policy, and support 4 | # documentation. 5 | 6 | # This workflow will build, test, sign and package a WPF or Windows Forms desktop application 7 | # built on .NET Core. 8 | # To learn how to migrate your existing application to .NET Core, 9 | # refer to https://docs.microsoft.com/en-us/dotnet/desktop-wpf/migration/convert-project-from-net-framework 10 | # 11 | # To configure this workflow: 12 | # 13 | # 1. Configure environment variables 14 | # GitHub sets default environment variables for every workflow run. 15 | # Replace the variables relative to your project in the "env" section below. 16 | # 17 | # 2. Signing 18 | # Generate a signing certificate in the Windows Application 19 | # Packaging Project or add an existing signing certificate to the project. 20 | # Next, use PowerShell to encode the .pfx file using Base64 encoding 21 | # by running the following Powershell script to generate the output string: 22 | # 23 | # $pfx_cert = Get-Content '.\SigningCertificate.pfx' -Encoding Byte 24 | # [System.Convert]::ToBase64String($pfx_cert) | Out-File 'SigningCertificate_Encoded.txt' 25 | # 26 | # Open the output file, SigningCertificate_Encoded.txt, and copy the 27 | # string inside. Then, add the string to the repo as a GitHub secret 28 | # and name it "Base64_Encoded_Pfx." 29 | # For more information on how to configure your signing certificate for 30 | # this workflow, refer to https://github.com/microsoft/github-actions-for-desktop-apps#signing 31 | # 32 | # Finally, add the signing certificate password to the repo as a secret and name it "Pfx_Key". 33 | # See "Build the Windows Application Packaging project" below to see how the secret is used. 34 | # 35 | # For more information on GitHub Actions, refer to https://github.com/features/actions 36 | # For a complete CI/CD sample to get started with GitHub Action workflows for Desktop Applications, 37 | # refer to https://github.com/microsoft/github-actions-for-desktop-apps 38 | 39 | name: .NET Core Desktop 40 | 41 | on: 42 | push: 43 | branches: [ Windows ] 44 | pull_request: 45 | branches: [ Windows ] 46 | 47 | jobs: 48 | 49 | build: 50 | 51 | strategy: 52 | matrix: 53 | configuration: [Debug, Release] 54 | 55 | runs-on: windows-latest # For a list of available runner types, refer to 56 | # https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idruns-on 57 | 58 | env: 59 | Solution_Name: your-solution-name # Replace with your solution name, i.e. MyWpfApp.sln. 60 | Test_Project_Path: your-test-project-path # Replace with the path to your test project, i.e. MyWpfApp.Tests\MyWpfApp.Tests.csproj. 61 | Wap_Project_Directory: your-wap-project-directory-name # Replace with the Wap project directory relative to the solution, i.e. MyWpfApp.Package. 62 | Wap_Project_Path: your-wap-project-path # Replace with the path to your Wap project, i.e. MyWpf.App.Package\MyWpfApp.Package.wapproj. 63 | 64 | steps: 65 | - name: Checkout 66 | uses: actions/checkout@v2 67 | with: 68 | fetch-depth: 0 69 | 70 | # Install the .NET Core workload 71 | - name: Install .NET Core 72 | uses: actions/setup-dotnet@v1 73 | with: 74 | dotnet-version: 5.0.x 75 | 76 | # Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild 77 | - name: Setup MSBuild.exe 78 | uses: microsoft/setup-msbuild@v1.0.3 79 | 80 | # Execute all unit tests in the solution 81 | - name: Execute unit tests 82 | run: dotnet test 83 | 84 | # Restore the application to populate the obj folder with RuntimeIdentifiers 85 | - name: Restore the application 86 | run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration 87 | env: 88 | Configuration: ${{ matrix.configuration }} 89 | 90 | # Decode the base 64 encoded pfx and save the Signing_Certificate 91 | - name: Decode the pfx 92 | run: | 93 | $pfx_cert_byte = [System.Convert]::FromBase64String("${{ secrets.Base64_Encoded_Pfx }}") 94 | $certificatePath = Join-Path -Path $env:Wap_Project_Directory -ChildPath GitHubActionsWorkflow.pfx 95 | [IO.File]::WriteAllBytes("$certificatePath", $pfx_cert_byte) 96 | 97 | # Create the app package by building and packaging the Windows Application Packaging project 98 | - name: Create the app package 99 | run: msbuild $env:Wap_Project_Path /p:Configuration=$env:Configuration /p:UapAppxPackageBuildMode=$env:Appx_Package_Build_Mode /p:AppxBundle=$env:Appx_Bundle /p:PackageCertificateKeyFile=GitHubActionsWorkflow.pfx /p:PackageCertificatePassword=${{ secrets.Pfx_Key }} 100 | env: 101 | Appx_Bundle: Always 102 | Appx_Bundle_Platforms: x86|x64 103 | Appx_Package_Build_Mode: StoreUpload 104 | Configuration: ${{ matrix.configuration }} 105 | 106 | # Remove the pfx 107 | - name: Remove the pfx 108 | run: Remove-Item -path $env:Wap_Project_Directory\$env:Signing_Certificate 109 | 110 | # Upload the MSIX package: https://github.com/marketplace/actions/upload-artifact 111 | - name: Upload build artifacts 112 | uses: actions/upload-artifact@v2 113 | with: 114 | name: MSIX Package 115 | path: ${{ env.Wap_Project_Directory }}\AppPackages 116 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | *.exe 3 | *.pdb 4 | *.dll 5 | /.metals 6 | bin/ 7 | obj/ 8 | *.cache 9 | /Hypermc/mod-pack/ 10 | /mods 11 | /Hypermc_TemporaryKey.pfx 12 | /Hypermc.csproj.user 13 | /Hypermc.pdb 14 | /Hypermc.exe.config 15 | Hypermc.sln 16 | source/mod-pack/ 17 | .vs/Hypermc/v16/.suo 18 | source/Hypermc.csproj.user 19 | source/obj/Debug/net5.0-windows/Hypermc.csproj.FileListAbsolute.txt 20 | .vs/Hypermc/DesignTimeBuild/.dtbcache.v2 21 | source/Hypermc.csproj.user 22 | 23 | # Ignore NuGet Packages 24 | *.nupkg 25 | 26 | # The packages folder can be ignored because of Package Restore 27 | **/[Pp]ackages/* 28 | 29 | # except build/, which is used as an MSBuild target. 30 | !**/[Pp]ackages/build/ 31 | 32 | # NuGet v3's project.json files produces more ignorable files 33 | *.nuget.props 34 | *.nuget.targets 35 | 36 | # Ignore other intermediate files that NuGet might create. project.lock.json is used in conjunction 37 | # with project.json (NuGet v3); project.assets.json is used in conjunction with the PackageReference 38 | # format (NuGet v4 and .NET Core). 39 | project.lock.json 40 | project.assets.json 41 | 42 | # Ignore Visual Studio temporary files, build results, and 43 | # files generated by popular Visual Studio add-ons. 44 | # 45 | # Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 46 | User-specific files 47 | *.rsuser 48 | *.suo 49 | *.user 50 | *.userosscache 51 | *.sln.docstates 52 | 53 | # User-specific files (MonoDevelop/Xamarin Studio) 54 | *.userprefs 55 | 56 | # Mono auto generated files 57 | mono_crash.* 58 | 59 | # Build results 60 | [Dd]ebug/ 61 | [Dd]ebugPublic/ 62 | [Rr]elease/ 63 | [Rr]eleases/ 64 | x64/ 65 | x86/ 66 | [Aa][Rr][Mm]/ 67 | [Aa][Rr][Mm]64/ 68 | bld/ 69 | [Bb]in/ 70 | [Oo]bj/ 71 | [Ll]og/ 72 | [Ll]ogs/ 73 | 74 | # Visual Studio 2015/2017 cache/options directory 75 | .vs/ 76 | # Uncomment if you have tasks that create the project's static files in wwwroot 77 | #wwwroot/ 78 | 79 | # Visual Studio 2017 auto generated files 80 | Generated\ Files/ 81 | 82 | # MSTest test Results 83 | [Tt]est[Rr]esult*/ 84 | [Bb]uild[Ll]og.* 85 | 86 | # NUnit 87 | *.VisualState.xml 88 | TestResult.xml 89 | nunit-*.xml 90 | 91 | # Build Results of an ATL Project 92 | [Dd]ebugPS/ 93 | [Rr]eleasePS/ 94 | dlldata.c 95 | 96 | # Benchmark Results 97 | BenchmarkDotNet.Artifacts/ 98 | 99 | # .NET Core 100 | project.lock.json 101 | project.fragment.lock.json 102 | artifacts/ 103 | 104 | # StyleCop 105 | StyleCopReport.xml 106 | 107 | # Files built by Visual Studio 108 | *_i.c 109 | *_p.c 110 | *_h.h 111 | *.ilk 112 | *.meta 113 | *.obj 114 | *.iobj 115 | *.pch 116 | *.pdb 117 | *.ipdb 118 | *.pgc 119 | *.pgd 120 | *.rsp 121 | *.sbr 122 | *.tlb 123 | *.tli 124 | *.tlh 125 | *.tmp 126 | *.tmp_proj 127 | *_wpftmp.csproj 128 | *.log 129 | *.vspscc 130 | *.vssscc 131 | .builds 132 | *.pidb 133 | *.svclog 134 | *.scc 135 | 136 | # Chutzpah Test files 137 | _Chutzpah* 138 | 139 | # Visual C++ cache files 140 | ipch/ 141 | *.aps 142 | *.ncb 143 | *.opendb 144 | *.opensdf 145 | *.sdf 146 | *.cachefile 147 | *.VC.db 148 | *.VC.VC.opendb 149 | 150 | # Visual Studio profiler 151 | *.psess 152 | *.vsp 153 | *.vspx 154 | *.sap 155 | 156 | # Visual Studio Trace Files 157 | *.e2e 158 | 159 | # TFS 2012 Local Workspace 160 | $tf/ 161 | 162 | # Guidance Automation Toolkit 163 | *.gpState 164 | 165 | # ReSharper is a .NET coding add-in 166 | _ReSharper*/ 167 | *.[Rr]e[Ss]harper 168 | *.DotSettings.user 169 | 170 | # TeamCity is a build add-in 171 | _TeamCity* 172 | 173 | # DotCover is a Code Coverage Tool 174 | *.dotCover 175 | 176 | # AxoCover is a Code Coverage Tool 177 | .axoCover/* 178 | !.axoCover/settings.json 179 | 180 | # Visual Studio code coverage results 181 | *.coverage 182 | *.coveragexml 183 | 184 | # NCrunch 185 | _NCrunch_* 186 | .*crunch*.local.xml 187 | nCrunchTemp_* 188 | 189 | # MightyMoose 190 | *.mm.* 191 | AutoTest.Net/ 192 | 193 | # Web workbench (sass) 194 | .sass-cache/ 195 | 196 | # Installshield output folder 197 | [Ee]xpress/ 198 | 199 | # DocProject is a documentation generator add-in 200 | DocProject/buildhelp/ 201 | DocProject/Help/*.HxT 202 | DocProject/Help/*.HxC 203 | DocProject/Help/*.hhc 204 | DocProject/Help/*.hhk 205 | DocProject/Help/*.hhp 206 | DocProject/Help/Html2 207 | DocProject/Help/html 208 | 209 | # Click-Once directory 210 | publish/ 211 | 212 | # Publish Web Output 213 | *.[Pp]ublish.xml 214 | *.azurePubxml 215 | # Note: Comment the next line if you want to checkin your web deploy settings, 216 | # but database connection strings (with potential passwords) will be unencrypted 217 | *.pubxml 218 | *.publishproj 219 | 220 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 221 | # checkin your Azure Web App publish settings, but sensitive information contained 222 | # in these scripts will be unencrypted 223 | PublishScripts/ 224 | 225 | # NuGet Packages 226 | *.nupkg 227 | # NuGet Symbol Packages 228 | *.snupkg 229 | # The packages folder can be ignored because of Package Restore 230 | **/[Pp]ackages/* 231 | # except build/, which is used as an MSBuild target. 232 | !**/[Pp]ackages/build/ 233 | # Uncomment if necessary however generally it will be regenerated when needed 234 | #!**/[Pp]ackages/repositories.config 235 | # NuGet v3's project.json files produces more ignorable files 236 | *.nuget.props 237 | *.nuget.targets 238 | 239 | # Microsoft Azure Build Output 240 | csx/ 241 | *.build.csdef 242 | 243 | # Microsoft Azure Emulator 244 | ecf/ 245 | rcf/ 246 | 247 | # Windows Store app package directories and files 248 | AppPackages/ 249 | BundleArtifacts/ 250 | Package.StoreAssociation.xml 251 | _pkginfo.txt 252 | *.appx 253 | *.appxbundle 254 | *.appxupload 255 | 256 | # Visual Studio cache files 257 | # files ending in .cache can be ignored 258 | *.[Cc]ache 259 | # but keep track of directories ending in .cache 260 | !?*.[Cc]ache/ 261 | 262 | # Others 263 | ClientBin/ 264 | ~$* 265 | *~ 266 | *.dbmdl 267 | *.dbproj.schemaview 268 | *.jfm 269 | *.pfx 270 | *.publishsettings 271 | orleans.codegen.cs 272 | 273 | # Including strong name files can present a security risk 274 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 275 | #*.snk 276 | 277 | # Since there are multiple workflows, uncomment next line to ignore bower_components 278 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 279 | #bower_components/ 280 | 281 | # RIA/Silverlight projects 282 | Generated_Code/ 283 | 284 | # Backup & report files from converting an old project file 285 | # to a newer Visual Studio version. Backup files are not needed, 286 | # because we have git ;-) 287 | _UpgradeReport_Files/ 288 | Backup*/ 289 | UpgradeLog*.XML 290 | UpgradeLog*.htm 291 | ServiceFabricBackup/ 292 | *.rptproj.bak 293 | 294 | # SQL Server files 295 | *.mdf 296 | *.ldf 297 | *.ndf 298 | 299 | # Business Intelligence projects 300 | *.rdl.data 301 | *.bim.layout 302 | *.bim_*.settings 303 | *.rptproj.rsuser 304 | *- [Bb]ackup.rdl 305 | *- [Bb]ackup ([0-9]).rdl 306 | *- [Bb]ackup ([0-9][0-9]).rdl 307 | 308 | # Microsoft Fakes 309 | FakesAssemblies/ 310 | 311 | # GhostDoc plugin setting file 312 | *.GhostDoc.xml 313 | 314 | # Node.js Tools for Visual Studio 315 | .ntvs_analysis.dat 316 | node_modules/ 317 | 318 | # Visual Studio 6 build log 319 | *.plg 320 | 321 | # Visual Studio 6 workspace options file 322 | *.opt 323 | 324 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 325 | *.vbw 326 | 327 | # Visual Studio LightSwitch build output 328 | **/*.HTMLClient/GeneratedArtifacts 329 | **/*.DesktopClient/GeneratedArtifacts 330 | **/*.DesktopClient/ModelManifest.xml 331 | **/*.Server/GeneratedArtifacts 332 | **/*.Server/ModelManifest.xml 333 | _Pvt_Extensions 334 | 335 | # Paket dependency manager 336 | .paket/paket.exe 337 | paket-files/ 338 | 339 | # FAKE - F# Make 340 | .fake/ 341 | 342 | # CodeRush personal settings 343 | .cr/personal 344 | 345 | # Python Tools for Visual Studio (PTVS) 346 | __pycache__/ 347 | *.pyc 348 | 349 | # Cake - Uncomment if you are using it 350 | # tools/** 351 | # !tools/packages.config 352 | 353 | # Tabs Studio 354 | *.tss 355 | 356 | # Telerik's JustMock configuration file 357 | *.jmconfig 358 | 359 | # BizTalk build output 360 | *.btp.cs 361 | *.btm.cs 362 | *.odx.cs 363 | *.xsd.cs 364 | 365 | # OpenCover UI analysis results 366 | OpenCover/ 367 | 368 | # Azure Stream Analytics local run output 369 | ASALocalRun/ 370 | 371 | # MSBuild Binary and Structured Log 372 | *.binlog 373 | 374 | # NVidia Nsight GPU debugger configuration file 375 | *.nvuser 376 | 377 | # MFractors (Xamarin productivity tool) working folder 378 | .mfractor/ 379 | 380 | # Local History for Visual Studio 381 | .localhistory/ 382 | 383 | # BeatPulse healthcheck temp database 384 | healthchecksdb 385 | 386 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 387 | MigrationBackup/ 388 | 389 | # Ionide (cross platform F# VS Code tools) working folder 390 | .ionide/ 391 | 392 | # REMOVE PRIVATE USAGE API WRAPPER 393 | src/HyperMC.CurseForge -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.2.0", 3 | "configurations": [ 4 | { 5 | // Use IntelliSense to find out which attributes exist for C# debugging 6 | // Use hover for the description of the existing attributes 7 | // For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md 8 | "name": ".NET Core Launch (console)", 9 | "type": "coreclr", 10 | "request": "launch", 11 | "preLaunchTask": "build", 12 | // If you have changed target frameworks, make sure to update the program path. 13 | "program": "${workspaceFolder}/src/Hypermc/bin/Debug/net5.0-windows/Hypermc.dll", 14 | "args": [], 15 | "cwd": "${workspaceFolder}/src/Hypermc", 16 | // For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console 17 | "console": "internalConsole", 18 | "stopAtEntry": false 19 | }, 20 | { 21 | "name": ".NET Core Attach", 22 | "type": "coreclr", 23 | "request": "attach" 24 | } 25 | ] 26 | } -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "files.watcherExclude": { 3 | "**/target": true 4 | } 5 | } -------------------------------------------------------------------------------- /.vscode/tasks.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0.0", 3 | "tasks": [ 4 | { 5 | "label": "build", 6 | "command": "dotnet", 7 | "type": "process", 8 | "args": [ 9 | "build", 10 | "${workspaceFolder}/src/Hypermc/Hypermc.csproj", 11 | "/property:GenerateFullPaths=true", 12 | "/consoleloggerparameters:NoSummary" 13 | ], 14 | "problemMatcher": "$msCompile" 15 | }, 16 | { 17 | "label": "publish", 18 | "command": "dotnet", 19 | "type": "process", 20 | "args": [ 21 | "publish", 22 | "${workspaceFolder}/src/Hypermc/Hypermc.csproj", 23 | "/property:GenerateFullPaths=true", 24 | "/consoleloggerparameters:NoSummary" 25 | ], 26 | "problemMatcher": "$msCompile" 27 | }, 28 | { 29 | "label": "watch", 30 | "command": "dotnet", 31 | "type": "process", 32 | "args": [ 33 | "watch", 34 | "run", 35 | "${workspaceFolder}/src/Hypermc/Hypermc.csproj", 36 | "/property:GenerateFullPaths=true", 37 | "/consoleloggerparameters:NoSummary" 38 | ], 39 | "problemMatcher": "$msCompile" 40 | } 41 | ] 42 | } -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Contributor Covenant Code of Conduct 2 | 3 | ## Our Pledge 4 | 5 | We as members, contributors, and leaders pledge to make participation in our 6 | community a harassment-free experience for everyone, regardless of age, body 7 | size, visible or invisible disability, ethnicity, sex characteristics, gender 8 | identity and expression, level of experience, education, socio-economic status, 9 | nationality, personal appearance, race, religion, or sexual identity 10 | and orientation. 11 | 12 | We pledge to act and interact in ways that contribute to an open, welcoming, 13 | diverse, inclusive, and healthy community. 14 | 15 | ## Our Standards 16 | 17 | Examples of behavior that contributes to a positive environment for our 18 | community include: 19 | 20 | * Demonstrating empathy and kindness toward other people 21 | * Being respectful of differing opinions, viewpoints, and experiences 22 | * Giving and gracefully accepting constructive feedback 23 | * Accepting responsibility and apologizing to those affected by our mistakes, 24 | and learning from the experience 25 | * Focusing on what is best not just for us as individuals, but for the 26 | overall community 27 | 28 | Examples of unacceptable behavior include: 29 | 30 | * The use of sexualized language or imagery, and sexual attention or 31 | advances of any kind 32 | * Trolling, insulting or derogatory comments, and personal or political attacks 33 | * Public or private harassment 34 | * Publishing others' private information, such as a physical or email 35 | address, without their explicit permission 36 | * Other conduct which could reasonably be considered inappropriate in a 37 | professional setting 38 | 39 | ## Enforcement Responsibilities 40 | 41 | Community leaders are responsible for clarifying and enforcing our standards of 42 | acceptable behavior and will take appropriate and fair corrective action in 43 | response to any behavior that they deem inappropriate, threatening, offensive, 44 | or harmful. 45 | 46 | Community leaders have the right and responsibility to remove, edit, or reject 47 | comments, commits, code, wiki edits, issues, and other contributions that are 48 | not aligned to this Code of Conduct, and will communicate reasons for moderation 49 | decisions when appropriate. 50 | 51 | ## Scope 52 | 53 | This Code of Conduct applies within all community spaces, and also applies when 54 | an individual is officially representing the community in public spaces. 55 | Examples of representing our community include using an official e-mail address, 56 | posting via an official social media account, or acting as an appointed 57 | representative at an online or offline event. 58 | 59 | ## Enforcement 60 | 61 | Instances of abusive, harassing, or otherwise unacceptable behavior may be 62 | reported to the community leaders responsible for enforcement at 63 | . 64 | All complaints will be reviewed and investigated promptly and fairly. 65 | 66 | All community leaders are obligated to respect the privacy and security of the 67 | reporter of any incident. 68 | 69 | ## Enforcement Guidelines 70 | 71 | Community leaders will follow these Community Impact Guidelines in determining 72 | the consequences for any action they deem in violation of this Code of Conduct: 73 | 74 | ### 1. Correction 75 | 76 | **Community Impact**: Use of inappropriate language or other behavior deemed 77 | unprofessional or unwelcome in the community. 78 | 79 | **Consequence**: A private, written warning from community leaders, providing 80 | clarity around the nature of the violation and an explanation of why the 81 | behavior was inappropriate. A public apology may be requested. 82 | 83 | ### 2. Warning 84 | 85 | **Community Impact**: A violation through a single incident or series 86 | of actions. 87 | 88 | **Consequence**: A warning with consequences for continued behavior. No 89 | interaction with the people involved, including unsolicited interaction with 90 | those enforcing the Code of Conduct, for a specified period of time. This 91 | includes avoiding interactions in community spaces as well as external channels 92 | like social media. Violating these terms may lead to a temporary or 93 | permanent ban. 94 | 95 | ### 3. Temporary Ban 96 | 97 | **Community Impact**: A serious violation of community standards, including 98 | sustained inappropriate behavior. 99 | 100 | **Consequence**: A temporary ban from any sort of interaction or public 101 | communication with the community for a specified period of time. No public or 102 | private interaction with the people involved, including unsolicited interaction 103 | with those enforcing the Code of Conduct, is allowed during this period. 104 | Violating these terms may lead to a permanent ban. 105 | 106 | ### 4. Permanent Ban 107 | 108 | **Community Impact**: Demonstrating a pattern of violation of community 109 | standards, including sustained inappropriate behavior, harassment of an 110 | individual, or aggression toward or disparagement of classes of individuals. 111 | 112 | **Consequence**: A permanent ban from any sort of public interaction within 113 | the community. 114 | 115 | ## Attribution 116 | 117 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], 118 | version 2.0, available at 119 | https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. 120 | 121 | Community Impact Guidelines were inspired by [Mozilla's code of conduct 122 | enforcement ladder](https://github.com/mozilla/diversity). 123 | 124 | [homepage]: https://www.contributor-covenant.org 125 | 126 | For answers to common questions about this code of conduct, see the FAQ at 127 | https://www.contributor-covenant.org/faq. Translations are available at 128 | https://www.contributor-covenant.org/translations. 129 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing to Transcriptase 2 | We love your input! We want to make contributing to this project as easy and transparent as possible, whether it's: 3 | 4 | - Reporting a bug 5 | - Discussing the current state of the code 6 | - Submitting a fix 7 | - Proposing new features 8 | - Becoming a maintainer 9 | 10 | ## We Develop with Github 11 | We use github to host code, to track issues and feature requests, as well as accept pull requests. 12 | 13 | ## We Use [Github Flow](https://guides.github.com/introduction/flow/index.html), So All Code Changes Happen Through Pull Requests 14 | Pull requests are the best way to propose changes to the codebase (we use [Github Flow](https://guides.github.com/introduction/flow/index.html)). We actively welcome your pull requests: 15 | 16 | 1. Fork the repo and create your branch from `master`. 17 | 2. If you've added code that should be tested, add tests. 18 | 3. If you've changed APIs, update the documentation. 19 | 4. Ensure the test suite passes. 20 | 5. Make sure your code lints. 21 | 6. Issue that pull request! 22 | 23 | ## Any contributions you make will be under the MIT Software License 24 | In short, when you submit code changes, your submissions are understood to be under the same [MIT License](http://choosealicense.com/licenses/mit/) that covers the project. Feel free to contact the maintainers if that's a concern. 25 | 26 | ## Report bugs using Github's [issues](https://github.com/briandk/transcriptase-atom/issues) 27 | We use GitHub issues to track public bugs. Report a bug by [opening a new issue](); it's that easy! 28 | 29 | ## Write bug reports with detail, background, and sample code 30 | [This is an example](http://stackoverflow.com/q/12488905/180626) of a bug report I wrote, and I think it's not a bad model. Here's [another example from Craig Hockenberry](http://www.openradar.me/11905408), an app developer whom I greatly respect. 31 | 32 | **Great Bug Reports** tend to have: 33 | 34 | - A quick summary and/or background 35 | - Steps to reproduce 36 | - Be specific! 37 | - Give sample code if you can. [My stackoverflow question](http://stackoverflow.com/q/12488905/180626) includes sample code that *anyone* with a base R setup can run to reproduce what I was seeing 38 | - What you expected would happen 39 | - What actually happens 40 | - Notes (possibly including why you think this might be happening, or stuff you tried that didn't work) 41 | 42 | People *love* thorough bug reports. I'm not even kidding. 43 | 44 | ## License 45 | By contributing, you agree that your contributions will be licensed under its MIT License. 46 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Creative Commons Legal Code 2 | 3 | CC0 1.0 Universal 4 | 5 | CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE 6 | LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN 7 | ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS 8 | INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES 9 | REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS 10 | PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM 11 | THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED 12 | HEREUNDER. 13 | 14 | Statement of Purpose 15 | 16 | The laws of most jurisdictions throughout the world automatically confer 17 | exclusive Copyright and Related Rights (defined below) upon the creator 18 | and subsequent owner(s) (each and all, an "owner") of an original work of 19 | authorship and/or a database (each, a "Work"). 20 | 21 | Certain owners wish to permanently relinquish those rights to a Work for 22 | the purpose of contributing to a commons of creative, cultural and 23 | scientific works ("Commons") that the public can reliably and without fear 24 | of later claims of infringement build upon, modify, incorporate in other 25 | works, reuse and redistribute as freely as possible in any form whatsoever 26 | and for any purposes, including without limitation commercial purposes. 27 | These owners may contribute to the Commons to promote the ideal of a free 28 | culture and the further production of creative, cultural and scientific 29 | works, or to gain reputation or greater distribution for their Work in 30 | part through the use and efforts of others. 31 | 32 | For these and/or other purposes and motivations, and without any 33 | expectation of additional consideration or compensation, the person 34 | associating CC0 with a Work (the "Affirmer"), to the extent that he or she 35 | is an owner of Copyright and Related Rights in the Work, voluntarily 36 | elects to apply CC0 to the Work and publicly distribute the Work under its 37 | terms, with knowledge of his or her Copyright and Related Rights in the 38 | Work and the meaning and intended legal effect of CC0 on those rights. 39 | 40 | 1. Copyright and Related Rights. A Work made available under CC0 may be 41 | protected by copyright and related or neighboring rights ("Copyright and 42 | Related Rights"). Copyright and Related Rights include, but are not 43 | limited to, the following: 44 | 45 | i. the right to reproduce, adapt, distribute, perform, display, 46 | communicate, and translate a Work; 47 | ii. moral rights retained by the original author(s) and/or performer(s); 48 | iii. publicity and privacy rights pertaining to a person's image or 49 | likeness depicted in a Work; 50 | iv. rights protecting against unfair competition in regards to a Work, 51 | subject to the limitations in paragraph 4(a), below; 52 | v. rights protecting the extraction, dissemination, use and reuse of data 53 | in a Work; 54 | vi. database rights (such as those arising under Directive 96/9/EC of the 55 | European Parliament and of the Council of 11 March 1996 on the legal 56 | protection of databases, and under any national implementation 57 | thereof, including any amended or successor version of such 58 | directive); and 59 | vii. other similar, equivalent or corresponding rights throughout the 60 | world based on applicable law or treaty, and any national 61 | implementations thereof. 62 | 63 | 2. Waiver. To the greatest extent permitted by, but not in contravention 64 | of, applicable law, Affirmer hereby overtly, fully, permanently, 65 | irrevocably and unconditionally waives, abandons, and surrenders all of 66 | Affirmer's Copyright and Related Rights and associated claims and causes 67 | of action, whether now known or unknown (including existing as well as 68 | future claims and causes of action), in the Work (i) in all territories 69 | worldwide, (ii) for the maximum duration provided by applicable law or 70 | treaty (including future time extensions), (iii) in any current or future 71 | medium and for any number of copies, and (iv) for any purpose whatsoever, 72 | including without limitation commercial, advertising or promotional 73 | purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each 74 | member of the public at large and to the detriment of Affirmer's heirs and 75 | successors, fully intending that such Waiver shall not be subject to 76 | revocation, rescission, cancellation, termination, or any other legal or 77 | equitable action to disrupt the quiet enjoyment of the Work by the public 78 | as contemplated by Affirmer's express Statement of Purpose. 79 | 80 | 3. Public License Fallback. Should any part of the Waiver for any reason 81 | be judged legally invalid or ineffective under applicable law, then the 82 | Waiver shall be preserved to the maximum extent permitted taking into 83 | account Affirmer's express Statement of Purpose. In addition, to the 84 | extent the Waiver is so judged Affirmer hereby grants to each affected 85 | person a royalty-free, non transferable, non sublicensable, non exclusive, 86 | irrevocable and unconditional license to exercise Affirmer's Copyright and 87 | Related Rights in the Work (i) in all territories worldwide, (ii) for the 88 | maximum duration provided by applicable law or treaty (including future 89 | time extensions), (iii) in any current or future medium and for any number 90 | of copies, and (iv) for any purpose whatsoever, including without 91 | limitation commercial, advertising or promotional purposes (the 92 | "License"). The License shall be deemed effective as of the date CC0 was 93 | applied by Affirmer to the Work. Should any part of the License for any 94 | reason be judged legally invalid or ineffective under applicable law, such 95 | partial invalidity or ineffectiveness shall not invalidate the remainder 96 | of the License, and in such case Affirmer hereby affirms that he or she 97 | will not (i) exercise any of his or her remaining Copyright and Related 98 | Rights in the Work or (ii) assert any associated claims and causes of 99 | action with respect to the Work, in either case contrary to Affirmer's 100 | express Statement of Purpose. 101 | 102 | 4. Limitations and Disclaimers. 103 | 104 | a. No trademark or patent rights held by Affirmer are waived, abandoned, 105 | surrendered, licensed or otherwise affected by this document. 106 | b. Affirmer offers the Work as-is and makes no representations or 107 | warranties of any kind concerning the Work, express, implied, 108 | statutory or otherwise, including without limitation warranties of 109 | title, merchantability, fitness for a particular purpose, non 110 | infringement, or the absence of latent or other defects, accuracy, or 111 | the present or absence of errors, whether or not discoverable, all to 112 | the greatest extent permissible under applicable law. 113 | c. Affirmer disclaims responsibility for clearing rights of other persons 114 | that may apply to the Work or any use thereof, including without 115 | limitation any person's Copyright and Related Rights in the Work. 116 | Further, Affirmer disclaims responsibility for obtaining any necessary 117 | consents, permissions or other rights required for any use of the 118 | Work. 119 | d. Affirmer understands and acknowledges that Creative Commons is not a 120 | party to this document and has no duty or obligation with respect to 121 | this CC0 or use of the Work. 122 | -------------------------------------------------------------------------------- /Languages/frenchREADME.md: -------------------------------------------------------------------------------- 1 | 2 | A propos de 3 | HyperMC est un gestionnaire Minecraft Extention. Télécharger des essests puis les mettre dans les bons dossiers peut prendre du temps et être ennuyeux. Avec HyperMC, vous pouvez le faire presque instantanément! Choisissez votre actif, appuyez sur « Ajouter » et votre tout ensemble! 4 | 5 | Qu’est-ce qui nous différencie? 6 | HyperMC est un gestionnaire Minecraft Extention. Non seulement cela signifie que nous avons des mods, mais nous avons d’autres choses telles que de nouvelles versions, des API, des mods, des resourcepacks et des shaders. Nous aurons également un type de fichier personnalisé que vous pourrez utiliser pour télécharger des packs de mods fabriqués par d’autres. 7 | 8 | Pourquoi devriez-vous télécharger? 9 | Bien qu’il s’agisse d’un projet jeune, nous sommes encore en train de développer. Comme nous sommes si jeunes, cela signifie que nous mettons constamment à jour et ajoutons de nouvelles fonctionnalités et corrigeons des bogues. 10 | 11 | Quels paquets utilisons-nous ? 12 | Nous utilisons quelques paquets différents. En tant que gestionnaire de package, nous utilisons nuGet.As a package manager we use nuGet. 13 | 14 | voici quelques-uns des paquets que nous utilisons: 15 | 16 | 17 | - LibGit2Sharp 18 | - ForgedSource (wraper) 19 | 20 | 21 | Cadre: 22 | 23 | WinForms 24 | 25 | L’inspiration 26 | Im un grand fan de KSP. J’aime les nouvelles choses. Mettez-les ensemble, vous obtenez des mods de jeu. Je me suis vraiment agacé en téléchargeant une tonne de fichiers et en mettant le dossier gamedata, alors j’ai cherché une solution alternative. C’est quand j’ai trouvé CKAN (The Comprehensive Kerbal Archive Network). J’en suis tombée amoureuse. Puis mon cerveau a dit: « Et si je faisais la même chose avec l’un de mes jeux préférés de tous les temps. Minecraft ». J’ai donc commencé le développement 27 | 28 | État d’avancement 29 | À l’heure actuelle, nous en sommes encore aux premiers stades de développement. 30 | 31 | Contributeurs 32 | Merci beaucoup à tous les contributeurs incroyables. Je tiens à donner une mention spéciale à TheBoxyBear pour être ici depuis le jour 1. 33 | TheBoxyBear github: https://github.com/TheBoxyBear 34 | Et pour rester à jour, consultez notre reddit ici: https://www.reddit.com/r/hypermc/ 35 | 36 | L'un de nos développeurs a créé un conteneur d'API qui est utilisé dans ce projet. Vous pouvez vérifier ici https://github.com/AndrewToaster/ForgedCurse :) 37 | -------------------------------------------------------------------------------- /Languages/spanishREADME.md: -------------------------------------------------------------------------------- 1 | Acerca de HyperMC es un administrador de extensiones de Minecraft. Descargar ensayos y luego colocarlos en archivos buenos puede llevar tiempo y ser innovador. ¡Con HyperMC, puede hacerlo casi instantáneamente! ¡Elija su activo, apoye "Agregar" y todo su conjunto! 2 | 3 | ¿Qué es lo que nos diferencia? HyperMC es un administrador de extensiones de Minecraft. No solo significa que tenemos los modos, sino que tenemos otras opciones, como nuevas versiones, API, modos, paquetes de recursos y sombreadores. También tenemos un tipo de archivo personalizado que puede usar para descargar paquetes de modificaciones hechas por otros. 4 | 5 | ¿Por qué debería descargarlo? Bueno, si es un proyecto joven, todavía lo estamos desarrollando. Como somos jóvenes, esto significa que estamos constantemente actualizando y agregando nuevas funciones y correcciones de errores. 6 | 7 | ¿Qué paquetes usamos? Usamos algunos paquetes diferentes. Como administrador de paquetes usamos nuGet, como administrador de paquetes usamos nuGet. 8 | 9 | estos son algunos de los paquetes que usamos: 10 | 11 | - LibGit2Sharp 12 | - ForgedSource (envoltorio) 13 | Marco de referencia: 14 | 15 | WinForms 16 | 17 | La inspiración Soy un gran fan de KSP. Amo las cosas nuevas. Ponlos todos juntos, obtienes modos de juego. Tenía muchas ganas de descargar una tonelada de archivos y luego el archivo de datos del juego, mientras buscaba una solución alternativa. Fue entonces cuando encontré CKAN (The Comprehensive Kerbal Archive Network). Soy un amante cariñoso. Entonces mi cerebro dijo: “Y si hiciera lo mismo con uno de mis juegos favoritos de todos los tiempos. Minecraft ". Por lo tanto, comencé el desarrollo 18 | 19 | Estado avanzado En la actualidad, todavía estamos en las primeras etapas de desarrollo. 20 | 21 | Colaboradores Muchas gracias a todos los increíbles colaboradores. Tengo que dar una mención especial a TheBoxyBear por estar aquí desde el día 1. TheBoxyBear github: https://github.com/TheBoxyBear Y para estar al día, echa un vistazo a nuestro reddit aquí: https://www.reddit.com/r/hypermc/ 22 | 23 | Uno de nuestros desarrolladores ha creado un contenedor de API que se utiliza en este proyecto. Puede consultar aquí https://github.com/AndrewToaster/ForgedCurse :) 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 |

3 | 4 |
5 |

HyperMC

6 |

7 |

8 | 9 | 10 | 11 | 12 | 13 | 14 |


15 | 16 |

17 | 18 | # This project is abandoned 19 | -sadly we abandoned this project. 20 | 21 | 22 | -because overflow stopped developing 23 | 24 | -and the team was not sure where to go 25 | 26 | -so we are no longer working 27 | 28 | on hyperMC 29 | 30 | 31 | # LANGUAGE SUPPORT 32 | - **[Documentation Français](https://github.com/TechPenguineer/Hypermc/blob/Windows/Languages/frenchREADME.md)** 33 | 34 | - **[Documentation España](https://github.com/TechPenguineer/Hypermc/blob/Windows/Languages/spanishREADME.md)** 35 | 36 |

37 |

About

38 |

39 | HyperMC is a Minecraft Extention manager. Downloading assests then putting them into the right folders can be time consuming and annoying. With HyperMC you can do it almost instantly! Choose your asset, press "Add" and your all set! 40 |

41 |

42 |
43 |

44 |

What makes us different?

45 |

46 | HyperMC is a Minecraft Extention manager. Not only does it mean that we have mods but we have other things such as new versions, apis, mods, resourcepacks, and shaders. We will also have a custom file type that you can use to download mod packs made by others. 47 |

48 |

49 |
50 |

51 |

Why should you download?

52 |

53 | Although this is a young project we are still developing. Since we are so young that means we are constantly updating and adding new features and fixing bugs. 54 |

55 |

56 |
57 |

58 |

What packages do we use?

59 |

60 | We use a few different packages. As a package manager we use nuGet. 61 |
62 | heres some of out packages we use: 63 |
64 |
65 | - LibGit2Sharp
66 | - ForgedSource (wraper) 67 |

68 | Frame work: 69 |
WinForms 70 |

71 |

72 |
73 |

74 |

Inspiration

75 |

76 | Im a big KSP fan. I love new things. Put those together you get game mods. I got really annoyed downloading a ton of files and putting the gamedata folder so I looked up an alternative solution. Thats when I found CKAN (The Comprehensive Kerbal Archive Network). I fell in love with it. Then my brain went, "What if I do the samething with one of my all time favourite games. Minecraft". So I started development 77 |

78 |

79 |
80 |

81 |

Status

82 |

83 | As of 22/7/2021 we started the dependency injector 84 |

85 |

86 |
87 |

88 |

Contributers

89 | 90 | 91 | ![GitHub Contributors Image](https://contrib.rocks/image?repo=TechPenguineer/Hypermc) 92 | 93 | -------------------------------------------------------------------------------- /archive/.gitignore: -------------------------------------------------------------------------------- 1 | 2 | #*.exe 3 | #*.pdb 4 | #*.dll 5 | #/.metals 6 | #bin/ 7 | #obj/ 8 | #*.cache 9 | #/Hypermc/mod-pack/ 10 | #/mods 11 | #/Hypermc_TemporaryKey.pfx 12 | #/Hypermc.csproj.user 13 | #/Hypermc.pdb 14 | #/Hypermc.exe.config 15 | #Hypermc.sln 16 | #source/mod-pack/ 17 | #.vs/Hypermc/v16/.suo 18 | #source/Hypermc.csproj.user 19 | #source/obj/Debug/net5.0-windows/Hypermc.csproj.FileListAbsolute.txt 20 | #.vs/Hypermc/DesignTimeBuild/.dtbcache.v2 21 | #source/Hypermc.csproj.user 22 | # 23 | ## Ignore NuGet Packages 24 | #*.nupkg 25 | # 26 | ## The packages folder can be ignored because of Package Restore 27 | #**/[Pp]ackages/* 28 | # 29 | ## except build/, which is used as an MSBuild target. 30 | #!**/[Pp]ackages/build/ 31 | # 32 | ## NuGet v3's project.json files produces more ignorable files 33 | #*.nuget.props 34 | #*.nuget.targets 35 | # 36 | ## Ignore other intermediate files that NuGet might create. project.lock.json is used in conjunction 37 | ## with project.json (NuGet v3); project.assets.json is used in conjunction with the PackageReference 38 | ## format (NuGet v4 and .NET Core). 39 | #project.lock.json 40 | #project.assets.json 41 | # 42 | 43 | 44 | ## Ignore Visual Studio temporary files, build results, and 45 | ## files generated by popular Visual Studio add-ons. 46 | ## 47 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 48 | 49 | # User-specific files 50 | *.rsuser 51 | *.suo 52 | *.user 53 | *.userosscache 54 | *.sln.docstates 55 | 56 | # User-specific files (MonoDevelop/Xamarin Studio) 57 | *.userprefs 58 | 59 | # Mono auto generated files 60 | mono_crash.* 61 | 62 | # Build results 63 | [Dd]ebug/ 64 | [Dd]ebugPublic/ 65 | [Rr]elease/ 66 | [Rr]eleases/ 67 | x64/ 68 | x86/ 69 | [Aa][Rr][Mm]/ 70 | [Aa][Rr][Mm]64/ 71 | bld/ 72 | [Bb]in/ 73 | [Oo]bj/ 74 | [Ll]og/ 75 | [Ll]ogs/ 76 | 77 | # Visual Studio 2015/2017 cache/options directory 78 | .vs/ 79 | # Uncomment if you have tasks that create the project's static files in wwwroot 80 | #wwwroot/ 81 | 82 | # Visual Studio 2017 auto generated files 83 | Generated\ Files/ 84 | 85 | # MSTest test Results 86 | [Tt]est[Rr]esult*/ 87 | [Bb]uild[Ll]og.* 88 | 89 | # NUnit 90 | *.VisualState.xml 91 | TestResult.xml 92 | nunit-*.xml 93 | 94 | # Build Results of an ATL Project 95 | [Dd]ebugPS/ 96 | [Rr]eleasePS/ 97 | dlldata.c 98 | 99 | # Benchmark Results 100 | BenchmarkDotNet.Artifacts/ 101 | 102 | # .NET Core 103 | project.lock.json 104 | project.fragment.lock.json 105 | artifacts/ 106 | 107 | # StyleCop 108 | StyleCopReport.xml 109 | 110 | # Files built by Visual Studio 111 | *_i.c 112 | *_p.c 113 | *_h.h 114 | *.ilk 115 | *.meta 116 | *.obj 117 | *.iobj 118 | *.pch 119 | *.pdb 120 | *.ipdb 121 | *.pgc 122 | *.pgd 123 | *.rsp 124 | *.sbr 125 | *.tlb 126 | *.tli 127 | *.tlh 128 | *.tmp 129 | *.tmp_proj 130 | *_wpftmp.csproj 131 | *.log 132 | *.vspscc 133 | *.vssscc 134 | .builds 135 | *.pidb 136 | *.svclog 137 | *.scc 138 | 139 | # Chutzpah Test files 140 | _Chutzpah* 141 | 142 | # Visual C++ cache files 143 | ipch/ 144 | *.aps 145 | *.ncb 146 | *.opendb 147 | *.opensdf 148 | *.sdf 149 | *.cachefile 150 | *.VC.db 151 | *.VC.VC.opendb 152 | 153 | # Visual Studio profiler 154 | *.psess 155 | *.vsp 156 | *.vspx 157 | *.sap 158 | 159 | # Visual Studio Trace Files 160 | *.e2e 161 | 162 | # TFS 2012 Local Workspace 163 | $tf/ 164 | 165 | # Guidance Automation Toolkit 166 | *.gpState 167 | 168 | # ReSharper is a .NET coding add-in 169 | _ReSharper*/ 170 | *.[Rr]e[Ss]harper 171 | *.DotSettings.user 172 | 173 | # TeamCity is a build add-in 174 | _TeamCity* 175 | 176 | # DotCover is a Code Coverage Tool 177 | *.dotCover 178 | 179 | # AxoCover is a Code Coverage Tool 180 | .axoCover/* 181 | !.axoCover/settings.json 182 | 183 | # Visual Studio code coverage results 184 | *.coverage 185 | *.coveragexml 186 | 187 | # NCrunch 188 | _NCrunch_* 189 | .*crunch*.local.xml 190 | nCrunchTemp_* 191 | 192 | # MightyMoose 193 | *.mm.* 194 | AutoTest.Net/ 195 | 196 | # Web workbench (sass) 197 | .sass-cache/ 198 | 199 | # Installshield output folder 200 | [Ee]xpress/ 201 | 202 | # DocProject is a documentation generator add-in 203 | DocProject/buildhelp/ 204 | DocProject/Help/*.HxT 205 | DocProject/Help/*.HxC 206 | DocProject/Help/*.hhc 207 | DocProject/Help/*.hhk 208 | DocProject/Help/*.hhp 209 | DocProject/Help/Html2 210 | DocProject/Help/html 211 | 212 | # Click-Once directory 213 | publish/ 214 | 215 | # Publish Web Output 216 | *.[Pp]ublish.xml 217 | *.azurePubxml 218 | # Note: Comment the next line if you want to checkin your web deploy settings, 219 | # but database connection strings (with potential passwords) will be unencrypted 220 | *.pubxml 221 | *.publishproj 222 | 223 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 224 | # checkin your Azure Web App publish settings, but sensitive information contained 225 | # in these scripts will be unencrypted 226 | PublishScripts/ 227 | 228 | # NuGet Packages 229 | *.nupkg 230 | # NuGet Symbol Packages 231 | *.snupkg 232 | # The packages folder can be ignored because of Package Restore 233 | **/[Pp]ackages/* 234 | # except build/, which is used as an MSBuild target. 235 | !**/[Pp]ackages/build/ 236 | # Uncomment if necessary however generally it will be regenerated when needed 237 | #!**/[Pp]ackages/repositories.config 238 | # NuGet v3's project.json files produces more ignorable files 239 | *.nuget.props 240 | *.nuget.targets 241 | 242 | # Microsoft Azure Build Output 243 | csx/ 244 | *.build.csdef 245 | 246 | # Microsoft Azure Emulator 247 | ecf/ 248 | rcf/ 249 | 250 | # Windows Store app package directories and files 251 | AppPackages/ 252 | BundleArtifacts/ 253 | Package.StoreAssociation.xml 254 | _pkginfo.txt 255 | *.appx 256 | *.appxbundle 257 | *.appxupload 258 | 259 | # Visual Studio cache files 260 | # files ending in .cache can be ignored 261 | *.[Cc]ache 262 | # but keep track of directories ending in .cache 263 | !?*.[Cc]ache/ 264 | 265 | # Others 266 | ClientBin/ 267 | ~$* 268 | *~ 269 | *.dbmdl 270 | *.dbproj.schemaview 271 | *.jfm 272 | *.pfx 273 | *.publishsettings 274 | orleans.codegen.cs 275 | 276 | # Including strong name files can present a security risk 277 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 278 | #*.snk 279 | 280 | # Since there are multiple workflows, uncomment next line to ignore bower_components 281 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 282 | #bower_components/ 283 | 284 | # RIA/Silverlight projects 285 | Generated_Code/ 286 | 287 | # Backup & report files from converting an old project file 288 | # to a newer Visual Studio version. Backup files are not needed, 289 | # because we have git ;-) 290 | _UpgradeReport_Files/ 291 | Backup*/ 292 | UpgradeLog*.XML 293 | UpgradeLog*.htm 294 | ServiceFabricBackup/ 295 | *.rptproj.bak 296 | 297 | # SQL Server files 298 | *.mdf 299 | *.ldf 300 | *.ndf 301 | 302 | # Business Intelligence projects 303 | *.rdl.data 304 | *.bim.layout 305 | *.bim_*.settings 306 | *.rptproj.rsuser 307 | *- [Bb]ackup.rdl 308 | *- [Bb]ackup ([0-9]).rdl 309 | *- [Bb]ackup ([0-9][0-9]).rdl 310 | 311 | # Microsoft Fakes 312 | FakesAssemblies/ 313 | 314 | # GhostDoc plugin setting file 315 | *.GhostDoc.xml 316 | 317 | # Node.js Tools for Visual Studio 318 | .ntvs_analysis.dat 319 | node_modules/ 320 | 321 | # Visual Studio 6 build log 322 | *.plg 323 | 324 | # Visual Studio 6 workspace options file 325 | *.opt 326 | 327 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 328 | *.vbw 329 | 330 | # Visual Studio LightSwitch build output 331 | **/*.HTMLClient/GeneratedArtifacts 332 | **/*.DesktopClient/GeneratedArtifacts 333 | **/*.DesktopClient/ModelManifest.xml 334 | **/*.Server/GeneratedArtifacts 335 | **/*.Server/ModelManifest.xml 336 | _Pvt_Extensions 337 | 338 | # Paket dependency manager 339 | .paket/paket.exe 340 | paket-files/ 341 | 342 | # FAKE - F# Make 343 | .fake/ 344 | 345 | # CodeRush personal settings 346 | .cr/personal 347 | 348 | # Python Tools for Visual Studio (PTVS) 349 | __pycache__/ 350 | *.pyc 351 | 352 | # Cake - Uncomment if you are using it 353 | # tools/** 354 | # !tools/packages.config 355 | 356 | # Tabs Studio 357 | *.tss 358 | 359 | # Telerik's JustMock configuration file 360 | *.jmconfig 361 | 362 | # BizTalk build output 363 | *.btp.cs 364 | *.btm.cs 365 | *.odx.cs 366 | *.xsd.cs 367 | 368 | # OpenCover UI analysis results 369 | OpenCover/ 370 | 371 | # Azure Stream Analytics local run output 372 | ASALocalRun/ 373 | 374 | # MSBuild Binary and Structured Log 375 | *.binlog 376 | 377 | # NVidia Nsight GPU debugger configuration file 378 | *.nvuser 379 | 380 | # MFractors (Xamarin productivity tool) working folder 381 | .mfractor/ 382 | 383 | # Local History for Visual Studio 384 | .localhistory/ 385 | 386 | # BeatPulse healthcheck temp database 387 | healthchecksdb 388 | 389 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 390 | MigrationBackup/ 391 | 392 | # Ionide (cross platform F# VS Code tools) working folder 393 | .ionide/ 394 | -------------------------------------------------------------------------------- /cli/makefile: -------------------------------------------------------------------------------- 1 | CC=gcc 2 | OUTPUT_DIR=$(wildcard out/$@.o) 3 | SRC=$(wildcard src/*.*) 4 | CFLAGS= -Wall -o 5 | VERSION=1-0-0 6 | 7 | build-exe: $(SRC) 8 | $(CC) -g $(SRC) $(CFLAGS) out/HyperMc-cli-$(VERSION) 9 | make build-obj 10 | 11 | build-obj: 12 | $(CC) -g $(SRC) $(CFLAGS) out/HyperMc-cli-$(VERSION).o 13 | 14 | clean: 15 | rm out/*.* -------------------------------------------------------------------------------- /cli/out/HyperMc-cli-1-0-0.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TechPenguineer/Hypermc/c32ccf824f1afdc29cd6e0e78242e7dd79e12f57/cli/out/HyperMc-cli-1-0-0.o -------------------------------------------------------------------------------- /cli/src/hmc.c: -------------------------------------------------------------------------------- 1 | #include "includer.h" 2 | #include 3 | #include 4 | #include 5 | 6 | int main(int argc, char *argv[]) 7 | { 8 | if(strcmp(argv[1], "config")==0 && strcmp(argv[2], "-s")==0) 9 | { 10 | if(argc != 4){ 11 | printf("Invalid Argumentation"); 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /cli/src/includer.h: -------------------------------------------------------------------------------- 1 | #ifndef INCLUDER_DOT_H 2 | #define INCLUDER_DOT_H 3 | 4 | void SetUserSetting(char *setting[], int argc, char *argv[]); 5 | 6 | #endif // !INCLUDER_DOT_H -------------------------------------------------------------------------------- /cli/src/userSettings.c: -------------------------------------------------------------------------------- 1 | #include "includer.h" 2 | 3 | void SetUserSetting(char *setting[], int argc, char *argv[]) 4 | { 5 | 6 | } -------------------------------------------------------------------------------- /docs/howToInstall.md: -------------------------------------------------------------------------------- 1 | If you are an early adopter of a new version, you may get a Windows Security warning - This is fine, and it is safe. Click "Run Anyway" to continue. 2 | 3 | Step 1. Install the exe 4 | 5 | Step 2. You will get a warning. It is a safe file just not comonly used. Press "Run Anyway". 6 | 7 | Step 3. Launch the application. This will bring up a terminal window for a breif second. Do NOT cancel the operation. 8 | 9 | Step 4: A ui window will popup. You can install mods from there -------------------------------------------------------------------------------- /docs/howToUse.md: -------------------------------------------------------------------------------- 1 | COMING SOON -------------------------------------------------------------------------------- /installer.nsi: -------------------------------------------------------------------------------- 1 | !define APP_NAME "HyperMc" 2 | !define APP_VERSION "1.0.0" 3 | 4 | !define INSTALLER_TITLE "${APP_NAME} - ${APP_VERSION} - Setup" 5 | !define UNINSTALLER_TITLE "${APP_NAME} - ${APP_VERSION} - Uninstaller" 6 | 7 | !addincludedir "./" 8 | 9 | !include "MUI.nsh" 10 | !include "MUI2.nsh" 11 | 12 | SetCompressor lzma 13 | 14 | !insertmacro MUI_LANGUAGE "English" 15 | 16 | RequestExecutionLevel user 17 | 18 | ; ---------------------- PAGES ---------------------- 19 | Page directory 20 | Page instfiles 21 | 22 | ; ---------------------- INSTALL ---------------------- 23 | 24 | Name "${INSTALLER_TITLE}" 25 | OutFile "hypermc-setup-${APP_VERSION}.exe" 26 | InstallDir "$PROGRAMFILES\Hypermc" 27 | ShowUnInstDetails show 28 | 29 | Section "MainSection" SEC01 30 | 31 | SectionEnd 32 | 33 | 34 | ; ---------------------- FUNCITONS ---------------------- 35 | Function .onVerifyInstDir 36 | ReadEnvStr $0 "ProgramFiles(x86)" 37 | StrCmp $0 $INSTDIR 0 PathGood 38 | MessageBox MB_OK "directory not valid for installation" 39 | Abort 40 | PathGood: 41 | FunctionEnd -------------------------------------------------------------------------------- /license.txt: -------------------------------------------------------------------------------- 1 | Creative Commons Legal Code 2 | 3 | CC0 1.0 Universal 4 | 5 | CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE 6 | LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN 7 | ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS 8 | INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES 9 | REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS 10 | PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM 11 | THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED 12 | HEREUNDER. 13 | 14 | Statement of Purpose 15 | 16 | The laws of most jurisdictions throughout the world automatically confer 17 | exclusive Copyright and Related Rights (defined below) upon the creator 18 | and subsequent owner(s) (each and all, an "owner") of an original work of 19 | authorship and/or a database (each, a "Work"). 20 | 21 | Certain owners wish to permanently relinquish those rights to a Work for 22 | the purpose of contributing to a commons of creative, cultural and 23 | scientific works ("Commons") that the public can reliably and without fear 24 | of later claims of infringement build upon, modify, incorporate in other 25 | works, reuse and redistribute as freely as possible in any form whatsoever 26 | and for any purposes, including without limitation commercial purposes. 27 | These owners may contribute to the Commons to promote the ideal of a free 28 | culture and the further production of creative, cultural and scientific 29 | works, or to gain reputation or greater distribution for their Work in 30 | part through the use and efforts of others. 31 | 32 | For these and/or other purposes and motivations, and without any 33 | expectation of additional consideration or compensation, the person 34 | associating CC0 with a Work (the "Affirmer"), to the extent that he or she 35 | is an owner of Copyright and Related Rights in the Work, voluntarily 36 | elects to apply CC0 to the Work and publicly distribute the Work under its 37 | terms, with knowledge of his or her Copyright and Related Rights in the 38 | Work and the meaning and intended legal effect of CC0 on those rights. 39 | 40 | 1. Copyright and Related Rights. A Work made available under CC0 may be 41 | protected by copyright and related or neighboring rights ("Copyright and 42 | Related Rights"). Copyright and Related Rights include, but are not 43 | limited to, the following: 44 | 45 | i. the right to reproduce, adapt, distribute, perform, display, 46 | communicate, and translate a Work; 47 | ii. moral rights retained by the original author(s) and/or performer(s); 48 | iii. publicity and privacy rights pertaining to a person's image or 49 | likeness depicted in a Work; 50 | iv. rights protecting against unfair competition in regards to a Work, 51 | subject to the limitations in paragraph 4(a), below; 52 | v. rights protecting the extraction, dissemination, use and reuse of data 53 | in a Work; 54 | vi. database rights (such as those arising under Directive 96/9/EC of the 55 | European Parliament and of the Council of 11 March 1996 on the legal 56 | protection of databases, and under any national implementation 57 | thereof, including any amended or successor version of such 58 | directive); and 59 | vii. other similar, equivalent or corresponding rights throughout the 60 | world based on applicable law or treaty, and any national 61 | implementations thereof. 62 | 63 | 2. Waiver. To the greatest extent permitted by, but not in contravention 64 | of, applicable law, Affirmer hereby overtly, fully, permanently, 65 | irrevocably and unconditionally waives, abandons, and surrenders all of 66 | Affirmer's Copyright and Related Rights and associated claims and causes 67 | of action, whether now known or unknown (including existing as well as 68 | future claims and causes of action), in the Work (i) in all territories 69 | worldwide, (ii) for the maximum duration provided by applicable law or 70 | treaty (including future time extensions), (iii) in any current or future 71 | medium and for any number of copies, and (iv) for any purpose whatsoever, 72 | including without limitation commercial, advertising or promotional 73 | purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each 74 | member of the public at large and to the detriment of Affirmer's heirs and 75 | successors, fully intending that such Waiver shall not be subject to 76 | revocation, rescission, cancellation, termination, or any other legal or 77 | equitable action to disrupt the quiet enjoyment of the Work by the public 78 | as contemplated by Affirmer's express Statement of Purpose. 79 | 80 | 3. Public License Fallback. Should any part of the Waiver for any reason 81 | be judged legally invalid or ineffective under applicable law, then the 82 | Waiver shall be preserved to the maximum extent permitted taking into 83 | account Affirmer's express Statement of Purpose. In addition, to the 84 | extent the Waiver is so judged Affirmer hereby grants to each affected 85 | person a royalty-free, non transferable, non sublicensable, non exclusive, 86 | irrevocable and unconditional license to exercise Affirmer's Copyright and 87 | Related Rights in the Work (i) in all territories worldwide, (ii) for the 88 | maximum duration provided by applicable law or treaty (including future 89 | time extensions), (iii) in any current or future medium and for any number 90 | of copies, and (iv) for any purpose whatsoever, including without 91 | limitation commercial, advertising or promotional purposes (the 92 | "License"). The License shall be deemed effective as of the date CC0 was 93 | applied by Affirmer to the Work. Should any part of the License for any 94 | reason be judged legally invalid or ineffective under applicable law, such 95 | partial invalidity or ineffectiveness shall not invalidate the remainder 96 | of the License, and in such case Affirmer hereby affirms that he or she 97 | will not (i) exercise any of his or her remaining Copyright and Related 98 | Rights in the Work or (ii) assert any associated claims and causes of 99 | action with respect to the Work, in either case contrary to Affirmer's 100 | express Statement of Purpose. 101 | 102 | 4. Limitations and Disclaimers. 103 | 104 | a. No trademark or patent rights held by Affirmer are waived, abandoned, 105 | surrendered, licensed or otherwise affected by this document. 106 | b. Affirmer offers the Work as-is and makes no representations or 107 | warranties of any kind concerning the Work, express, implied, 108 | statutory or otherwise, including without limitation warranties of 109 | title, merchantability, fitness for a particular purpose, non 110 | infringement, or the absence of latent or other defects, accuracy, or 111 | the present or absence of errors, whether or not discoverable, all to 112 | the greatest extent permissible under applicable law. 113 | c. Affirmer disclaims responsibility for clearing rights of other persons 114 | that may apply to the Work or any use thereof, including without 115 | limitation any person's Copyright and Related Rights in the Work. 116 | Further, Affirmer disclaims responsibility for obtaining any necessary 117 | consents, permissions or other rights required for any use of the 118 | Work. 119 | d. Affirmer understands and acknowledges that Creative Commons is not a 120 | party to this document and has no duty or obligation with respect to 121 | this CC0 or use of the Work. 122 | -------------------------------------------------------------------------------- /renovate.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": [ 3 | "config:base" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /src/HyperMC/Api/fetchMod.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ForgedCurse; 7 | using ForgedCurse.Json; 8 | namespace Hypermc.Api 9 | { 10 | class fetchMod 11 | { 12 | 13 | void createForgeClient() 14 | { 15 | ForgeClient client = new ForgeClient(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/HyperMC/Data/ModpackData.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Drawing; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | 8 | namespace Hypermc.Data 9 | { 10 | public class ModpackData 11 | { 12 | public string Name { get; set; } 13 | public string Thumbnail { get; } 14 | public string Path { get; } 15 | 16 | public ModpackData() 17 | { 18 | 19 | } 20 | 21 | public ModpackData(string name, string thumbnail, string path) 22 | { 23 | Name = name; 24 | Thumbnail = thumbnail; 25 | Path = path; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /src/HyperMC/Data/VersionData.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using ForgedCurse; 7 | 8 | 9 | 10 | 11 | 12 | 13 | namespace HypermcData 14 | { 15 | public class VersionData 16 | { 17 | 18 | ForgeClient client = new ForgeClient(); 19 | 20 | public void getForgeVersions() 21 | { 22 | } 23 | public void getMinecraftVersions() 24 | { 25 | 26 | client.Minecraft.RetrieveGameVersions(); 27 | } 28 | }; 29 | } -------------------------------------------------------------------------------- /src/HyperMC/HyperMC.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | WinExe 5 | net5.0-windows 6 | enable 7 | true 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | True 26 | True 27 | Resources.resx 28 | 29 | 30 | 31 | 32 | 33 | ResXFileCodeGenerator 34 | Resources.Designer.cs 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | PreserveNewest 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /src/HyperMC/HyperMcView.Designer.cs: -------------------------------------------------------------------------------- 1 |  2 | using System; 3 | 4 | namespace Hypermc 5 | { 6 | public partial class HyperMcView 7 | { 8 | /// 9 | /// Required designer variable. 10 | /// 11 | private System.ComponentModel.IContainer components = null; 12 | 13 | /// 14 | /// Clean up any resources being used. 15 | /// 16 | /// true if managed resources should be disposed; otherwise, false. 17 | protected override void Dispose(bool disposing) 18 | { 19 | if (disposing && (components != null)) 20 | { 21 | components.Dispose(); 22 | } 23 | base.Dispose(disposing); 24 | } 25 | #region Windows Form Designer generated code 26 | 27 | /// 28 | /// Required method for Designer support - do not modify 29 | /// the contents of this method with the code editor. 30 | /// 31 | private void InitializeComponent() 32 | { 33 | this.dpnl_Top = new Hypermc.UI.Components.DraggablePanel(); 34 | this.label1 = new System.Windows.Forms.Label(); 35 | this.pcb_Icon = new System.Windows.Forms.PictureBox(); 36 | this.tlpnl_TopButtons = new System.Windows.Forms.TableLayoutPanel(); 37 | this.hbtn_Minimize = new Hypermc.UI.Components.HoverButton(); 38 | this.hbtn_Close = new Hypermc.UI.Components.HoverButton(); 39 | this.hbtn_Options = new Hypermc.UI.Components.HoverButton(); 40 | this.hbtn_Maximize = new Hypermc.UI.Components.HoverButton(); 41 | this.cpy_right = new System.Windows.Forms.Label(); 42 | this.pnl_MainArea = new System.Windows.Forms.Panel(); 43 | this.panel1 = new System.Windows.Forms.Panel(); 44 | this.hbtn_CreateModpack = new Hypermc.UI.Components.HoverButton(); 45 | this.flpnl_Modpacks = new System.Windows.Forms.FlowLayoutPanel(); 46 | this.hoverButton1 = new Hypermc.UI.Components.HoverButton(); 47 | this.dpnl_Top.SuspendLayout(); 48 | ((System.ComponentModel.ISupportInitialize)(this.pcb_Icon)).BeginInit(); 49 | this.tlpnl_TopButtons.SuspendLayout(); 50 | this.pnl_MainArea.SuspendLayout(); 51 | this.panel1.SuspendLayout(); 52 | this.SuspendLayout(); 53 | // 54 | // dpnl_Top 55 | // 56 | this.dpnl_Top.BackColor = System.Drawing.Color.White; 57 | this.dpnl_Top.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 58 | this.dpnl_Top.Controls.Add(this.label1); 59 | this.dpnl_Top.Controls.Add(this.pcb_Icon); 60 | this.dpnl_Top.Controls.Add(this.tlpnl_TopButtons); 61 | this.dpnl_Top.Dock = System.Windows.Forms.DockStyle.Top; 62 | this.dpnl_Top.DragControl = this; 63 | this.dpnl_Top.Location = new System.Drawing.Point(0, 0); 64 | this.dpnl_Top.Margin = new System.Windows.Forms.Padding(0); 65 | this.dpnl_Top.Name = "dpnl_Top"; 66 | this.dpnl_Top.Size = new System.Drawing.Size(1082, 40); 67 | this.dpnl_Top.TabIndex = 2; 68 | // 69 | // label1 70 | // 71 | this.label1.Anchor = System.Windows.Forms.AnchorStyles.Top; 72 | this.label1.AutoSize = true; 73 | this.label1.Font = new System.Drawing.Font("Microsoft Tai Le", 10.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 74 | this.label1.Location = new System.Drawing.Point(537, 8); 75 | this.label1.Name = "label1"; 76 | this.label1.Size = new System.Drawing.Size(71, 19); 77 | this.label1.TabIndex = 1; 78 | this.label1.Text = "HyperMC"; 79 | // 80 | // pcb_Icon 81 | // 82 | this.pcb_Icon.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch; 83 | this.pcb_Icon.Image = global::Hypermc.Properties.Resources.HyperMc32; 84 | this.pcb_Icon.Location = new System.Drawing.Point(11, 1); 85 | this.pcb_Icon.Margin = new System.Windows.Forms.Padding(0); 86 | this.pcb_Icon.Name = "pcb_Icon"; 87 | this.pcb_Icon.Size = new System.Drawing.Size(31, 32); 88 | this.pcb_Icon.TabIndex = 2; 89 | this.pcb_Icon.TabStop = false; 90 | // 91 | // tlpnl_TopButtons 92 | // 93 | this.tlpnl_TopButtons.ColumnCount = 5; 94 | this.tlpnl_TopButtons.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 46F)); 95 | this.tlpnl_TopButtons.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 76F)); 96 | this.tlpnl_TopButtons.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 46F)); 97 | this.tlpnl_TopButtons.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 46F)); 98 | this.tlpnl_TopButtons.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 46F)); 99 | this.tlpnl_TopButtons.Controls.Add(this.hbtn_Minimize, 2, 0); 100 | this.tlpnl_TopButtons.Controls.Add(this.hbtn_Close, 4, 0); 101 | this.tlpnl_TopButtons.Controls.Add(this.hbtn_Options, 0, 0); 102 | this.tlpnl_TopButtons.Controls.Add(this.hbtn_Maximize, 3, 0); 103 | this.tlpnl_TopButtons.Dock = System.Windows.Forms.DockStyle.Right; 104 | this.tlpnl_TopButtons.Location = new System.Drawing.Point(820, 0); 105 | this.tlpnl_TopButtons.Margin = new System.Windows.Forms.Padding(0); 106 | this.tlpnl_TopButtons.Name = "tlpnl_TopButtons"; 107 | this.tlpnl_TopButtons.RowCount = 1; 108 | this.tlpnl_TopButtons.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F)); 109 | this.tlpnl_TopButtons.Size = new System.Drawing.Size(260, 38); 110 | this.tlpnl_TopButtons.TabIndex = 0; 111 | // 112 | // hbtn_Minimize 113 | // 114 | this.hbtn_Minimize.Dock = System.Windows.Forms.DockStyle.Right; 115 | this.hbtn_Minimize.FlatAppearance.BorderSize = 0; 116 | this.hbtn_Minimize.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 117 | this.hbtn_Minimize.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 118 | this.hbtn_Minimize.HoverBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); 119 | this.hbtn_Minimize.HoverForeColor = System.Drawing.Color.Empty; 120 | this.hbtn_Minimize.Location = new System.Drawing.Point(125, 3); 121 | this.hbtn_Minimize.Name = "hbtn_Minimize"; 122 | this.hbtn_Minimize.Size = new System.Drawing.Size(40, 32); 123 | this.hbtn_Minimize.TabIndex = 2; 124 | this.hbtn_Minimize.Text = "-"; 125 | this.hbtn_Minimize.UseVisualStyleBackColor = true; 126 | this.hbtn_Minimize.Click += new System.EventHandler(this.Hbtn_Minimize_Click); 127 | // 128 | // hbtn_Close 129 | // 130 | this.hbtn_Close.Dock = System.Windows.Forms.DockStyle.Right; 131 | this.hbtn_Close.FlatAppearance.BorderSize = 0; 132 | this.hbtn_Close.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 133 | this.hbtn_Close.Font = new System.Drawing.Font("Bahnschrift Light", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 134 | this.hbtn_Close.HoverBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(232)))), ((int)(((byte)(17)))), ((int)(((byte)(35))))); 135 | this.hbtn_Close.HoverForeColor = System.Drawing.Color.White; 136 | this.hbtn_Close.Location = new System.Drawing.Point(217, 3); 137 | this.hbtn_Close.Name = "hbtn_Close"; 138 | this.hbtn_Close.Size = new System.Drawing.Size(40, 32); 139 | this.hbtn_Close.TabIndex = 0; 140 | this.hbtn_Close.Text = "✕"; 141 | this.hbtn_Close.UseVisualStyleBackColor = true; 142 | this.hbtn_Close.Click += new System.EventHandler(this.Hbtn_Close_Click); 143 | // 144 | // hbtn_Options 145 | // 146 | this.hbtn_Options.Dock = System.Windows.Forms.DockStyle.Right; 147 | this.hbtn_Options.FlatAppearance.BorderSize = 0; 148 | this.hbtn_Options.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 149 | this.hbtn_Options.Font = new System.Drawing.Font("Bahnschrift Light", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 150 | this.hbtn_Options.HoverBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); 151 | this.hbtn_Options.HoverForeColor = System.Drawing.Color.Empty; 152 | this.hbtn_Options.Location = new System.Drawing.Point(3, 3); 153 | this.hbtn_Options.Name = "hbtn_Options"; 154 | this.hbtn_Options.Size = new System.Drawing.Size(40, 32); 155 | this.hbtn_Options.TabIndex = 3; 156 | this.hbtn_Options.Text = "⚙"; 157 | this.hbtn_Options.UseVisualStyleBackColor = true; 158 | this.hbtn_Options.Click += new System.EventHandler(this.Hbtn_Options_Click); 159 | // 160 | // hbtn_Maximize 161 | // 162 | this.hbtn_Maximize.Dock = System.Windows.Forms.DockStyle.Right; 163 | this.hbtn_Maximize.FlatAppearance.BorderSize = 0; 164 | this.hbtn_Maximize.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 165 | this.hbtn_Maximize.Font = new System.Drawing.Font("Bahnschrift Light", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 166 | this.hbtn_Maximize.HoverBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); 167 | this.hbtn_Maximize.HoverForeColor = System.Drawing.Color.Empty; 168 | this.hbtn_Maximize.Location = new System.Drawing.Point(171, 3); 169 | this.hbtn_Maximize.Name = "hbtn_Maximize"; 170 | this.hbtn_Maximize.Size = new System.Drawing.Size(40, 32); 171 | this.hbtn_Maximize.TabIndex = 1; 172 | this.hbtn_Maximize.Text = "▢"; 173 | this.hbtn_Maximize.UseVisualStyleBackColor = true; 174 | this.hbtn_Maximize.Click += new System.EventHandler(this.Hbtn_Maximize_Click); 175 | // 176 | // cpy_right 177 | // 178 | this.cpy_right.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 179 | this.cpy_right.AutoSize = true; 180 | this.cpy_right.Font = new System.Drawing.Font("Segoe UI Light", 8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 181 | this.cpy_right.ForeColor = System.Drawing.SystemColors.ButtonFace; 182 | this.cpy_right.Location = new System.Drawing.Point(9, 581); 183 | this.cpy_right.Name = "cpy_right"; 184 | this.cpy_right.Size = new System.Drawing.Size(230, 13); 185 | this.cpy_right.TabIndex = 5; 186 | this.cpy_right.Text = "© 2021 - Tech Penguin INC. All Rights Reserved"; 187 | // 188 | // pnl_MainArea 189 | // 190 | this.pnl_MainArea.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 191 | this.pnl_MainArea.Controls.Add(this.panel1); 192 | this.pnl_MainArea.Controls.Add(this.flpnl_Modpacks); 193 | this.pnl_MainArea.Dock = System.Windows.Forms.DockStyle.Fill; 194 | this.pnl_MainArea.Location = new System.Drawing.Point(0, 40); 195 | this.pnl_MainArea.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4); 196 | this.pnl_MainArea.Name = "pnl_MainArea"; 197 | this.pnl_MainArea.Size = new System.Drawing.Size(1082, 604); 198 | this.pnl_MainArea.TabIndex = 4; 199 | // 200 | // panel1 201 | // 202 | this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); 203 | this.panel1.Controls.Add(this.hoverButton1); 204 | this.panel1.Controls.Add(this.hbtn_CreateModpack); 205 | this.panel1.Controls.Add(this.cpy_right); 206 | this.panel1.Dock = System.Windows.Forms.DockStyle.Right; 207 | this.panel1.Location = new System.Drawing.Point(830, 0); 208 | this.panel1.Name = "panel1"; 209 | this.panel1.Size = new System.Drawing.Size(250, 602); 210 | this.panel1.TabIndex = 2; 211 | // 212 | // hbtn_CreateModpack 213 | // 214 | this.hbtn_CreateModpack.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); 215 | this.hbtn_CreateModpack.FlatAppearance.BorderSize = 0; 216 | this.hbtn_CreateModpack.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 217 | this.hbtn_CreateModpack.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 218 | this.hbtn_CreateModpack.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); 219 | this.hbtn_CreateModpack.HoverBackColor = System.Drawing.SystemColors.WindowFrame; 220 | this.hbtn_CreateModpack.HoverForeColor = System.Drawing.Color.Empty; 221 | this.hbtn_CreateModpack.Location = new System.Drawing.Point(27, 19); 222 | this.hbtn_CreateModpack.Name = "hbtn_CreateModpack"; 223 | this.hbtn_CreateModpack.Size = new System.Drawing.Size(196, 59); 224 | this.hbtn_CreateModpack.TabIndex = 0; 225 | this.hbtn_CreateModpack.Text = "+ ADD MODPACK"; 226 | this.hbtn_CreateModpack.UseVisualStyleBackColor = false; 227 | this.hbtn_CreateModpack.Click += new System.EventHandler(this.Hbtn_CreateModpack_Click); 228 | // 229 | // flpnl_Modpacks 230 | // 231 | this.flpnl_Modpacks.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 232 | | System.Windows.Forms.AnchorStyles.Left))); 233 | this.flpnl_Modpacks.Location = new System.Drawing.Point(-1, -1); 234 | this.flpnl_Modpacks.Name = "flpnl_Modpacks"; 235 | this.flpnl_Modpacks.Padding = new System.Windows.Forms.Padding(10); 236 | this.flpnl_Modpacks.Size = new System.Drawing.Size(819, 542); 237 | this.flpnl_Modpacks.TabIndex = 1; 238 | // 239 | // hoverButton1 240 | // 241 | this.hoverButton1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); 242 | this.hoverButton1.FlatAppearance.BorderSize = 0; 243 | this.hoverButton1.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 244 | this.hoverButton1.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 245 | this.hoverButton1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); 246 | this.hoverButton1.HoverBackColor = System.Drawing.SystemColors.WindowFrame; 247 | this.hoverButton1.HoverForeColor = System.Drawing.Color.Empty; 248 | this.hoverButton1.Location = new System.Drawing.Point(27, 111); 249 | this.hoverButton1.Name = "hoverButton1"; 250 | this.hoverButton1.Size = new System.Drawing.Size(196, 59); 251 | this.hoverButton1.TabIndex = 6; 252 | this.hoverButton1.Text = "Settings"; 253 | this.hoverButton1.UseVisualStyleBackColor = false; 254 | // 255 | // HyperMcView 256 | // 257 | this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 18F); 258 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 259 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(48)))), ((int)(((byte)(43)))), ((int)(((byte)(39))))); 260 | this.ClientSize = new System.Drawing.Size(1082, 644); 261 | this.Controls.Add(this.pnl_MainArea); 262 | this.Controls.Add(this.dpnl_Top); 263 | this.Font = new System.Drawing.Font("Bahnschrift SemiBold", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point); 264 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 265 | this.Margin = new System.Windows.Forms.Padding(5, 4, 5, 4); 266 | this.Name = "HyperMcView"; 267 | this.Text = "HyperMC"; 268 | this.Load += new System.EventHandler(this.HyperMcView_Load); 269 | this.dpnl_Top.ResumeLayout(false); 270 | this.dpnl_Top.PerformLayout(); 271 | ((System.ComponentModel.ISupportInitialize)(this.pcb_Icon)).EndInit(); 272 | this.tlpnl_TopButtons.ResumeLayout(false); 273 | this.pnl_MainArea.ResumeLayout(false); 274 | this.panel1.ResumeLayout(false); 275 | this.panel1.PerformLayout(); 276 | this.ResumeLayout(false); 277 | 278 | } 279 | 280 | #endregion 281 | private UI.Components.DraggablePanel dpnl_Top; 282 | private System.Windows.Forms.Panel pnl_MainArea; 283 | private UI.Components.HoverButton hbtn_Minimize; 284 | private UI.Components.HoverButton hbtn_Maximize; 285 | private UI.Components.HoverButton hbtn_Close; 286 | private UI.Components.HoverButton hbtn_Options; 287 | private System.Windows.Forms.TableLayoutPanel tlpnl_TopButtons; 288 | private System.Windows.Forms.FlowLayoutPanel flpnl_Modpacks; 289 | private UI.Components.HoverButton hbtn_CreateModpack; 290 | private System.Windows.Forms.PictureBox pcb_Icon; 291 | private System.Windows.Forms.Label label1; 292 | private System.Windows.Forms.Label cpy_right; 293 | private System.Windows.Forms.Panel panel1; 294 | private UI.Components.HoverButton hoverButton1; 295 | } 296 | } 297 | 298 | -------------------------------------------------------------------------------- /src/HyperMC/HyperMcView.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Collections.ObjectModel; 4 | using System.Collections.Specialized; 5 | using System.ComponentModel; 6 | using System.Data; 7 | using System.Diagnostics; 8 | using System.Drawing; 9 | using System.Linq; 10 | using System.Text; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | using Hypermc.Data; 14 | using Hypermc.Services; 15 | using Hypermc.Settings; 16 | using Hypermc.UI.Dialogs; 17 | using Hypermc.UI.UserControls; 18 | using Hypermc.UI.Views; 19 | using Hypermc.Utility; 20 | using HyperMC.CurseForge; 21 | using Microsoft.Extensions.DependencyInjection; 22 | 23 | namespace Hypermc 24 | { 25 | public partial class HyperMcView : Form, IViewHost 26 | { 27 | 28 | private readonly IForgeClient _forgeClient; 29 | private readonly IDataAccess _dataAccess; 30 | private readonly IUserSettings _settings; 31 | private readonly SettingView _settingView; 32 | 33 | public HyperMcView(IForgeClient forgeClient, IDataAccess dataAccess, IUserSettings settings, SettingView settingView) 34 | { 35 | InitializeComponent(); 36 | 37 | _forgeClient = forgeClient; 38 | _dataAccess = dataAccess; 39 | _settings = settings; 40 | _settingView = settingView; 41 | 42 | _modpacks = new(); 43 | _modpacks.CollectionChanged += ModpacksUpdated; 44 | } 45 | 46 | private async void HyperMcView_Load(object sender, EventArgs e) 47 | { 48 | SetView(new ControlView(pnl_MainArea)); 49 | var mods = await _dataAccess.LoadData(_settings.ModPacksFile); 50 | if (mods != null) 51 | { 52 | foreach (var mod in mods) 53 | { 54 | _modpacks.Add(mod); 55 | } 56 | } 57 | } 58 | 59 | #region Default View 60 | 61 | #region Create Modpack Button 62 | 63 | private void Hbtn_CreateModpack_Click(object sender, EventArgs e) 64 | { 65 | CreateModpackDialog dialog = new(_forgeClient); 66 | DialogResult result = dialog.ShowDialog(this); 67 | if (result == DialogResult.OK) 68 | { 69 | _modpacks.Add(dialog.Data); 70 | } 71 | } 72 | 73 | #endregion Create Modpack Button 74 | 75 | #region Modpack List 76 | 77 | private ObservableCollection _modpacks; 78 | 79 | private async void ModpacksUpdated(object? sender, NotifyCollectionChangedEventArgs e) 80 | { 81 | switch (e.Action) 82 | { 83 | case NotifyCollectionChangedAction.Add: 84 | { 85 | foreach (ModpackData item in e.NewItems) 86 | { 87 | flpnl_Modpacks.Controls.Add(CreateModpackBox(item)); 88 | } 89 | 90 | break; 91 | } 92 | 93 | case NotifyCollectionChangedAction.Remove: 94 | { 95 | foreach (ModpackData item in e.OldItems) 96 | { 97 | flpnl_Modpacks.Controls.RemoveByKey(item.Name); 98 | } 99 | 100 | break; 101 | } 102 | 103 | case NotifyCollectionChangedAction.Replace: 104 | { 105 | foreach (ModpackData item in e.NewItems) 106 | { 107 | flpnl_Modpacks.Controls.Add(CreateModpackBox(item)); 108 | } 109 | foreach (ModpackData item in e.OldItems) 110 | { 111 | flpnl_Modpacks.Controls.RemoveByKey(item.Name); 112 | } 113 | 114 | break; 115 | } 116 | 117 | case NotifyCollectionChangedAction.Reset: 118 | { 119 | flpnl_Modpacks.Controls.Clear(); 120 | foreach (ModpackData item in _modpacks) 121 | { 122 | flpnl_Modpacks.Controls.Add(CreateModpackBox(item)); 123 | } 124 | 125 | break; 126 | } 127 | } 128 | 129 | SortModpacks(); 130 | await _dataAccess.SaveData(_settings.ModPacksFile, _modpacks.ToArray()); 131 | } 132 | 133 | private ModpackBox CreateModpackBox(ModpackData data) 134 | { 135 | Image thumbnail; 136 | if (string.IsNullOrWhiteSpace(data.Thumbnail)) 137 | { 138 | thumbnail = Properties.Resources.DefaultModpackImage; 139 | } 140 | else 141 | { 142 | // May need to be changed depending on how the image will be set 143 | thumbnail = Image.FromStream(_forgeClient.GetImageFromURL(data.Thumbnail).GetAwaiter().GetResult()); 144 | } 145 | 146 | return new() 147 | { 148 | Thumbnail = thumbnail, 149 | SizeMode = PictureBoxSizeMode.StretchImage, 150 | Name = data.Name, 151 | Tag = data.Path 152 | }; 153 | } 154 | 155 | private void SortModpacks() 156 | { 157 | // Questionable 158 | lock (flpnl_Modpacks.Controls) 159 | { 160 | Control[] controls = Utils.PopChildControls(flpnl_Modpacks); 161 | flpnl_Modpacks.Controls.AddRange(controls.OrderBy(x => x.Name).ToArray()); 162 | } 163 | } 164 | 165 | #endregion Modpack List 166 | 167 | #endregion Default View 168 | 169 | #region Top Panel 170 | 171 | #region Buttons 172 | 173 | #region Close Button 174 | 175 | private void Hbtn_Close_Click(object sender, EventArgs e) 176 | { 177 | Close(); 178 | } 179 | 180 | #endregion Close Button 181 | 182 | #region Maximize Button 183 | 184 | private void Hbtn_Maximize_Click(object sender, EventArgs e) 185 | { 186 | if (WindowState == FormWindowState.Maximized) 187 | { 188 | WindowState = FormWindowState.Normal; 189 | hbtn_Maximize.Text = "\u25A2"; // ▢ 190 | } 191 | else 192 | { 193 | WindowState = FormWindowState.Maximized; 194 | hbtn_Maximize.Text = "\u25F1"; // ◱ 195 | } 196 | } 197 | 198 | #endregion Maximize Button 199 | 200 | #region Minimize Button 201 | 202 | private void Hbtn_Minimize_Click(object sender, EventArgs e) 203 | { 204 | WindowState = FormWindowState.Minimized; 205 | } 206 | 207 | #endregion Minimize Button 208 | 209 | #region Options Button 210 | 211 | private void Hbtn_Options_Click(object sender, EventArgs e) 212 | { 213 | //Utils.NotImplAlert("Options Menu"); 214 | SetView(_settingView); 215 | } 216 | 217 | #endregion Minimize Button 218 | 219 | #endregion Buttons 220 | 221 | #endregion Top Panel 222 | 223 | #region View Hosting 224 | 225 | private IView? _view; 226 | private IView? _viewPrev; 227 | 228 | public void SetView(IView view, object? data = null) 229 | { 230 | if (_view is not null) 231 | { 232 | if (_view.GetType() != view.GetType()) 233 | { 234 | _view.HideView(Utils.PopChildControls(pnl_MainArea)); 235 | _view.OnMessage -= View_OnMessage; 236 | _viewPrev = _view; 237 | } 238 | } 239 | 240 | view.OnMessage += View_OnMessage; 241 | 242 | _view = view; 243 | Control[] controls = view.ShowView(data); 244 | pnl_MainArea.Controls.AddRange(controls); 245 | } 246 | 247 | private void View_OnMessage(IView view, int message) 248 | { 249 | if (message == IView.MSG_GO_BACK && _viewPrev is not null) 250 | { 251 | SetView(_viewPrev, null); 252 | } 253 | } 254 | 255 | #endregion View Hosting 256 | } 257 | } 258 | -------------------------------------------------------------------------------- /src/HyperMC/HyperMcView.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | text/microsoft-resx 50 | 51 | 52 | 2.0 53 | 54 | 55 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 56 | 57 | 58 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 59 | 60 | -------------------------------------------------------------------------------- /src/HyperMC/Mod.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Hypermc; 7 | 8 | namespace Hypermc 9 | { 10 | public class Mod 11 | { 12 | public string Name { get; } 13 | 14 | public Mod(string name) 15 | { 16 | Name = name; 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /src/HyperMC/ModDownloadEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Hypermc 8 | { 9 | public class ModDownloadEventArgs : EventArgs 10 | { 11 | public Mod Mod { get; init; } 12 | public ModDownloadEventArgs(Mod mod) => Mod = mod; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/HyperMC/Program.cs: -------------------------------------------------------------------------------- 1 | using Hypermc.Services; 2 | using Hypermc.Settings; 3 | using Hypermc.UI.Views; 4 | using Microsoft.Extensions.Configuration; 5 | using Microsoft.Extensions.DependencyInjection; 6 | using Microsoft.Extensions.Hosting; 7 | using System; 8 | using System.Collections.Generic; 9 | using System.IO; 10 | using System.Linq; 11 | using System.Threading.Tasks; 12 | using System.Windows.Forms; 13 | 14 | namespace Hypermc 15 | { 16 | static class Program 17 | { 18 | /// 19 | /// The main entry point for the application. 20 | /// 21 | [STAThread] 22 | static async Task Main() 23 | { 24 | var host = Host.CreateDefaultBuilder() 25 | .ConfigureAppConfiguration(builder => 26 | { 27 | builder.SetBasePath(Directory.GetCurrentDirectory()) 28 | .AddJsonFile("appsettings.json", optional: false, reloadOnChange: true) 29 | .AddJsonFile($"appsettings.{ Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT") ?? "Production" }.json", optional: true) 30 | .AddEnvironmentVariables(); 31 | }) 32 | .ConfigureServices((context, services) => 33 | { 34 | ConfigureServices(services); 35 | }) 36 | .Build(); 37 | 38 | await host.Services.GetRequiredService().Initialize(); 39 | 40 | Application.SetHighDpiMode(HighDpiMode.SystemAware); 41 | Application.EnableVisualStyles(); 42 | Application.SetCompatibleTextRenderingDefault(false); 43 | Application.Run(host.Services.GetRequiredService()); 44 | } 45 | 46 | private static void ConfigureServices(IServiceCollection services) 47 | { 48 | services.AddSingleton() 49 | .AddSingleton(); 50 | 51 | services.AddTransient() 52 | .AddTransient(); 53 | 54 | services.AddForgeClient(); 55 | } 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /src/HyperMC/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace Hypermc.Properties { 12 | using System; 13 | 14 | 15 | /// 16 | /// A strongly-typed resource class, for looking up localized strings, etc. 17 | /// 18 | // This class was auto-generated by the StronglyTypedResourceBuilder 19 | // class via a tool like ResGen or Visual Studio. 20 | // To add or remove a member, edit your .ResX file then rerun ResGen 21 | // with the /str option, or rebuild your VS project. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() { 33 | } 34 | 35 | /// 36 | /// Returns the cached ResourceManager instance used by this class. 37 | /// 38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 39 | internal static global::System.Resources.ResourceManager ResourceManager { 40 | get { 41 | if (object.ReferenceEquals(resourceMan, null)) { 42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Hypermc.Properties.Resources", typeof(Resources).Assembly); 43 | resourceMan = temp; 44 | } 45 | return resourceMan; 46 | } 47 | } 48 | 49 | /// 50 | /// Overrides the current thread's CurrentUICulture property for all 51 | /// resource lookups using this strongly typed resource class. 52 | /// 53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 54 | internal static global::System.Globalization.CultureInfo Culture { 55 | get { 56 | return resourceCulture; 57 | } 58 | set { 59 | resourceCulture = value; 60 | } 61 | } 62 | 63 | /// 64 | /// Looks up a localized resource of type System.Drawing.Bitmap. 65 | /// 66 | internal static System.Drawing.Bitmap DefaultModpackImage { 67 | get { 68 | object obj = ResourceManager.GetObject("DefaultModpackImage", resourceCulture); 69 | return ((System.Drawing.Bitmap)(obj)); 70 | } 71 | } 72 | 73 | /// 74 | /// Looks up a localized resource of type System.Drawing.Bitmap. 75 | /// 76 | internal static System.Drawing.Bitmap HyperMc256 { 77 | get { 78 | object obj = ResourceManager.GetObject("HyperMc256", resourceCulture); 79 | return ((System.Drawing.Bitmap)(obj)); 80 | } 81 | } 82 | 83 | /// 84 | /// Looks up a localized resource of type System.Drawing.Bitmap. 85 | /// 86 | internal static System.Drawing.Bitmap HyperMc32 { 87 | get { 88 | object obj = ResourceManager.GetObject("HyperMc32", resourceCulture); 89 | return ((System.Drawing.Bitmap)(obj)); 90 | } 91 | } 92 | 93 | /// 94 | /// Looks up a localized resource of type System.Drawing.Bitmap. 95 | /// 96 | internal static System.Drawing.Bitmap testImg { 97 | get { 98 | object obj = ResourceManager.GetObject("testImg", resourceCulture); 99 | return ((System.Drawing.Bitmap)(obj)); 100 | } 101 | } 102 | } 103 | } 104 | -------------------------------------------------------------------------------- /src/HyperMC/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | text/microsoft-resx 110 | 111 | 112 | 2.0 113 | 114 | 115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | 118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 119 | 120 | 121 | 122 | ..\Resources\DefaultModpackImage.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a 123 | 124 | 125 | ..\Resources\logo.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a 126 | 127 | 128 | ..\Resources\HyperMc32x32.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a 129 | 130 | 131 | ..\Resources\testImg.jpg;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a 132 | 133 | -------------------------------------------------------------------------------- /src/HyperMC/Resources/DefaultModpackImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TechPenguineer/Hypermc/c32ccf824f1afdc29cd6e0e78242e7dd79e12f57/src/HyperMC/Resources/DefaultModpackImage.png -------------------------------------------------------------------------------- /src/HyperMC/Resources/HyperMc32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TechPenguineer/Hypermc/c32ccf824f1afdc29cd6e0e78242e7dd79e12f57/src/HyperMC/Resources/HyperMc32x32.png -------------------------------------------------------------------------------- /src/HyperMC/Resources/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TechPenguineer/Hypermc/c32ccf824f1afdc29cd6e0e78242e7dd79e12f57/src/HyperMC/Resources/logo.png -------------------------------------------------------------------------------- /src/HyperMC/Resources/testImg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TechPenguineer/Hypermc/c32ccf824f1afdc29cd6e0e78242e7dd79e12f57/src/HyperMC/Resources/testImg.jpg -------------------------------------------------------------------------------- /src/HyperMC/Services/FileDataAccess.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Text.Json; 7 | using System.Threading.Tasks; 8 | 9 | namespace Hypermc.Services 10 | { 11 | public class FileDataAccess : IDataAccess 12 | { 13 | public async Task LoadData(string fileOrQuery, U parameters = default(U), string connectionStringName = null) 14 | { 15 | if (File.Exists(fileOrQuery)) 16 | { 17 | using var stream = new FileStream(fileOrQuery, FileMode.Open, FileAccess.Read); 18 | var settings = await JsonSerializer.DeserializeAsync(stream); 19 | return settings; 20 | } 21 | 22 | return default(O); 23 | } 24 | 25 | public async Task SaveData(string fileOrQuery, T parametersOrData, string connectionStringName = null) 26 | { 27 | string settingsToSave = JsonSerializer.Serialize(parametersOrData); 28 | await File.WriteAllTextAsync(fileOrQuery, settingsToSave); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/HyperMC/Services/IDataAccess.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Hypermc.Services 8 | { 9 | public interface IDataAccess 10 | { 11 | /// 12 | /// Loads data from a file or database 13 | /// 14 | /// The input type for the data that you want to be loaded 15 | /// The type of the data that is being passed in to be saved 16 | /// The return type 17 | /// The file name or query string to run 18 | /// The data to query the database on (can be ignored when using file based data) 19 | /// The connection string name for the database (can be ignored when using file based data) 20 | /// 21 | Task LoadData(string fileOrQuery, U parameters = default(U), string connectionStringName = null); 22 | 23 | /// 24 | /// Saves data to a file or database 25 | /// 26 | /// The data type that is being passed in 27 | /// The file name or query string to run 28 | /// The data to be saved to the file or database 29 | /// The connection string name for the database (can be ignored when using file based data) 30 | /// 31 | Task SaveData(string fileOrQuery, T parametersOrData = default(T), string connectionStringName = null); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/HyperMC/Settings/ApplicationSettings.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Hypermc.Settings 8 | { 9 | public class ApplicationSettings 10 | { 11 | public string AppPath { get; set; } 12 | public string DeafultMinecraftPath { get; set; } 13 | public string ModPacksFile { get; set; } 14 | public string DefaultModPacksPath { get; set; } 15 | public string SettingsFile { get; set; } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/HyperMC/Settings/IUserSettings.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Hypermc.Settings 8 | { 9 | public interface IUserSettings 10 | { 11 | string MinecraftPath { get; } 12 | string ModPacksPath { get; } 13 | string ModPacksFile { get; } 14 | 15 | Task Initialize(); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/HyperMC/Settings/UserSettings.cs: -------------------------------------------------------------------------------- 1 | using Hypermc.Services; 2 | using Microsoft.Extensions.Configuration; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.IO; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Text.Json; 9 | using System.Threading.Tasks; 10 | using System.Windows.Forms; 11 | 12 | namespace Hypermc.Settings 13 | { 14 | public class UserSettings : IUserSettings 15 | { 16 | private readonly string _appPath; 17 | private readonly string _settingsFile; 18 | private readonly IDataAccess _dataAccess; 19 | 20 | public string MinecraftPath { get; private set; } 21 | public string ModPacksPath { get; private set; } 22 | public string ModPacksFile { get; } 23 | 24 | public UserSettings(IDataAccess dataAccess, IConfiguration config) 25 | { 26 | var settings = config.GetSection(nameof(ApplicationSettings)).Get(); 27 | _appPath = string.Format(settings.AppPath, Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)); 28 | _settingsFile = string.Format(settings.SettingsFile, _appPath); 29 | 30 | _dataAccess = dataAccess; 31 | 32 | MinecraftPath = string.Format(settings.DeafultMinecraftPath, Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)); 33 | ModPacksPath = string.Format(settings.DefaultModPacksPath, MinecraftPath); 34 | ModPacksFile = string.Format(settings.ModPacksFile, ModPacksPath); 35 | } 36 | 37 | public async Task Initialize() 38 | { 39 | if (!Directory.Exists(_appPath)) 40 | { 41 | Directory.CreateDirectory(_appPath); 42 | } 43 | 44 | if (!Directory.Exists(ModPacksPath)) 45 | { 46 | Directory.CreateDirectory(ModPacksPath); 47 | } 48 | 49 | var settings = await _dataAccess.LoadData(_settingsFile); 50 | 51 | if (settings != null) 52 | { 53 | MinecraftPath = settings.MinecraftPath; 54 | ModPacksPath = settings.ModPacksPath; 55 | } 56 | } 57 | 58 | public async Task UpdateSettings(string mcPath, string modPath) 59 | { 60 | MinecraftPath = mcPath; 61 | ModPacksPath = modPath; 62 | 63 | await _dataAccess.SaveData(_settingsFile, this); 64 | } 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Components/DraggablePanel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Drawing; 5 | using System.Linq; 6 | using System.Text; 7 | using System.Threading.Tasks; 8 | using System.Windows.Forms; 9 | using Hypermc.Utility; 10 | 11 | namespace Hypermc.UI.Components 12 | { 13 | public class DraggablePanel : Panel 14 | { 15 | [Browsable(false)] 16 | public bool IsDragging { get; private set; } 17 | 18 | [Category("Behavior")] 19 | [DisplayName("Drag Control")] 20 | [Description("The control which's location will be updated (i.e. dragged)")] 21 | public Control? DragControl { get; set; } 22 | 23 | private Point _dragCursorOrigin; 24 | private Point _dragFormOrigin; 25 | 26 | protected override void OnMouseDown(MouseEventArgs e) 27 | { 28 | base.OnMouseDown(e); 29 | 30 | if (DragControl is not null) 31 | { 32 | IsDragging = true; 33 | _dragCursorOrigin = Cursor.Position; 34 | _dragFormOrigin = DragControl.Location; 35 | } 36 | } 37 | 38 | protected override void OnMouseMove(MouseEventArgs e) 39 | { 40 | base.OnMouseMove(e); 41 | 42 | if (IsDragging && DragControl is not null) 43 | { 44 | DragControl.Location = Utils.PointAdd(_dragFormOrigin, Utils.PointSub(Cursor.Position, _dragCursorOrigin)); 45 | } 46 | } 47 | 48 | protected override void OnMouseUp(MouseEventArgs e) 49 | { 50 | base.OnMouseUp(e); 51 | 52 | IsDragging = false; 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Components/HoverButton.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Diagnostics; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace Hypermc.UI.Components 12 | { 13 | public class HoverButton : Button 14 | { 15 | private Color? _beforeForeColor; 16 | private Color? _beforeBackColor; 17 | 18 | [Category("Appearance")] 19 | [DisplayName("Hover Background Color")] 20 | [Description("Changes the buttons background color to this when hovered on with cursor")] 21 | public Color HoverBackColor { get; set; } 22 | 23 | [Category("Appearance")] 24 | [DisplayName("Hover Foreground Color")] 25 | [Description("Changes the buttons foreground color to this when hovered on with cursor")] 26 | public Color HoverForeColor { get; set; } 27 | 28 | public HoverButton() 29 | { 30 | FlatStyle = FlatStyle.Flat; 31 | FlatAppearance.BorderSize = 0; 32 | } 33 | 34 | protected override void OnMouseEnter(EventArgs e) 35 | { 36 | base.OnMouseEnter(e); 37 | 38 | if (HoverForeColor != default) 39 | { 40 | _beforeForeColor = ForeColor; 41 | ForeColor = HoverForeColor; 42 | } 43 | 44 | if (HoverBackColor != default) 45 | { 46 | _beforeBackColor = BackColor; 47 | BackColor = HoverBackColor; 48 | } 49 | } 50 | 51 | protected override void OnMouseLeave(EventArgs e) 52 | { 53 | base.OnMouseLeave(e); 54 | 55 | if (_beforeForeColor.HasValue) 56 | { 57 | ForeColor = _beforeForeColor.Value; 58 | _beforeForeColor = null; 59 | } 60 | if (_beforeBackColor.HasValue) 61 | { 62 | BackColor = _beforeBackColor.Value; 63 | _beforeBackColor = null; 64 | } 65 | } 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Dialogs/CreateModpackDialog.Designer.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Hypermc.UI.Dialogs 3 | { 4 | partial class CreateModpackDialog 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.txb_Name = new System.Windows.Forms.TextBox(); 33 | this.pnl_AlignPanel = new System.Windows.Forms.Panel(); 34 | this.cmbx_FmlVersion = new System.Windows.Forms.ComboBox(); 35 | this.cmbx_McVersion = new System.Windows.Forms.ComboBox(); 36 | this.lbl_FmlVersion = new System.Windows.Forms.Label(); 37 | this.lbl_McVersion = new System.Windows.Forms.Label(); 38 | this.lbl_Name = new System.Windows.Forms.Label(); 39 | this.hbtn_Cancel = new Hypermc.UI.Components.HoverButton(); 40 | this.hbtn_Ok = new Hypermc.UI.Components.HoverButton(); 41 | this.lbl_Caption = new System.Windows.Forms.Label(); 42 | this.pnl_Top = new System.Windows.Forms.Panel(); 43 | this.cpy_right = new System.Windows.Forms.Label(); 44 | this.pnl_AlignPanel.SuspendLayout(); 45 | this.pnl_Top.SuspendLayout(); 46 | this.SuspendLayout(); 47 | // 48 | // txb_Name 49 | // 50 | this.txb_Name.Anchor = System.Windows.Forms.AnchorStyles.None; 51 | this.txb_Name.Font = new System.Drawing.Font("Segoe UI Light", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 52 | this.txb_Name.Location = new System.Drawing.Point(217, 136); 53 | this.txb_Name.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6); 54 | this.txb_Name.Name = "txb_Name"; 55 | this.txb_Name.Size = new System.Drawing.Size(331, 42); 56 | this.txb_Name.TabIndex = 0; 57 | // 58 | // pnl_AlignPanel 59 | // 60 | this.pnl_AlignPanel.BackColor = System.Drawing.Color.DimGray; 61 | this.pnl_AlignPanel.Controls.Add(this.cpy_right); 62 | this.pnl_AlignPanel.Controls.Add(this.cmbx_FmlVersion); 63 | this.pnl_AlignPanel.Controls.Add(this.cmbx_McVersion); 64 | this.pnl_AlignPanel.Controls.Add(this.lbl_FmlVersion); 65 | this.pnl_AlignPanel.Controls.Add(this.lbl_McVersion); 66 | this.pnl_AlignPanel.Controls.Add(this.lbl_Name); 67 | this.pnl_AlignPanel.Controls.Add(this.hbtn_Cancel); 68 | this.pnl_AlignPanel.Controls.Add(this.hbtn_Ok); 69 | this.pnl_AlignPanel.Controls.Add(this.txb_Name); 70 | this.pnl_AlignPanel.Dock = System.Windows.Forms.DockStyle.Fill; 71 | this.pnl_AlignPanel.Font = new System.Drawing.Font("Segoe UI Light", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 72 | this.pnl_AlignPanel.Location = new System.Drawing.Point(0, 0); 73 | this.pnl_AlignPanel.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6); 74 | this.pnl_AlignPanel.Name = "pnl_AlignPanel"; 75 | this.pnl_AlignPanel.Padding = new System.Windows.Forms.Padding(16, 0, 0, 0); 76 | this.pnl_AlignPanel.Size = new System.Drawing.Size(598, 430); 77 | this.pnl_AlignPanel.TabIndex = 1; 78 | // 79 | // cmbx_FmlVersion 80 | // 81 | this.cmbx_FmlVersion.Anchor = System.Windows.Forms.AnchorStyles.None; 82 | this.cmbx_FmlVersion.FormattingEnabled = true; 83 | this.cmbx_FmlVersion.Location = new System.Drawing.Point(217, 238); 84 | this.cmbx_FmlVersion.Name = "cmbx_FmlVersion"; 85 | this.cmbx_FmlVersion.Size = new System.Drawing.Size(331, 44); 86 | this.cmbx_FmlVersion.TabIndex = 3; 87 | // 88 | // cmbx_McVersion 89 | // 90 | this.cmbx_McVersion.Anchor = System.Windows.Forms.AnchorStyles.None; 91 | this.cmbx_McVersion.FormattingEnabled = true; 92 | this.cmbx_McVersion.Location = new System.Drawing.Point(217, 187); 93 | this.cmbx_McVersion.Name = "cmbx_McVersion"; 94 | this.cmbx_McVersion.Size = new System.Drawing.Size(331, 44); 95 | this.cmbx_McVersion.TabIndex = 3; 96 | this.cmbx_McVersion.SelectedIndexChanged += new System.EventHandler(this.cmbx_McVersion_SelectedIndexChanged); 97 | // 98 | // lbl_FmlVersion 99 | // 100 | this.lbl_FmlVersion.Anchor = System.Windows.Forms.AnchorStyles.None; 101 | this.lbl_FmlVersion.AutoSize = true; 102 | this.lbl_FmlVersion.Location = new System.Drawing.Point(0, 238); 103 | this.lbl_FmlVersion.Name = "lbl_FmlVersion"; 104 | this.lbl_FmlVersion.Size = new System.Drawing.Size(170, 37); 105 | this.lbl_FmlVersion.TabIndex = 2; 106 | this.lbl_FmlVersion.Text = "Forge Version"; 107 | // 108 | // lbl_McVersion 109 | // 110 | this.lbl_McVersion.Anchor = System.Windows.Forms.AnchorStyles.None; 111 | this.lbl_McVersion.AutoSize = true; 112 | this.lbl_McVersion.Location = new System.Drawing.Point(0, 190); 113 | this.lbl_McVersion.Name = "lbl_McVersion"; 114 | this.lbl_McVersion.Size = new System.Drawing.Size(211, 37); 115 | this.lbl_McVersion.TabIndex = 2; 116 | this.lbl_McVersion.Text = "Minecraft Version"; 117 | // 118 | // lbl_Name 119 | // 120 | this.lbl_Name.Anchor = System.Windows.Forms.AnchorStyles.None; 121 | this.lbl_Name.AutoSize = true; 122 | this.lbl_Name.Font = new System.Drawing.Font("Segoe UI Light", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 123 | this.lbl_Name.Location = new System.Drawing.Point(0, 139); 124 | this.lbl_Name.Name = "lbl_Name"; 125 | this.lbl_Name.Size = new System.Drawing.Size(196, 37); 126 | this.lbl_Name.TabIndex = 2; 127 | this.lbl_Name.Text = "Modpack Name"; 128 | // 129 | // hbtn_Cancel 130 | // 131 | this.hbtn_Cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 132 | this.hbtn_Cancel.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 133 | this.hbtn_Cancel.HoverBackColor = System.Drawing.Color.Empty; 134 | this.hbtn_Cancel.HoverForeColor = System.Drawing.Color.Empty; 135 | this.hbtn_Cancel.Location = new System.Drawing.Point(12, 376); 136 | this.hbtn_Cancel.Name = "hbtn_Cancel"; 137 | this.hbtn_Cancel.Size = new System.Drawing.Size(103, 42); 138 | this.hbtn_Cancel.TabIndex = 1; 139 | this.hbtn_Cancel.Text = "Cancel"; 140 | this.hbtn_Cancel.UseVisualStyleBackColor = true; 141 | this.hbtn_Cancel.Click += new System.EventHandler(this.Hbtn_Cancel_Click); 142 | // 143 | // hbtn_Ok 144 | // 145 | this.hbtn_Ok.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 146 | this.hbtn_Ok.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 147 | this.hbtn_Ok.HoverBackColor = System.Drawing.Color.Empty; 148 | this.hbtn_Ok.HoverForeColor = System.Drawing.Color.Empty; 149 | this.hbtn_Ok.Location = new System.Drawing.Point(483, 376); 150 | this.hbtn_Ok.Name = "hbtn_Ok"; 151 | this.hbtn_Ok.Size = new System.Drawing.Size(103, 42); 152 | this.hbtn_Ok.TabIndex = 1; 153 | this.hbtn_Ok.Text = "OK"; 154 | this.hbtn_Ok.UseVisualStyleBackColor = true; 155 | this.hbtn_Ok.Click += new System.EventHandler(this.Hbtn_Ok_Click); 156 | // 157 | // lbl_Caption 158 | // 159 | this.lbl_Caption.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 160 | | System.Windows.Forms.AnchorStyles.Right))); 161 | this.lbl_Caption.AutoSize = true; 162 | this.lbl_Caption.Font = new System.Drawing.Font("Segoe UI Semilight", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 163 | this.lbl_Caption.Location = new System.Drawing.Point(158, 9); 164 | this.lbl_Caption.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0); 165 | this.lbl_Caption.Name = "lbl_Caption"; 166 | this.lbl_Caption.Size = new System.Drawing.Size(290, 37); 167 | this.lbl_Caption.TabIndex = 1; 168 | this.lbl_Caption.Text = "Create a New Modpack"; 169 | // 170 | // pnl_Top 171 | // 172 | this.pnl_Top.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); 173 | this.pnl_Top.Controls.Add(this.lbl_Caption); 174 | this.pnl_Top.Dock = System.Windows.Forms.DockStyle.Top; 175 | this.pnl_Top.Font = new System.Drawing.Font("Segoe UI Semilight", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 176 | this.pnl_Top.Location = new System.Drawing.Point(0, 0); 177 | this.pnl_Top.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6); 178 | this.pnl_Top.Name = "pnl_Top"; 179 | this.pnl_Top.Size = new System.Drawing.Size(598, 53); 180 | this.pnl_Top.TabIndex = 2; 181 | // 182 | // cpy_right 183 | // 184 | this.cpy_right.AutoSize = true; 185 | this.cpy_right.Font = new System.Drawing.Font("Segoe UI Light", 8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 186 | this.cpy_right.ForeColor = System.Drawing.SystemColors.ControlDark; 187 | this.cpy_right.Location = new System.Drawing.Point(158, 402); 188 | this.cpy_right.Name = "cpy_right"; 189 | this.cpy_right.Size = new System.Drawing.Size(289, 19); 190 | this.cpy_right.TabIndex = 4; 191 | this.cpy_right.Text = "© 2021 - Tech Penguin INC. All Rights Reserved"; 192 | this.cpy_right.Click += new System.EventHandler(this.cpy_right_Click); 193 | // 194 | // CreateModpackDialog 195 | // 196 | this.AutoScaleDimensions = new System.Drawing.SizeF(14F, 36F); 197 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 198 | this.BackColor = System.Drawing.Color.DimGray; 199 | this.ClientSize = new System.Drawing.Size(598, 430); 200 | this.Controls.Add(this.pnl_Top); 201 | this.Controls.Add(this.pnl_AlignPanel); 202 | this.Font = new System.Drawing.Font("Segoe UI Light", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 203 | this.ForeColor = System.Drawing.Color.White; 204 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 205 | this.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6); 206 | this.Name = "CreateModpackDialog"; 207 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; 208 | this.Text = "CreateModpackDialog"; 209 | this.pnl_AlignPanel.ResumeLayout(false); 210 | this.pnl_AlignPanel.PerformLayout(); 211 | this.pnl_Top.ResumeLayout(false); 212 | this.pnl_Top.PerformLayout(); 213 | this.ResumeLayout(false); 214 | 215 | } 216 | 217 | #endregion 218 | 219 | private System.Windows.Forms.TextBox txb_Name; 220 | private System.Windows.Forms.Panel pnl_AlignPanel; 221 | private System.Windows.Forms.Label lbl_Name; 222 | private Components.HoverButton hbtn_Cancel; 223 | private Components.HoverButton hbtn_Ok; 224 | private System.Windows.Forms.Label lbl_Caption; 225 | private System.Windows.Forms.Panel pnl_Top; 226 | private System.Windows.Forms.ComboBox cmbx_FmlVersion; 227 | private System.Windows.Forms.ComboBox cmbx_McVersion; 228 | private System.Windows.Forms.Label lbl_FmlVersion; 229 | private System.Windows.Forms.Label lbl_McVersion; 230 | private System.Windows.Forms.Label cpy_right; 231 | } 232 | } -------------------------------------------------------------------------------- /src/HyperMC/UI/Dialogs/CreateModpackDialog.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using Hypermc.Data; 11 | using Hypermc.Utility; 12 | using HyperMC.CurseForge; 13 | 14 | namespace Hypermc.UI.Dialogs 15 | { 16 | public partial class CreateModpackDialog : Form 17 | { 18 | 19 | 20 | private readonly IForgeClient _forgeClient; 21 | 22 | public ModpackData? Data { get; private set; } 23 | public ModpackData? DataForge { get; private set; } 24 | 25 | 26 | public CreateModpackDialog(IForgeClient forgeClient) 27 | { 28 | InitializeComponent(); 29 | 30 | _forgeClient = forgeClient; 31 | Load += CreateModpackDialog_Load; 32 | 33 | List supported_versions; 34 | } 35 | 36 | private async void CreateModpackDialog_Load(object? sender, EventArgs e) 37 | { 38 | var versions = await _forgeClient.GetMinecraftVersions(); 39 | 40 | Console.WriteLine(versions); 41 | cmbx_McVersion.DataSource = versions; 42 | cmbx_McVersion.DisplayMember = "VersionString"; 43 | } 44 | 45 | 46 | 47 | 48 | 49 | private void Hbtn_Ok_Click(object sender, EventArgs e) 50 | { 51 | if (string.IsNullOrWhiteSpace(txb_Name.Text)) 52 | { 53 | MessageDialog.Exclaim("Please specify a modpack name", "Warning", owner: this); 54 | return; 55 | } 56 | if (string.IsNullOrWhiteSpace(cmbx_FmlVersion.Text)) 57 | { 58 | MessageDialog.Exclaim("Please specify a Forge version", "Warning", owner: this); 59 | return; 60 | } 61 | if (string.IsNullOrWhiteSpace(cmbx_McVersion.Text)) 62 | { 63 | MessageDialog.Exclaim("Please specify a Minecraft version", "Warning", owner: this); 64 | return; 65 | } 66 | 67 | Data = new ModpackData(txb_Name.Text, "", null); 68 | DataForge = new ModpackData(cmbx_FmlVersion.Text, "", null); 69 | DialogResult = DialogResult.OK; 70 | Close(); 71 | } 72 | 73 | private void Hbtn_Cancel_Click(object sender, EventArgs e) 74 | { 75 | DialogResult = DialogResult.Cancel; 76 | Close(); 77 | } 78 | 79 | private void cmbx_McVersion_SelectedIndexChanged(object sender, EventArgs e) 80 | { 81 | 82 | } 83 | 84 | private void cpy_right_Click(object sender, EventArgs e) 85 | { 86 | 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Dialogs/CreateModpackDialog.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | text/microsoft-resx 50 | 51 | 52 | 2.0 53 | 54 | 55 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 56 | 57 | 58 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 59 | 60 | -------------------------------------------------------------------------------- /src/HyperMC/UI/UserControls/ModpackBox.Designer.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Hypermc.UI.UserControls 3 | { 4 | partial class ModpackBox 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Component Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.pcb_Thumbnail = new System.Windows.Forms.PictureBox(); 33 | this.lbl_Name = new System.Windows.Forms.Label(); 34 | this.lbl_forge_version = new System.Windows.Forms.Label(); 35 | ((System.ComponentModel.ISupportInitialize)(this.pcb_Thumbnail)).BeginInit(); 36 | this.SuspendLayout(); 37 | // 38 | // pcb_Thumbnail 39 | // 40 | this.pcb_Thumbnail.Dock = System.Windows.Forms.DockStyle.Top; 41 | this.pcb_Thumbnail.Location = new System.Drawing.Point(0, 0); 42 | this.pcb_Thumbnail.Name = "pcb_Thumbnail"; 43 | this.pcb_Thumbnail.Size = new System.Drawing.Size(190, 100); 44 | this.pcb_Thumbnail.TabIndex = 0; 45 | this.pcb_Thumbnail.TabStop = false; 46 | this.pcb_Thumbnail.Click += new System.EventHandler(this.Pcb_Thumbnail_Click); 47 | // 48 | // lbl_Name 49 | // 50 | this.lbl_Name.Dock = System.Windows.Forms.DockStyle.Fill; 51 | this.lbl_Name.Font = new System.Drawing.Font("Segoe UI Semilight", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 52 | this.lbl_Name.ForeColor = System.Drawing.Color.White; 53 | this.lbl_Name.Location = new System.Drawing.Point(0, 100); 54 | this.lbl_Name.Name = "lbl_Name"; 55 | this.lbl_Name.Size = new System.Drawing.Size(190, 27); 56 | this.lbl_Name.TabIndex = 1; 57 | this.lbl_Name.Text = "#NAME"; 58 | this.lbl_Name.TextAlign = System.Drawing.ContentAlignment.BottomLeft; 59 | this.lbl_Name.Click += new System.EventHandler(this.lbl_Name_Click_1); 60 | // 61 | // lbl_forge_version 62 | // 63 | this.lbl_forge_version.AutoSize = true; 64 | this.lbl_forge_version.Font = new System.Drawing.Font("Segoe UI", 6F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 65 | this.lbl_forge_version.ForeColor = System.Drawing.SystemColors.ButtonHighlight; 66 | this.lbl_forge_version.Location = new System.Drawing.Point(3, 100); 67 | this.lbl_forge_version.Name = "lbl_forge_version"; 68 | this.lbl_forge_version.Size = new System.Drawing.Size(56, 11); 69 | this.lbl_forge_version.TabIndex = 2; 70 | this.lbl_forge_version.Text = "#MC VERSION"; 71 | // 72 | // ModpackBox 73 | // 74 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); 75 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 76 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); 77 | this.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 78 | this.Controls.Add(this.lbl_forge_version); 79 | this.Controls.Add(this.lbl_Name); 80 | this.Controls.Add(this.pcb_Thumbnail); 81 | this.Margin = new System.Windows.Forms.Padding(25, 25, 25, 25); 82 | this.Name = "ModpackBox"; 83 | this.Size = new System.Drawing.Size(190, 127); 84 | ((System.ComponentModel.ISupportInitialize)(this.pcb_Thumbnail)).EndInit(); 85 | this.ResumeLayout(false); 86 | this.PerformLayout(); 87 | 88 | } 89 | 90 | #endregion 91 | 92 | private System.Windows.Forms.PictureBox pcb_Thumbnail; 93 | private System.Windows.Forms.Label lbl_Name; 94 | private System.Windows.Forms.Label lbl_forge_version; 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /src/HyperMC/UI/UserControls/ModpackBox.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace Hypermc.UI.UserControls 12 | { 13 | public partial class ModpackBox : UserControl 14 | { 15 | [Category("Appearance")] 16 | [DisplayName("Modpack Thumbnail")] 17 | [Description("The image to display")] 18 | public Image Thumbnail { get => pcb_Thumbnail.Image; set => pcb_Thumbnail.Image = value; } 19 | 20 | [Category("Appearance")] 21 | [DisplayName("Thumbnail Size Mode")] 22 | [Description("How to display the image")] 23 | public PictureBoxSizeMode SizeMode { get => pcb_Thumbnail.SizeMode; set => pcb_Thumbnail.SizeMode = value; } 24 | 25 | [Browsable(false)] 26 | new public string Name { 27 | get { 28 | return base.Name; 29 | } 30 | set { 31 | base.Name = value; 32 | lbl_Name.Text = value; 33 | lbl_forge_version.Text = $"Forge Version: "; 34 | } 35 | } 36 | 37 | /*[Category("Appearance")] 38 | [DisplayName("Modpack Name")] 39 | [Description("The name of the modpack")] 40 | public string? ModpackName { get; set; }*/ 41 | 42 | public ModpackBox() 43 | { 44 | InitializeComponent(); 45 | } 46 | 47 | private void Pcb_Thumbnail_Click(object sender, EventArgs e) 48 | { 49 | OnClick(e); 50 | } 51 | 52 | private void lbl_Name_Click(object sender, EventArgs e) 53 | { 54 | 55 | } 56 | 57 | private void lbl_Name_Click_1(object sender, EventArgs e) 58 | { 59 | 60 | } 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /src/HyperMC/UI/UserControls/ModpackBox.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | text/microsoft-resx 50 | 51 | 52 | 2.0 53 | 54 | 55 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 56 | 57 | 58 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 59 | 60 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/ControlView.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Forms; 7 | using Hypermc.Utility; 8 | 9 | namespace Hypermc.UI.Views 10 | { 11 | public sealed class ControlView : IView 12 | { 13 | private Control[] _controls; 14 | 15 | public ControlView(Control control) 16 | { 17 | _controls = Utils.PopChildControls(control); 18 | } 19 | 20 | public event IView.ViewMessageCallback OnMessage; 21 | 22 | public Control[] ShowView(object? data = null) 23 | { 24 | SendMessage(IView.MSG_SHOW); 25 | return _controls; 26 | } 27 | 28 | public bool HideView(Control[] controls) 29 | { 30 | _controls = controls; 31 | SendMessage(IView.MSG_HIDE); 32 | return false; 33 | } 34 | 35 | public void DestroyView() 36 | { 37 | } 38 | 39 | private void SendMessage(int msg) 40 | { 41 | OnMessage?.Invoke(this, msg); 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/IView.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Threading.Tasks; 7 | using System.Windows.Forms; 8 | 9 | namespace Hypermc.UI.Views 10 | { 11 | public interface IView 12 | { 13 | public const int MSG_SHOW = 0x0; 14 | public const int MSG_HIDE = 0x1; 15 | public const int MSG_DESTROY = 0x2; 16 | public const int MSG_GO_BACK = 0x3; 17 | 18 | public Control[] ShowView(object? data = null); 19 | public bool HideView(Control[] controls); 20 | public void DestroyView(); 21 | 22 | public event ViewMessageCallback OnMessage; 23 | 24 | public delegate void ViewMessageCallback(IView view, int message); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/IViewHost.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace Hypermc.UI.Views 8 | { 9 | public interface IViewHost 10 | { 11 | public void SetView(IView view, object? data = null); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/SettingView.Designer.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Hypermc.UI.Views 3 | { 4 | partial class SettingView 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | this.pnl_AlignPanel = new System.Windows.Forms.Panel(); 33 | this.label5 = new System.Windows.Forms.Label(); 34 | this.checkBox2 = new System.Windows.Forms.CheckBox(); 35 | this.label4 = new System.Windows.Forms.Label(); 36 | this.checkBox1 = new System.Windows.Forms.CheckBox(); 37 | this.label1 = new System.Windows.Forms.Label(); 38 | this.textBox2 = new System.Windows.Forms.TextBox(); 39 | this.label3 = new System.Windows.Forms.Label(); 40 | this.modPackPath = new System.Windows.Forms.TextBox(); 41 | this.label2 = new System.Windows.Forms.Label(); 42 | this.game_path = new System.Windows.Forms.TextBox(); 43 | this.panel1 = new System.Windows.Forms.Panel(); 44 | this.hbtn_Back = new Hypermc.UI.Components.HoverButton(); 45 | this.lbl_Options = new System.Windows.Forms.Label(); 46 | this.pnl_AlignPanel.SuspendLayout(); 47 | this.SuspendLayout(); 48 | // 49 | // pnl_AlignPanel 50 | // 51 | this.pnl_AlignPanel.BackColor = System.Drawing.Color.White; 52 | this.pnl_AlignPanel.Controls.Add(this.label5); 53 | this.pnl_AlignPanel.Controls.Add(this.checkBox2); 54 | this.pnl_AlignPanel.Controls.Add(this.label4); 55 | this.pnl_AlignPanel.Controls.Add(this.checkBox1); 56 | this.pnl_AlignPanel.Controls.Add(this.label1); 57 | this.pnl_AlignPanel.Controls.Add(this.textBox2); 58 | this.pnl_AlignPanel.Controls.Add(this.label3); 59 | this.pnl_AlignPanel.Controls.Add(this.modPackPath); 60 | this.pnl_AlignPanel.Controls.Add(this.label2); 61 | this.pnl_AlignPanel.Controls.Add(this.game_path); 62 | this.pnl_AlignPanel.Controls.Add(this.panel1); 63 | this.pnl_AlignPanel.Controls.Add(this.hbtn_Back); 64 | this.pnl_AlignPanel.Controls.Add(this.lbl_Options); 65 | this.pnl_AlignPanel.Dock = System.Windows.Forms.DockStyle.Fill; 66 | this.pnl_AlignPanel.Location = new System.Drawing.Point(0, 0); 67 | this.pnl_AlignPanel.Name = "pnl_AlignPanel"; 68 | this.pnl_AlignPanel.Size = new System.Drawing.Size(1082, 612); 69 | this.pnl_AlignPanel.TabIndex = 0; 70 | this.pnl_AlignPanel.Paint += new System.Windows.Forms.PaintEventHandler(this.pnl_AlignPanel_Paint); 71 | // 72 | // label5 73 | // 74 | this.label5.AutoSize = true; 75 | this.label5.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 76 | this.label5.Location = new System.Drawing.Point(88, 270); 77 | this.label5.Name = "label5"; 78 | this.label5.Size = new System.Drawing.Size(290, 29); 79 | this.label5.TabIndex = 13; 80 | this.label5.Text = "Recieve Desktop Notifications"; 81 | this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 82 | // 83 | // checkBox2 84 | // 85 | this.checkBox2.AutoSize = true; 86 | this.checkBox2.Checked = true; 87 | this.checkBox2.CheckState = System.Windows.Forms.CheckState.Checked; 88 | this.checkBox2.Location = new System.Drawing.Point(384, 283); 89 | this.checkBox2.Name = "checkBox2"; 90 | this.checkBox2.Size = new System.Drawing.Size(15, 14); 91 | this.checkBox2.TabIndex = 12; 92 | this.checkBox2.UseVisualStyleBackColor = true; 93 | // 94 | // label4 95 | // 96 | this.label4.AutoSize = true; 97 | this.label4.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 98 | this.label4.Location = new System.Drawing.Point(252, 231); 99 | this.label4.Name = "label4"; 100 | this.label4.Size = new System.Drawing.Size(126, 29); 101 | this.label4.TabIndex = 11; 102 | this.label4.Text = "Auto Update"; 103 | // 104 | // checkBox1 105 | // 106 | this.checkBox1.AutoSize = true; 107 | this.checkBox1.Checked = true; 108 | this.checkBox1.CheckState = System.Windows.Forms.CheckState.Checked; 109 | this.checkBox1.Location = new System.Drawing.Point(384, 244); 110 | this.checkBox1.Name = "checkBox1"; 111 | this.checkBox1.Size = new System.Drawing.Size(15, 14); 112 | this.checkBox1.TabIndex = 10; 113 | this.checkBox1.UseVisualStyleBackColor = true; 114 | // 115 | // label1 116 | // 117 | this.label1.AutoSize = true; 118 | this.label1.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 119 | this.label1.Location = new System.Drawing.Point(171, 194); 120 | this.label1.Name = "label1"; 121 | this.label1.Size = new System.Drawing.Size(207, 29); 122 | this.label1.TabIndex = 9; 123 | this.label1.Text = "Program Folder Path"; 124 | // 125 | // textBox2 126 | // 127 | this.textBox2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 128 | this.textBox2.Location = new System.Drawing.Point(384, 200); 129 | this.textBox2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); 130 | this.textBox2.Name = "textBox2"; 131 | this.textBox2.Size = new System.Drawing.Size(415, 23); 132 | this.textBox2.TabIndex = 8; 133 | // 134 | // label3 135 | // 136 | this.label3.AutoSize = true; 137 | this.label3.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 138 | this.label3.Location = new System.Drawing.Point(144, 154); 139 | this.label3.Name = "label3"; 140 | this.label3.Size = new System.Drawing.Size(234, 29); 141 | this.label3.TabIndex = 7; 142 | this.label3.Text = "Mod Pack Creation Path"; 143 | this.label3.Click += new System.EventHandler(this.label3_Click); 144 | // 145 | // modPackPath 146 | // 147 | this.modPackPath.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 148 | this.modPackPath.Location = new System.Drawing.Point(384, 160); 149 | this.modPackPath.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); 150 | this.modPackPath.Name = "modPackPath"; 151 | this.modPackPath.Size = new System.Drawing.Size(415, 23); 152 | this.modPackPath.TabIndex = 6; 153 | this.modPackPath.TextChanged += new System.EventHandler(this.textBox1_TextChanged); 154 | // 155 | // label2 156 | // 157 | this.label2.AutoSize = true; 158 | this.label2.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 159 | this.label2.Location = new System.Drawing.Point(264, 114); 160 | this.label2.Name = "label2"; 161 | this.label2.Size = new System.Drawing.Size(114, 29); 162 | this.label2.TabIndex = 5; 163 | this.label2.Text = "Game Path"; 164 | this.label2.Click += new System.EventHandler(this.label2_Click); 165 | // 166 | // game_path 167 | // 168 | this.game_path.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 169 | this.game_path.Location = new System.Drawing.Point(384, 120); 170 | this.game_path.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); 171 | this.game_path.Name = "game_path"; 172 | this.game_path.Size = new System.Drawing.Size(415, 23); 173 | this.game_path.TabIndex = 4; 174 | // 175 | // panel1 176 | // 177 | this.panel1.BackColor = System.Drawing.Color.DimGray; 178 | this.panel1.Location = new System.Drawing.Point(220, 68); 179 | this.panel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); 180 | this.panel1.Name = "panel1"; 181 | this.panel1.Size = new System.Drawing.Size(579, 8); 182 | this.panel1.TabIndex = 2; 183 | // 184 | // hbtn_Back 185 | // 186 | this.hbtn_Back.BackColor = System.Drawing.Color.White; 187 | this.hbtn_Back.Dock = System.Windows.Forms.DockStyle.Top; 188 | this.hbtn_Back.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 189 | this.hbtn_Back.Font = new System.Drawing.Font("Arial", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point); 190 | this.hbtn_Back.HoverBackColor = System.Drawing.Color.Empty; 191 | this.hbtn_Back.HoverForeColor = System.Drawing.Color.Empty; 192 | this.hbtn_Back.Location = new System.Drawing.Point(0, 0); 193 | this.hbtn_Back.Name = "hbtn_Back"; 194 | this.hbtn_Back.Size = new System.Drawing.Size(1082, 32); 195 | this.hbtn_Back.TabIndex = 1; 196 | this.hbtn_Back.Text = "←"; 197 | this.hbtn_Back.UseVisualStyleBackColor = false; 198 | this.hbtn_Back.Click += new System.EventHandler(this.Hbtn_Back_Click); 199 | // 200 | // lbl_Options 201 | // 202 | this.lbl_Options.AutoSize = true; 203 | this.lbl_Options.Font = new System.Drawing.Font("Bahnschrift Light SemiCondensed", 18F, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point); 204 | this.lbl_Options.Location = new System.Drawing.Point(418, 37); 205 | this.lbl_Options.Name = "lbl_Options"; 206 | this.lbl_Options.Size = new System.Drawing.Size(171, 29); 207 | this.lbl_Options.TabIndex = 0; 208 | this.lbl_Options.Text = "HyperMC Options"; 209 | // 210 | // SettingView 211 | // 212 | this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); 213 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 214 | this.ClientSize = new System.Drawing.Size(1082, 612); 215 | this.Controls.Add(this.pnl_AlignPanel); 216 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 217 | this.Name = "SettingView"; 218 | this.Text = "SettingView"; 219 | this.pnl_AlignPanel.ResumeLayout(false); 220 | this.pnl_AlignPanel.PerformLayout(); 221 | this.ResumeLayout(false); 222 | 223 | } 224 | 225 | #endregion 226 | 227 | private System.Windows.Forms.Panel pnl_AlignPanel; 228 | private System.Windows.Forms.Label lbl_Options; 229 | private Components.HoverButton hbtn_Back; 230 | private System.Windows.Forms.Label label2; 231 | private System.Windows.Forms.Panel panel1; 232 | public System.Windows.Forms.TextBox game_path; 233 | private System.Windows.Forms.Label label3; 234 | public System.Windows.Forms.TextBox modPackPath; 235 | private System.Windows.Forms.Label label5; 236 | private System.Windows.Forms.CheckBox checkBox2; 237 | private System.Windows.Forms.Label label4; 238 | private System.Windows.Forms.CheckBox checkBox1; 239 | private System.Windows.Forms.Label label1; 240 | public System.Windows.Forms.TextBox textBox2; 241 | } 242 | } -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/SettingView.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using Hypermc.Settings; 11 | using Hypermc.Utility; 12 | 13 | namespace Hypermc.UI.Views 14 | { 15 | public partial class SettingView : Form, IView 16 | { 17 | private readonly IUserSettings _settings; 18 | 19 | public SettingView(IUserSettings settings) 20 | { 21 | InitializeComponent(); 22 | _settings = settings; 23 | game_path.Text = settings.MinecraftPath; 24 | modPackPath.Text = settings.ModPacksPath; 25 | } 26 | 27 | public event IView.ViewMessageCallback OnMessage; 28 | 29 | public Control[] ShowView(object? _ = null) 30 | { 31 | SendMessage(IView.MSG_SHOW); 32 | return Utils.PopChildControls(this); 33 | } 34 | 35 | public bool HideView(Control[] controls) 36 | { 37 | Controls.AddRange(controls); 38 | SendMessage(IView.MSG_HIDE); 39 | 40 | return true; 41 | } 42 | 43 | public void DestroyView() 44 | { 45 | SendMessage(IView.MSG_DESTROY); 46 | Close(); 47 | } 48 | 49 | private void SendMessage(int msg) 50 | { 51 | OnMessage?.Invoke(this, msg); 52 | } 53 | 54 | private void Hbtn_Back_Click(object sender, EventArgs e) 55 | { 56 | SendMessage(IView.MSG_GO_BACK); 57 | Hide(); 58 | } 59 | 60 | private void label2_Click(object sender, EventArgs e) 61 | { 62 | 63 | } 64 | 65 | private void pnl_AlignPanel_Paint(object sender, PaintEventArgs e) 66 | { 67 | 68 | } 69 | 70 | private void label3_Click(object sender, EventArgs e) 71 | { 72 | 73 | } 74 | 75 | private void textBox1_TextChanged(object sender, EventArgs e) 76 | { 77 | 78 | } 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /src/HyperMC/UI/Views/SettingView.resx: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | text/microsoft-resx 50 | 51 | 52 | 2.0 53 | 54 | 55 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 56 | 57 | 58 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 59 | 60 | -------------------------------------------------------------------------------- /src/HyperMC/Utility/MessageDialog.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using System.Windows.Forms; 7 | 8 | namespace Hypermc.Utility 9 | { 10 | internal static class MessageDialog 11 | { 12 | internal static DialogResult Exclaim(string message, string? caption = null, MessageBoxButtons buttons = MessageBoxButtons.OK, IWin32Window? owner = null) 13 | { 14 | return MessageBox.Show(owner, message, caption, buttons); 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/HyperMC/Utility/Utils.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Drawing; 5 | using System.Linq; 6 | using System.Runtime.CompilerServices; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using Hypermc.UI.Views; 11 | 12 | namespace Hypermc.Utility 13 | { 14 | internal static class Utils 15 | { 16 | internal static Point PointAdd(Point a, Point b) => new(a.X + b.X, a.Y + b.Y); 17 | 18 | internal static Point PointSub(Point a, Point b) => new(a.X - b.X, a.Y - b.Y); 19 | 20 | internal static void NotImplAlert(string? what = null) 21 | { 22 | MessageBox.Show($"Not Implemented{(what is not null ? " -> " + what : string.Empty)}", 23 | "Error", 24 | MessageBoxButtons.OK, 25 | MessageBoxIcon.Warning, 26 | MessageBoxDefaultButton.Button1); 27 | } 28 | 29 | internal static void OpenBrowser(string url) 30 | { 31 | Process.Start(new ProcessStartInfo("cmd", $"/c start {url}") 32 | { 33 | CreateNoWindow = true 34 | }); 35 | } 36 | 37 | internal static Control[] PopChildControls(Control parent) 38 | { 39 | Control[] controls = new Control[parent.Controls.Count]; 40 | for (int i = 0; i < controls.Length; i++) 41 | { 42 | controls[i] = parent.Controls[0]; 43 | parent.Controls.RemoveAt(0); 44 | } 45 | 46 | return controls; 47 | } 48 | 49 | internal static void ReturnChildControlsBasic(Control owner, Control parent) 50 | { 51 | parent.Controls.AddRange(PopChildControls(owner)); 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /src/HyperMC/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "ApplicationSettings": { 3 | "AppPath": "{0}\\.hypermc", 4 | "DeafultMinecraftPath": "{0}\\.minecraft", 5 | "DefaultModPacksPath": "{0}\\ModPacks", 6 | "ModPacksFile": "{0}\\packs.json", 7 | "SettingsFile": "{0}\\settings.json" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/HyperMC/lib/Main.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | 7 | namespace HyperMCLIB 8 | { 9 | class Main 10 | { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/HyperMC/lib/notifications/SendNotification.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Microsoft.Toolkit.Uwp.Notifications; 7 | 8 | namespace HyperMCLIB 9 | { 10 | public class SendNotification 11 | { 12 | 13 | } 14 | } 15 | --------------------------------------------------------------------------------