XML:XML Modding Lessons: Difference between revisions

From OniGalore
Jump to navigation Jump to search
m (restoring the Divhide around the "Working with XML files" section; moved up XML database to make it quicker to find and click on; wording)
Line 5: Line 5:


==Introduction==
==Introduction==
Oni's resources could be separated into one of two categories: media (such as models, textures and sounds), and non-media (such as character class data). Most of the non-media data can be exported to XML. This allows much easier modding than the hex-editing of the old days (compare the two methods [[Adding_spawnable_characters|here]]). Some media resources can also be edited as "XML", referring to the fact that an XML file will be created alongside the media file when it is exported from the game data, and this XML companion file contains metadata about the media that allows [[OniSplit]] to re-import the resource properly when you are done editing it.
Oni's resources could be separated into one of two categories: media (such as models, textures and sounds), and non-media (such as character class data). Most of the non-media data can be exported to XML. This allows much easier modding than the hex-editing of the old days (compare the two methods [[Adding spawnable characters|here]]). Some media resources can also be "edited as XML", referring to the fact that an XML file will be created alongside the media file(s) when the resources are exported from the game data, and this XML companion file will contain metadata about the media files that allows [[OniSplit]] to re-import them properly when you are done editing them.


To learn what all the resource types do, and to see which types can be edited through XML, see the link to the database at the bottom of the page. Though XML modding can generally be done with nothing more than OniSplit's command line interface and a text editor, the tutorials linked below are written with the [[Anniversary Edition]] in mind, because the AE provides modding tools (including a GUI for OniSplit), gives you a framework for testing your mod package, and globalizes more of Oni's data so it can be used in any level.
To learn what all the resource types do, and to see which types can be edited through XML, see the link to the database below. Though XML modding can generally be done with nothing more than OniSplit's command line interface and a text editor, the tutorials linked below are written with the [[Anniversary Edition]] in mind because the AE provides modding tools (including a GUI for OniSplit) and a framework for testing your mod package, and globalizes more of Oni's data so that it can be used in any level.


==Working with XML files==
==Working with XML files==
{{Divhide|Beginners will find this useful}}
[[Image:Visual Studio collapsed code.png|thumb|right|Code folding in Visual Studio 2019.]]
[[Image:Visual Studio collapsed code.png|thumb|right|Code folding in Visual Studio 2019.]]
[[Image:Xcode collapsed code.png|thumb|right|Xcode 12. If you don't see the code folding ribbon, see Preferences… > Text Editing > Display > Code folding ribbon.]]
[[Image:Xcode collapsed code.png|thumb|right|Xcode 12. If you don't see the code folding ribbon, see Preferences… > Text Editing > Display > Code folding ribbon.]]
Line 31: Line 32:


* '''File comparison''': For comparing two versions of an XML file to find the changes, you can use [https://winmerge.org/ WinMerge] (Windows) or FileMerge (Mac, comes with Xcode). Note that if one of the two files has passed through Oni and been re-exported, the data may have been totally reordered and cannot be diff-gazed effectively.
* '''File comparison''': For comparing two versions of an XML file to find the changes, you can use [https://winmerge.org/ WinMerge] (Windows) or FileMerge (Mac, comes with Xcode). Note that if one of the two files has passed through Oni and been re-exported, the data may have been totally reordered and cannot be diff-gazed effectively.
{{Divhide|end}}
==Knowledge database==
*[[XML:File types|XML resource type database]]


==Starter tutorials==
==Starter tutorials==
Line 43: Line 47:
*[[XML:TRAM#Color_trails|Adding colored contrails to combat moves]]
*[[XML:TRAM#Color_trails|Adding colored contrails to combat moves]]
*[[XML:ONLV|Creating a level]]
*[[XML:ONLV|Creating a level]]
==Knowledge database==
*[[XML:File types|XML resource type database]]


{{XML}}
{{XML}}

Revision as of 20:09, 28 October 2021

XML.png
This article builds on the general introduction to modding found at Modding Oni.

The XML namespace is devoted to explaining Oni's data types in plainer language than the technical documentation at OBD and also provides tutorials in XML-based modding.

Introduction

Oni's resources could be separated into one of two categories: media (such as models, textures and sounds), and non-media (such as character class data). Most of the non-media data can be exported to XML. This allows much easier modding than the hex-editing of the old days (compare the two methods here). Some media resources can also be "edited as XML", referring to the fact that an XML file will be created alongside the media file(s) when the resources are exported from the game data, and this XML companion file will contain metadata about the media files that allows OniSplit to re-import them properly when you are done editing them.

To learn what all the resource types do, and to see which types can be edited through XML, see the link to the database below. Though XML modding can generally be done with nothing more than OniSplit's command line interface and a text editor, the tutorials linked below are written with the Anniversary Edition in mind because the AE provides modding tools (including a GUI for OniSplit) and a framework for testing your mod package, and globalizes more of Oni's data so that it can be used in any level.

Working with XML files

Knowledge database

Starter tutorials

Additional tutorials