OpenXcom Forum

Modding => Tools => Topic started by: SonOfRainbow on September 03, 2014, 08:15:20 pm

Title: OXC Ruleset Editor
Post by: SonOfRainbow on September 03, 2014, 08:15:20 pm
Hi,

I couldn't really find a ruleset editor (saw some posts) so took a couple days to create one in .NET WPF.
 
It's currently Version 0.1 but it's able to parse through the default ruleset without any errors. If you use the tool make sure to make a backup before making any modifications! Also, it could be a good idea to compare the output with the input (with a tool such a BeyondCompare) before using the generated ruleset.

Tool Link: https://www.openxcom.com/mod/oxc-ruleset-editor (https://www.openxcom.com/mod/oxc-ruleset-editor)

Current Features:

Some known issues:

Let me know if you encounter any issues, I'll try to fix them when I have time but will look into cleaning up the source code and sharing it with the community.

Have fun and keep the mods coming!
 ;D
Title: Re: OXC Ruleset Editor
Post by: SonOfRainbow on September 04, 2014, 01:21:36 am
Just uploaded Version 0.15 which allows you to Add/Delete a lot of the entries in the ruleset.

Since the data is now presented in a TreeView you can right click on the nodes to Add/Delete rules.
Title: Re: OXC Ruleset Editor
Post by: ivandogovich on September 04, 2014, 01:46:06 am
This tool looks really great.  I can't wait to take it for a test drive. :)
Title: Re: OXC Ruleset Editor
Post by: Roxis231 on September 04, 2014, 06:52:26 am
Just downloaded and gave it a try - got this result.
Title: Re: OXC Ruleset Editor
Post by: SonOfRainbow on September 04, 2014, 05:48:24 pm
What version of Windows do you have? (XP/7/8/8.1) Also 32-bit or 64-bit installation?
Title: Re: OXC Ruleset Editor
Post by: Roxis231 on September 04, 2014, 10:12:20 pm
MS Windows XP Professional 32-bit with SP3

Current with all updates (except Windows Genuine Advantage)

Any Help?
Title: Re: OXC Ruleset Editor
Post by: Yankes on September 04, 2014, 11:14:51 pm
do you have .net installed?
Title: Re: OXC Ruleset Editor
Post by: Roxis231 on September 05, 2014, 02:21:23 am
Versions 1.1, 2.0, 3.0 and 3.5 SP1

There hasn't been any more right?

Edit : Just found and Instaled 4.0 - Still get the Invalid Application result.
Title: Re: OXC Ruleset Editor
Post by: Yankes on September 05, 2014, 07:07:08 pm
It could be 4.5 that is unavailable for XP.
Title: Re: OXC Ruleset Editor
Post by: SonOfRainbow on September 05, 2014, 11:08:43 pm
Yeah, version 0.1 and 0.1.5 were built with .NET 4.5

I'm working on a completely redesigned version, Had to do some major work around since YamlDotNet seems to interpret the YAML nodes in a different way then intended...so the version will jump to 0.5.0.

But the layout has been redesigned and the tool will be much more optimized (XCOM1 ruleset loads in 5 seconds) and supports the serialization/deserialization of 99% of it.
It will be built in .NET 4.0 to increase compatibility but  but that's the lowest framework the application can go since it uses datagrids extensively.

Stay tuned, should be ready very soon.
Title: Re: OXC Ruleset Editor
Post by: SonOfRainbow on September 07, 2014, 07:02:19 am
I'm happy to announce that version 0.5.0 has been released. It should support the entire ruleset as of the openxcom_git_master_2014_09_06_0652 build.
Visit the tool page for download and screenshots.

Still not fully tested in-game so use with caution. Enjoy!

------------------------------
Version 0.5.0
------------------------------
 + Implemented full de-serialization and serialization of Xcom1Ruleset.
    + De-serialization with YamlDotNet; Serialization with custom code.
 + Added summary counts of loaded counts beside TreeView.
 + Removed right-click context for Add/Delete; Use of DataGrids instead.


------------------------------
Instructions
------------------------------
 + Use File menu options to Load/Save/Create New rulesets.
     *** Remember to make backups of your Ruleset and do a text compare once the ruleset is generated. ***
     + Generated ruleset has not been tested extensively in-game.
     + Editor will generate ruleset in the same order as the Xcom1Ruleset. Please refer to it for formatting.
 + Create new entry by clicking on the bottom-most empty row of a data grid.
 + Delete entries by hitting Delete on keyboard.
 + Arrays must be entered in this format: [1, 2, 3, 4, 5]
 + If a loaded ruleset contains an error the Editor will indicate the row number in the Output panel.
 + Save and backup regularly.

------------------------------
Known Issues:
------------------------------
 - Issue with non-English string localization.
 - No field validation.
 - Trying to open a new ruleset while trying to edit a grid entry may free the Editor.


Please report any bugs on the OXC Forum.
Visit: https://www.openxcom.com/mod/oxc-ruleset-editor
Ruleset Reference: https://www.ufopaedia.org/index.php?title=Ruleset_Reference_(OpenXcom)
Title: Re: OXC Ruleset Editor
Post by: myk002 on September 08, 2014, 04:05:34 am
If you're looking for ideas for additional functionality, the ability to generate a manufacturing profitability report (such as the one here (https://www.ufopaedia.org/index.php?title=Manufacturing_Profitability)), based on a list of loaded rulesets, would be very nice indeed.
Title: Re: OXC Ruleset Editor
Post by: hellrazor on December 21, 2015, 12:09:22 am
Your work is appreciated, but i do not believe that your editor will beat Vi-Improved :)
Title: Re: OXC Ruleset Editor
Post by: Bloax on December 21, 2015, 06:09:37 am
I'm sure it'll beat vim for those that don't happen to know how to use it.

Which just happens to be quite a lot of people.
Title: Re: OXC Ruleset Editor
Post by: davide on December 21, 2015, 08:59:54 am
Do you plan to load more than one ruleset at the same time, at least as readonly  ?

Some big mods have a lot of rulests and it is possible to
build mod on other mod :Piratez as example.

good work  !