# Application version 1.4.2.0 (2022-04-09)
https://www.virustotal.com/gui/file/0cecd539dbf22f7d0d8ebc04d6f3ebad7cff7c7fee087ea487ea0832e4a06062?nocache=1

## The Relhax Modpack will be closing on April 20th, 2022. Thank you to all our volunteers and users for over 5 years of success!

- Added "end of life" window and logic to appear and prevent installations after the shut down date. It can be "brought back" with a version update in the future, so it's not permanent.
- Set the check for updates timeout to 3 seconds for after the servers go down, and it does not cause the application to quit. (You can still use it to uninstall, diagnostics, download WG updates, etc.)
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.4.1.1 (2022-03-26)
https://www.virustotal.com/gui/file/a5f0656c9d44f31605261241613b4e38e515594689a419ba1ac4607c387d81a1?nocache=1

## The Relhax Modpack will be closing on April 20th, 2022. Thank you to all our volunteers and users for over 5 years of success!

- Fixed a bug with the language selection not saving.
- Fixed a bug with the language selection not being displayed on application first launch (when the settings file is deleted).
- Minor code refactoring and optimizations.
- Updated documentation.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.4.1.0 (2022-03-08)
https://www.virustotal.com/gui/file/79db977e31acdbf7d6ecd6c7eefd5103f4ed63072f78e2ab14e518bb20794bd1

## The Relhax Modpack will be closing on April 20th, 2022. Thank you to all our volunteers and users for over 5 years of success!

- Fixed the automation runner pass/fail color change for sequence runs not working in dark mode.
- Fixed bug of atlas creators trying to use same bitmap resource at the same time causing an installer error.
- Fixed bug of the download progress not properly reporting download speed and ETA.
- Fixed severity of some log messages for the trigger system.
- Other misc code optimizations.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.4.0.0 (2022-02-26)
https://www.virustotal.com/gui/file/86ede3216074d901b87978b83c2bb02dd86601fe87e6526bea4a816220174d9a

## "This is the last official planned update to the Relhax Modpack"

### Automation additions and fixes
- Added the ability for an automation sequence to run browser sessions.
  - This provides the ability of using the same browser object, therefore allowing persistence of cookies or other login data.
  - Useful for sites that require a user to be logged in or require certain values in requests to prevent bots (lol).

- Added the ability for the user to specify 3 user macro names and values.

- Added the following automation tasks:
  - `StartBrowserSessionTask`: Starts an automation browser session.
  - `BrowserSessionSetHeaderTask`: Sets a default request header value.
  - `BrowserSessionRemoveHeaderTask`: Remove a request header value.
  - `BrowserSessionPostTask`: Sends a POST request to a URL.
  - `BrowserSessionGetTask`: Sends a GET request to a URL.
  - `BrowserSessionDownloadFileTask`: Downloads a file form a given url to a location on disk.

### "There's always time to do it right the second time"
- Re-wrote the dark theme UI and removed the winforms approach to applying control colors.
  - The original engine was an adaptation from our legacy WinForms application to WPF. I completely re-wrote it using design patterns for WPF that is better for performance and re-usability.
  - Some components had colors changed to make them more darker, since changing some properties was not possible in the old system.
  - It also frees up the use of the "Tag" property for each control of each window that should have a custom style applied to it.

- Re-wrote several sections of the DatabaseManager to make loading and saving database components more object-oriented.
  - After a database is loaded, it needs to have "post-processing" done on it's internal values (or "pre-processing" in the case of saving). This was moved into the DatabaseComponent (previously called XmlDatabaseComponent) so that any object using this load/save implementation could override and add the functionally needed.
  - It also means that the script style approach of the DatabaseUtils class was removed.

### New features!
- The long-awaited conflicting packages was finally implemented!
  - This means that if you try to select packages that conflict with each other (common examples being xvm vs. stand-alone features), it will inform you of the conflict and present you with a choice of which package you'd like to keep selected.
  - In the case of conflicts in a selection file, as components are selected, any conflicting package will be un-checked (the last loaded/selected package takes priority). The selection information window will inform you of this as well.

- Get #triggered with the new installation triggers system!
  - This system allows us to perform some post-extraction tasks (like atlas creation for contour icons) as soon as all relevant packages for it are extracted.
  - This means, continuing the contour icons example, that as soon as all contour icon packages are extracted, the atlas building process can immediately start, instead of waiting until all packages are extracted.
  - This also applies for shortcut creation and the installation of fonts.
  - Overall, it means that (when enabled) the installation time has been reduced by several seconds, depending on your installation selection.

- Updated database to xml schema 1.2
  - Schema 1.2 enforces that conflicting package and dependency entries contain the package internal name and UID properties for redundancy.

### Other Misc changes
- Removed the twitter and facebook buttons since we don't use those anymore.
- Changed the url for the support button to go to the Modpack discord (we don't offer support on the modpack forums anymore).
- Updated translations.
- Fixed the editor's "create ftp folder" operation crashing if the folder already exits.
- Added a couple missing translation entries and typos.
- Added focus to the FTP folder name textbox for the "create ftp folder" window when shown.
- Fixed the "yes" and "no" buttons in the version update window to be upper case.
- Moved some log messages from info the debug.
- Added a bunch of internal code documentation.
- Added some additional debugging information to Ui components in the PackageSelection window to help determine what component is attached to what package.
- Other misc code cleanup and optimization.
--------------------------------------------------------------------------------------------------------------------------------------------


# Application version 1.3.5.1 (2022-01-21)
https://www.virustotal.com/gui/file/d220b81bc03569ff0fce2f70df233d404964cbe9fd2cc7d61fd6409bdc8f1778

- Fixed bugs with modpack toolbox for database publishing.
- Fixed issues and optimized code in DatabaseManager.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.3.5.0 (2022-01-19)
https://www.virustotal.com/gui/file/2da65e991ef0290c9239ee97580c2e0755f853c115a1e15e62f22345fe1f5377

## "Working is good, but working efficiently is better"

### A new way to load and save Xml documents
- The system to save and load database packages to and from xml documents was completely re-written with a new, more modular implementation. It separates the physical loading of xml from web or disk into xml class objects (serialized into xml document objects), and the parsing of serialized xml objects to and from class properties via a map, or schema. Now, those are managed by two different version fields `documentVersion` and `schemaVersion`.
  - The document physical loading system was re-worked to be less hard-coded, and the saving now works on the idea of *updating*, rather then *replacing* the previous document information. For example, it won't save a file (or certain parts of it) if no changes occurred (before it would always delete and  re-save).
  - This allows for comments in the database that will be ignored by the system, but not removed when updating the physical file.
  - The schema system allows us to map database properties to xml elements or attributes (if not a list property), which also use an updating method rather then replacing method, with the exception of attributes.
  - The system also maintains ordering of what's listed in the schema.

### (Another) class re-structuring to make it more like a program, and not a script
- With the new xml serialization system, the class structure of database components was completely re-worked to now have all serializable components derive from the XmlDatabaseComponent class.
  - Now components can call `ToXml()` and `FromXml()` on them selves, while passing xml objects, to recursively save/load themselves and child components.
  - It also enables abstract 'middleman' classes that can handle common methods and objects between multiple components.
- A more robust copy system was implemented using the constructors and derived versions of them.
- An instruction compare system was also built-into the new class structure, for Instruction objects and their derivatives.

### Instructions have been moved into the database
- Post-install instructions (patches, atlas creation, shortcut creation, xml unpack/copy) were previously saved in the modpack packages and extracted with the package files into custom folders. This is bad for 2 reasons:
  - First, the instructions would be taking up space in the package zip files (sometimes, it was the only thing in a package's zip file), and then take up time being extracted to disk, while needing to maintain instruction order, and THEN would be loaded from disk from xml into a document the installer could act on. Gross.
  - Second, and most important, instructions weren't kept under source control. To update an instruction, it would require updating the package, and we were unable to effectively track instruction updates, who updated it, the exact changes, etc.
- Now, the instructions have been incorporated into the database: The application already has them parsed and loaded when running an install, and only needs to calculate the order to apply the instructions, which takes milliseconds.

### Automation system additions and fixes
- Added the following tasks:
  - DirectoryMoveTask: Attempt to move a file the 'quick' way of updating its location on the same volume. If attempting to move a file across volumes, it will fail.
  - FileExistsTask: Ensure a file exists. That's it.
  - MacroStringInputMacroJsonTask: Use JsonPath to search for a value by looking inside a macro.
- Improved class structure and re-usability by adding abstract classes DirectoryDestinationTask and MacroStringInputMacroTask, to manage the destination directory of a IO task and get the value of a given macro, respectively.
- Added the ability to specify which browser engine to use (IE11 or Edge) for DownloadBrowserTask, MacroStringSplitBrowserTask, MacroSubstringBrowserTask, implemented through a BrowserManager class.
- Fixed cleanup and disposal of unmanaged browser resources for DownloadBrowserTask, MacroStringSplitBrowserTask, MacroSubstringBrowserTask.
- Fixed a bug with the Macro tasks that would allow updating/replacement of macros that are Application defined, and now warns when replacing a global macro.
- Fixed a bug during HTMLPath parsing that would return an empty string if the returned element was the root of the document.
- Fixed log string formatting issues with several tasks.

### Other bug fixes and improvements
- The browser engine EdgeHTML (used for the Microsoft Edge browser) is now usable in the modpack for html parsing of some websites that don't support IE11.
- Updated 3rd dependency libraries DotNetZip, HtmlAgilityPack, Newtonsoft.Json, MSTest.TestAdapter, MSTest.TestFramework.
- Both `RelhaxSandbox` and `RelhaxModpack` projects were converted from Nuget Package config to Nuget Package Reference style of managing Nuget packages.
- The `RelhaxSandbox` project test implementations of embedded browsers was cleaned up.
- Other misc bug fixes and optimizations.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.3.4.0 (2021-12-19)
https://www.virustotal.com/gui/file/f0fe66fb073e7c629c18abc73a4eb7e0c3cf68768df9d0f2f76d9411325e0ed0

## "Automation is the future" ~ The guy writing the automation.

### Bug fixes and improvements for the package automation update system. If only it could update itself as well...
- Added the following automation tasks:
  - DirectoryCompareTask: Enable searching for files and comparing them, rather then needing to specify multiple files to check.
  - DirectoryCompareCountTask: Similar to DirectoryCompareTask, but when the files count or names change between directories, it counts as an update needed, not an error.
  - DirectoryCompareInverseTask: Similar to DirectoryCompareCountTask, except files with different hashes are set into the "noMatchStop" group, implying manual updating is required (stops the automation sequence from continuing).
- Fixed the following automation tasks:
  - DirectoryDeleteTask: Fixed/synced parameters to DirectorySearchTask.
  - DirectoryDeleteTask: Fixed bugs with deleting folders based on absolute and relative location.
  - DirectoryCopyTask: Fixed/synced parameters to DirectorySearchTask.
  - MacroSubstringMacroTask: Fixed bug with sometimes not getting the correct substring of the correct target variable.
  - MacroSubstringHtmlTask: Fixed bug with sometimes not getting the correct substring of the correct target variable.
  - MacroSubstringFilenameTask: Fixed bug with sometimes not getting the correct substring of the correct target variable.
  - MacroSubstringBrowserTask: Fixed bug with sometimes not getting the correct substring of the correct target variable.
  - RetrievePackagePropertyTask: Fixed bugs with task not using the correct target package to get/set based on target argument from task.
  - UpdatePackagePropertyTask: Fixed bugs with task not using the correct target package to get/set based on target argument from task.
  - MacroStringSplitBrowserTask: Fixed a bug with task not waiting until the WebClient request was completed.
  - MacroStringSplitHtmlTask: Fixed a bug with task not waiting until the WebClient request was completed.
  - MacroSubstringBrowserTask: Fixed a bug with task not waiting until the WebClient request was completed.
  - MacroSubstringHtmlTask: Fixed a bug with task not waiting until the WebClient request was completed.
  - MacroCreateTask: Fixed behavior that would not accept a macro value of empty text (sometimes that's the intent).
  - ShellExecuteTask: Fixed bugs handling the created child process upon failing to launch.
- Cleanup and bug fixes of the automation runner UI.
- Change the behavior of running multiple sequences for automation so that it saves the database at the end of a run from sequence error or sequence pass conditions. (It won't save for internal errors).
  - This is because for example, in a sequence of 4, if 2 fails, but 3 and 4 work, now it will save the database after all sequences are run. It wouldn't' before because 2 failed.
- Improved error code resolution for automation sequencer errors.
- Added check during automation sequence run if required settings are set in the settings tab for all macros.
- Removed overly complex method to check if url is valid, replaced it with a much quicker and simpler method.
- Added option IncludeRootInSearch to include DirectoryPath in search results. This allows you to delete an empty directory.

### Testing the application, one unit at a time
- Added several automation task unit tests and ensured they are passing.
- Updated all appilcation and database unit tests to be working with the updated code base and passing (except the patching unit tests).
- Updated/finished the automated installation unit test for future database self-checking and reporting.
- When updating the modpack by a major version, we require the pull request in source code to show proof of the unit tests passing.

### LOG MESSAGE SPAM! "The  b e s t  way to reach people."
- Fixed issues with how logging was handled between the editor, patch designer and the automation runner, in terns of redirection and re-initialization.
- Reduced the ammount of spam from the logging system when running automation sequences.
- Moved several info level log statements from info to debug throughout the application.
- Improved log formatting in the automation runner.
- Added option to suppress logging output messages that are of level debug to the automation log output console.

### Other bug fixes and improvements
- Added property `LastUpdateCheck` into database so the last time an update check was done by someone (or the automation runner) it is logged.
- Added feature to output all automation runner root elements for each package into a text file. Allows copy paste when creating automation sequences.
- Fixed bugs with file utility methods ProcessEmptyDirectories(), FileSearch, added file utility method DirectorySearch.
- Fixed optimization issues with the `Default` uninstall method.
- Class structure improvements for windows that are custom features like the editor or patch designer. Also synchronized how the logging was handled between all of them.
- Added translation entries and updated translations from contributers.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.3.3.0 (2021-07-25)
https://www.virustotal.com/gui/file-analysis/MTMyYjQ2ZTBlYzY1MjU0N2Q0MjU5NDc2M2ZiNzI0MDk6MTYyNzI1NTU4Mg==/detection

## "It will work this time, believe me".

### The beginning of the Automation system for the database to update itself and gain sentience.
- Allows us to script the update process rather then relying on manual work.
- Scripts written in Xml to allow leverage of already known syntax.
- Complete with error catching and exit code parsing to know what was the reason for ending, if it was success, failure, or no changes needed to the package.
- An automation runner window runs the `AutomationSequencer`.
- It has a template / import system so that we can re-use tasks as needed. This is like object-oriented programming, so when we update a template, it updates for all sequences that use it. No dumb copy-pasting here!
- An `AutomationSequencer` runs a list of `AutomationSequence` objects, called sequences for short.
- Each sequence has a list of tasks that it will run. The types of tasks can be downloading, file IO, zip file processing, file comparison via md5 hash, and more.
- It allows for loading from a specific branch of our repository, or a local copy.
- A signature feature of the system is a multi-level, recursive, macro processing system using regex tag balancing. You can have macros inside macros, AND you can recursively solve macros.

### Lots of code optimizations and improvements that frankly should have been done the first time around, but yeah. ThE MoRe YoU KnOw.
- Moved several static methods and copy-paste code into re-usable managed classes. #Reuse #OOP.
- Added a bunch of missing translations that managed to get lost in a migration to a different process of loading them into the application on startup.
- Updated and added new translations for Russian (DrWeb7_1).
- Added text wrapping to tooltip messages so they don't go off the screen or look weird.
- Cleaned up and updated tooltip explanations for the settings options in the settings tab.
- Some debug log spam cleanup.

### So many bug fixes the EPA may classify this update as a biological hazard.
- Fixed layout of database editor where it looks fine in the developer view but is wrong in runtime. Thanks to The_Illusion for pointing this out (repeatedly until I finally fixed it).
- Fixed locations of database version and language selection text so it is aligned and doesn't wrap to a new line.
- Fixed wrong translation key entry for Minimalist mode description.
- Fixed not showing beta application release notes in application news viewer and version information windows.
- Fixed code merge issues with custom scaling and font settings.
- Fixed a bug where custom database feature windows (like the editor, patch designer, etc.) would crash on launch if a custom font was requested.
- Fixed a bug that would not correctly detect the version of windows above windows 8.0.
- Fixed the bug of the database editor not saving to the correct file location.
- Fixed the bug of the database editor crashing when removing or adding, or moving a package at the top most level of a category.
- Fixed a bug with the first time load of the beta application distribution not being set properly on startup. It was causing a loop (or weird update track, at least). Thanks for Nullmaruzero for his hours of debugging on this.
- Fixed crashes in the package selection list when right clicking on a disabled package for preview.
- Fixed crashes when selecting the category root checkbox in the package selection list.
--------------------------------------------------------------------------------------------------------------------------------------------

# Application version 1.3.1.0 (2021-05-15)
https://www.virustotal.com/gui/file-analysis/ZDE0ZTAyNTc0ODUyNTA5ZTRmOTUyZjBiMzcwMTU4ZmQ6MTYyMTEzMDQ5NA==/detection

## The application update you didn't know was needed, and if I did it right, will hardly notice

### A complete re-structure of the application from the bottom-up
- There was a lot of spaghetti code, or at least potential for some (more). It was cleaned up by implementing class structure into several areas:
  - A lot of static properties and settings were moved into class objects. This helps with trying to find where things are randomly set within different points of the code and allows for potential modification of settings to be used in a sub-function.
  - Windows that provide a separate function (like Patch Designer or Database Editor) now all derive from RelhaxCustomFeatureWindow, which ensures they all have a ModpackSettings and CommandLineSettings configuration class objects.
  - Application logging and startup was changed so that modpack settings are loaded for all 'feature windows'. This means that the order for application launch is now:
    1. Logging setup
    2. Settings loading
    3. .Net framework version verification
    4. Command line parsing
    5. Feature window selection
  - Several static methods and functions were moved into class structure objects. This allows for two things: Reuse-ability, and more reliable and extensive unit testing. Specifically:
    - Settings object loading/saving to/from custom feature Windows.
    - Local database cache management.
    - Downloading of packages from our servers.

### New feature: Ability to select download mirrors!
- Starting with 1.3.1.0, you have the ability to select a download mirror for downloading the zip packages! This is a huge benefit for our EU, RU, (basically not NA) users! As of now, you have two options:
  - relhaxmodpack.com, Dallas, USA
  - clanverwaltung.de, Frankfurt, Germany
- Additionally, we've integrated our mirror solution to use rsync for hourly synchronization, with the option to manually sync from the database editor. As soon as a package is updated to the main server, it will be on the mirror(s) in seconds!

### Less 'incomplete download' messages
- The new download manager has integrated md5 hash calculation right into downloading, so as soon as the file is downloaded, the hash is already calculated. This allows two things:
  - The hash is saved immediately to the download cache database so you don't need to wait for it when you are loading the selection list.
  - The hash is compared to the server hash, and if not equal, it will automatically try a could times to re-download. NOTE: with the beta database, packages 'in-testing' will still be re-downloaded every time until published into the stable database.

### Other big changes you'll notice
- The preview window was not only optimized internally, but now will display the next preview elements you right click on *without* re-opening the window.
- The thread synchronization was re-worked with the introduction of the download manager component
  - Now in the 'download while installing' step, if an extraction thread is waiting for a package to download, it will use synchronization mechanisms instead of low frequency polling. It's all about parallel computing and optimization.
  - This also fixed issues with progress reporting, especially in the Advanced Progress reporting window: When 'download while installing' enabled, the progress will report downloading, rather then reporting nothing and giving the idea it is stuck.
- The escape key can be used to close several dialog-like windows now (diagnostics, install done, and release notes windows to name a few).
- Added a `Deprecated` field to the database for internal tracking. This can be used by us to track, investigate and determine action on packages that look old and obsolete.
- Added a `Minimalist Mode` as requested by some users, so that only the minimum amount of packages are installed for mod operation. For example, it won't change the background or loading theme to be the Relhax logo.
- Improved the behavior of the Diagnostic Tools window so that it will try to auto-fill the selected WoT directory info by the following methods:
  - If an installation was just done, it will use that path.
  - Else, it will auto search (like the main installation process) and select the most recent installation path.
- In the main installation process, and when selecting a client in the Diagnostic Tools, instead of a window prompting you to find a folder, it will first provide you with a list of auto-detected WoT install paths. You can still manually select one from that window.


### Miscellaneous improvements
- Re-work top of ModSelectionList layout to allow for dynamic expansion of text (it will wrap and fill down, those below it will move down).
- Add label to ModSelectionList to show the version of the database you'll be installing.
- Updated the instruction parsing code (Atlas files, Patch files, etc) to be using a reflective and dynamic method, rather that a static method that required manual entry and maintenance.
- Change default selection view to legacy.
- Fixed a crash when canceling the scaling option after preview that occurred after the time expired.
- Fixed the code to validate a selection structure after loading it from a file. It will now check to make sure only 1 option is selected in options that should only have one, rather then only checking if it had 1 or more.
  - Also fixed the scenario where a parent package would still be selected and technically be an invalid selection when the child was determined to be an invalid selection.
- Added editor option that if set, will auto delete a zip from the disk after a successful upload. Honors the "delete is actually move" setting.
- Removed useless package properties: StartAddress and EndAddress. They were only used once, and never afterwards.
- Fixed alignment of language selection text box.
- Moved all downloads from http to https.
- Remove separate text box informing the user he can search, and put it into the search combobox.
- Improve exception logging for CommonUtils.SetListEntries().
- Beta and Alpha application distributions now will have debug logging enabled always.
- More refactoring of enums and EventArgs into the Enums and CustomEventArgs namespace/folder.
- Removed UI options for custom theme. Any custom theme options found will re-direct to default.
- Updated and added new translations for English, Spanish(LordFelix), French (Tolrod22), German (Elektrosmoker), Polish (Nullmaruzero)
--------------------------------------------------------------------------------------------------------------------------------------------
