Difference between revisions of "About.xml"

From RimWorld Wiki
Jump to navigation Jump to search
m (→‎Tags: Fixed the stupid comment error. Now proper comments)
(Moved explanations to after the tags. Added incompatibleWith.)
Line 10: Line 10:
 
<pre>
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<?xml version="1.0" encoding="utf-8"?>
 
 
<ModMetaData>
 
<ModMetaData>
<name>Example Mod</name>
+
    <!-- The name of the mod -->
<!-- The name of the mod -->
+
    <name>Example Mod</name>
<author>Mod Author</author>
+
   
<!-- The mod author name, usually set to your Steam/Forum name -->
+
    <!-- The mod author names, usually set to your Steam/Forum name -->
<url>www.anything.com</url>
+
    <author>Mod Author, Contributing Author, Other Folks, etc.</author>
<!-- A URL to be displayed on your mod info page(if available). Can be set to link to anything. Most link it to their Github/Workshop page/forum post. -->
+
   
<packageId>AuthorName.ModName/ModSeries.ModName/AuthorName.ModSeries.ModName</packageId>
+
    <!-- A URL to be displayed on your mod info page(if available). Can be set to link to anything. Most link it to their Github/Workshop page/forum post. -->
<!-- Added in 1.0. Please make it human readable. Avoid acronyms where possible. -->
+
    <url>www.anything.com</url>
<supportedVersions>
+
   
<li>0.0</li>
+
    <!-- Added in 1.0. Please make it human readable. Avoid acronyms where possible. Normally qualifiers seperated by periods.-->
<li>0.1</li>
+
    <packageId>AuthorName.ModSeries.ModName</packageId>
</supportedVersions>
+
   
<!-- Supported version lists which versions of Rimworld your mod is compatible with. If your mod doesn't break across versions, lists them all here. -->
+
    <!-- Supported version lists which versions of Rimworld your mod is compatible with. If your mod doesn't break across versions, lists them all here. -->
<modDependencies>
+
    <supportedVersions>
    <li>
+
        <li>1.1</li>
      <packageId>Unknown (help extend this)</packageId>
+
        <li>1.2</li>
      <displayName>Unknown (help extend this)</displayName>
+
    </supportedVersions>
      <downloadUrl>Unknown (help extend this)</downloadUrl>
+
   
      <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
+
    <!-- Describes your mod, can be multiple lines long. -->
    </li>
+
    <description>Sample description.
</modDependencies>
+
       
<modDependenciesByVersion>
+
        Which spans multiple lines.
    <v1.1>
+
    </description>
      <li>
+
    <!-- List of other mods which your mod requires to function. -->
        <packageId>Unknown (help extend this)</packageId>
+
    <modDependencies>
        <displayName>Unknown (help extend this)</displayName>
+
        <li>
        <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
+
            <packageId>Unknown (help extend this)</packageId>
        <downloadUrl>Unknown (help extend this)</downloadUrl>
+
            <displayName>Unknown (help extend this)</displayName>
      </li>
+
            <downloadUrl>Unknown (help extend this)</downloadUrl>
    </v1.1>
+
            <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
</modDependenciesByVersion>
+
        </li>
<description>
+
    </modDependencies>
Sample description
+
    <modDependenciesByVersion>
</description>
+
        <v1.1>
<!-- Describes your mod, can be multiple lines long. -->
+
            <li>
<loadAfter>
+
                <packageId>Unknown (help extend this)</packageId>
<li>Ludeon.RimWorld</li>
+
                <displayName>Unknown (help extend this)</displayName>
<li>Ludeon.RimWorld.Royalty</li>
+
                <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
</loadAfter>
+
                <downloadUrl>Unknown (help extend this)</downloadUrl>
<!-- Lists the mods which should be loaded before your mod. Helps ensure your dependencies are loaded in first. -->
+
            </li>
 +
        </v1.1>
 +
    </modDependenciesByVersion>
 +
   
 +
    <!-- Lists the mods which should be loaded before your mod. Helps ensure your dependencies are loaded in first. -->
 +
    <loadAfter>
 +
        <li>Ludeon.RimWorld</li>
 +
        <li>Ludeon.RimWorld.Royalty</li>
 +
    </loadAfter>
 +
   
 +
    <!-- List of packageIds of any mods which are incompatible with your mod. -->
 +
    <incompatibleWith>
 +
        <li>erdelf.HumanoidAlienRaces</li>
 +
    </incompatibleWith>
 
</ModMetaData>
 
</ModMetaData>
 
 
</pre>
 
</pre>
  
Line 59: Line 70:
 
<targetVersion> has been replaced by <supportedVersions>. Use is as follows :
 
<targetVersion> has been replaced by <supportedVersions>. Use is as follows :
 
<pre>
 
<pre>
<supportedVersions>
+
    <supportedVersions>
<li>1.0</li>
+
        <li>1.0</li>
</supportedVersions>
+
    </supportedVersions>
 
</pre>
 
</pre>
 
== Another tag format? ==
 
== Another tag format? ==

Revision as of 23:17, 5 September 2020

This article is supposed to explain what tags are available in the About.xml file & what the tags do & how you should use them. The exact format of the article is still under development, please help.

(Yes, I'm aware that I'm not writing this as objectively as an article should be (sorry), but I feel I need to explain what this article should aim towards, please DON'T just delete it! )

Tags

These are the tags I have found in various mods I have downloaded, but I don't understand all of them, i'm not sure if all of them even CAN be combined with each other & therefore I need help from more experienced developers.

<?xml version="1.0" encoding="utf-8"?>
<ModMetaData>
    <!-- The name of the mod -->
    <name>Example Mod</name>
    
    <!-- The mod author names, usually set to your Steam/Forum name -->
    <author>Mod Author, Contributing Author, Other Folks, etc.</author>
    
    <!-- A URL to be displayed on your mod info page(if available). Can be set to link to anything. Most link it to their Github/Workshop page/forum post. -->
    <url>www.anything.com</url>
    
    <!-- Added in 1.0. Please make it human readable. Avoid acronyms where possible. Normally qualifiers seperated by periods.-->
    <packageId>AuthorName.ModSeries.ModName</packageId>
    
    <!-- Supported version lists which versions of Rimworld your mod is compatible with. If your mod doesn't break across versions, lists them all here. -->
    <supportedVersions>
        <li>1.1</li>
        <li>1.2</li>
    </supportedVersions>
    
    <!-- Describes your mod, can be multiple lines long. -->
    <description>Sample description.
        
        Which spans multiple lines.
    </description>
    <!-- List of other mods which your mod requires to function. -->
    <modDependencies>
        <li>
            <packageId>Unknown (help extend this)</packageId>
            <displayName>Unknown (help extend this)</displayName>
            <downloadUrl>Unknown (help extend this)</downloadUrl>
            <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
        </li>
    </modDependencies>
    <modDependenciesByVersion>
        <v1.1>
            <li>
                <packageId>Unknown (help extend this)</packageId>
                <displayName>Unknown (help extend this)</displayName>
                <steamWorkshopUrl>Unknown (help extend this)</steamWorkshopUrl>
                <downloadUrl>Unknown (help extend this)</downloadUrl>
            </li>
        </v1.1>
    </modDependenciesByVersion>
    
    <!-- Lists the mods which should be loaded before your mod. Helps ensure your dependencies are loaded in first. -->
    <loadAfter>
        <li>Ludeon.RimWorld</li>
        <li>Ludeon.RimWorld.Royalty</li>
    </loadAfter>
    
    <!-- List of packageIds of any mods which are incompatible with your mod. -->
    <incompatibleWith>
        <li>erdelf.HumanoidAlienRaces</li>
    </incompatibleWith>
</ModMetaData>

Deprecated Parts

<targetVersion> has been replaced by <supportedVersions>. Use is as follows :

    <supportedVersions>
        <li>1.0</li>
    </supportedVersions>

Another tag format?

Another way to explain this data might be more similar to a filesystem, like this:

  • ModMetaData/name = The name of the mod (probably better)

or:

  • <ModMetaData>/<author> = Name of who created this mod (bad, because eg: <li> interfere with the Wiki-code)

or: (I really like this format)

  • <?xml version="1.0" encoding="utf-8"?> - MUST be included exactly like this, explains to the program how the data should be interpreted.
  • ModMetaData - A container for all the data that is related to this mod.
    • name - The name of the mod.
    • author - The name of the author.
      • supportedVersions - A container for suported versions.
        • li - A list item containing a version number, like 1.0 or 2.5.3
      • modDependencies - A container for mods that is needed for this nod to function properly.
  • ....

Questions

  • <ModMetaData>/<packageId> How is this determined?
  • Are <ModMetaData>/ <modDependencies> & <modDependenciesByVersion> mutually exclusive? or can both be present in the same file?
  • I think there exist some kind of: <ModMetaData>/ <incompatibleWith> / <li> /<packageId> tag, but I haven't seen it in any of my downloaded mods, please add it if you know more about it.