Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

<?xml version="1.0" encoding="utf-8" ?>
<content id="" name="Foo" description="Test" version="100">
</content>

Using the Workshop tool

The Workshop tool is contained in the X Rebirth Tools. It's a command-line based tool, we don't have a GUI for it (yet). You'll need a command console to run it, and the easiest way to do it is to "Play" the X Rebirth Tools. This will open the Windows command prompt in the X Rebirth Tools folder, where WorkshopTool.exe is located.

Image AddedImage Added

Type WorkshopTool and press Enter. This will give you an overview of the available commands and switches. Don't be afraid, the tool will ask for confirmation before it uploads anything.

Publishing an extension

Important: You have to agree to the Steam Workshop Legal Agreement to upload any item to the Steam Workshop.

Imagine you have prepared an extension in the game's extension folder:

...\steamapps\common\X Rebirth\extensions\my first mod

You have also prepared a preview image (see above). It's called preview.jpg and you have put it in your extension folder ("my first mod"). Notice the lower-case folder name. Now it's time to run the WorkshopTool! Your command line to publish your mod will look like this:

WorkshopTool publish -path "..\X Rebirth\extensions\my first mod" -preview "..\X Rebirth\extensions\my first mod\preview.jpg" -buildcat

[You may also want to use the -tags switch, but tags are not implemented yet. Come back later to see if this has changed.]

You must be logged into Steam while the WorkshopTool is running.

So what is happening now?

  • We are not using the -foldername override switch here, so the WorkshopTool takes the actual folder name: "my first mod" (note that this is a bad name!)
  • We are not using the -contentdef override switch, so the WorkshopTool just takes the content.xml in the "my first mod" folder.
  • Since we haven't bothered to create catalog files manually, we use the -buildcat switch so the WorkshopTool does everything for us.
  • The catalog tool builds ext_01.cat / ext_01.dat, which will be included in the files to be uploaded. These catalog files will be deleted automatically when the WorkshopTool finishes. You can prevent the deletion with the switch [i]-keepcatfiles[/i], but in that case don't forget to update or delete the catalogs manually later!
  • The WorkshopTool validates the metadata in content.xml and shows some output. Please read it all and make sure there are no mistakes.
  • The tool will ask for confirmation: "Start upload to the Steam cloud (y/n)?" Type Y or N, respectively, and press Enter.
  • Just wait for the upload to finish. This can take some time. You can abort the upload with Ctrl+C.
  • When the upload finishes, some XML attributes will be written back to content.xml, most importantly the id attribute, which identifies the extension as a Workshop item.

 

After the successful upload you are asked if you want to open the Workhop item web page. You should do this for several reasons:

  • You may have to confirm the Steam Workshop Legal Agreement online.
  • Even after upload, the Workshop item will not be visible for other players yet. You will have to set the visibility on the Workshop item page (visible for everyone or only for friends)
  • On the item page you can directly change the title and description, without having to update your Workshop item.[/list]

 

If the web page tells you that the Workshop item does not exist, you are probably not logged in. Just log in to see your item.

If you want to come back to the page later, either create a bookmark in your browser, or run the WorkshopTool with the command showpage:

WorkshopTool showpage -path "..\X Rebirth\extensions\my first mod"

Usually, when you subscribe to an extension in the Workshop and start X Rebirth, it will be downloaded, potentially overwriting files from the previous version on the disk. This won't happen for your own extension because the WorkshopTool writes sync="false" into your content.xml after publishing. So you can safely keep your extension in the game folder while working on updates. (However, it's always a good idea to back up your files regularly.) If you want to enable synchronisation anyway, no problem: Go to the extension menu in-game, go to your extension and set "Updates" to "Yes".

A side effect of disabled updates is that X Rebirth will not update the name and description in your local content.xml when you change them on the Steam Workshop page. However, other players will see the updated name and description in their games.

Once players can see your extension in the Workshop, they can subscribe to it, and install it by starting X Rebirth. You disable the extension by unsubscribing from it. If players just delete the folder without unsubscribing, it will be downloaded again on the next game start.

If your extension has dependencies on other Workshop items, players have to subscribe to all of them manually, otherwise they will get an error message in the game. The dependency extensions will be shown in the in-game extension menu and can also be subscribed there.