Support | News | Classic | F.A.Q. | Discord | Discussions | Wiki | Roadmap

I've noticed that some people have been struggling with creating mods, in this guide I will be explaining how to create a mod.txt, and make it appear in the mods list, in later guides I will teach you how to add a basic part, and start getting to more advanced things, like tabs, ship types, and inputs. Anywho, let's get started, shall we?

First of all, you need an 'IDE', an Integrated Development Environment, if you're just starting with making mods the standard program notepad can be enough, however, if you want to get serious with modding you might want to switch to notepad++ download, or Sublime Text download, personally I use notepad++, for which I made a highlighting package, if you want to use Sublime, Walt made a highlighting package for it.

Now that I've discussed the IDE, I will explain the main things in cosmoteer 'code', normal code looks like this:

// This is a Comment, use it to document your code
/* This is a multiline comment,
use it for when you need to write a longer comment without repeating // for each line
This closes it -> */

I will now start with a basic mod.txt, the main file of your mod. A mod can NOT exist without this file. First of all, you need to think of a name for your mod. Find the folder Documents/My Games/Cosmoteer/Mods, click the 'New Folder' button and pick a simple name for it, the standard naming convetion is: "author_name.mod_name", then double-click the folder, right click and create a new text document, it HAS to be named "mod.txt", type something like this in it:

ID = author_name.mod_name
Name="The Human Readable Name For Your Mod"
Version=major.minor.bugfix // All of those should be numbers
CompatibleGameVersions = ["Versions","With","Which","Your","Mod","Works"] // Like "0.14.4"
ModifiesMultiplayer = false // Should be true if you add any parts or other stuff that, well, modifies multiplayer
Author = "Human Readable Author Name"
Description = "Summary Of What Your Mod Does, And Why You Created It"
Actions /* Alter the games behaviour, no need for them if you just want your mod to show up, so just write an empty group */
[
]

Catelyn

Looks at Lafiel’s modding guide series.

Little nit pick since you used the term several times: Text editors are not IDEs and most don't strive to be. IDE would mean that all actions you take throughout mod creation are integrated with the tool. That starts with creating a new mod "project" with mod.txt and assisting in picking a unique name and ends with packaging the mod for distribution. In the middle there may be no text editor at all, but a visual environment where you have a list of parts with icons like in Cosmoteer itself and you edit their properties maybe with a color picker, sliders and text boxes. Actually, a good IDE would render this guide obsolete as it would not allow you to step into the potential pitfalls you outlined here.
That said, a text editor is nowadays expected to provide code highlighting, some form of grouping files into a project and very basic auto-completion, and that's still heaps better than using the default notepad.

    Write a Reply...