Basics[edit | edit source]
First, you will need to install a text editor or other program capable of reading and creating XML files. Atom and Notepad++ are two commonly used ones. Then, type the following. All of the other code for your mod goes between <init> and <init/>. Remember to use enter to separate lines, and use tab for all code between the two mod tags. Use tab twice for all code between the init tags.
<name>Think of a name for your mod<name/>
<description>Describe your mod<description/>
<author>Who made the mod<author/>
<version>Mod version number<version/>
To finish off your mod once you are done coding it, save the file under the name mod.xml. It is best to make a folder for it, so that if you make multiple mods, they don't accidentally overwrite each other. Then right-click on the mod.xml once it is in the folder, and click on send to and click on Compressed (Zipped) Folder. You cannot zip the folder that the XML file is in, you must zip the file itself. Name your Zip file whatever you want, most likely the name of the mod.
Defining Objects and Items[edit | edit source]
Now that you know how to make a basic mod, lets get started with making your mod do something. Remember, all of this code goes between the init tags.
Items[edit | edit source]
To define an item, you need to give it an ID. To do this, type <item id="your_item_id_here"> This is different from the command. You can add things to the item, such as type, weight, sell price, and other variables. We'll start with the most basic type of item, a resource. Replace what you just typed with <item id="your_item_id_here" type="resource">. To add weight and price, simply add weight ="10" (As an example) and cost ="700" (As an example). So, to recap, you can make a resource with 10 weight that sells for 700 coins by typing <item id="your_item_id_here" type="resource" weight="10" cost="700">. The types of items are: food; resource; equipment; tool; potion; object; spellbook; blueprint.
Objects[edit | edit source]
Objects are a lot more complicated. For them, you need to define the type of object. They also require many more animations and statistics to be put into them. There are 5 types of objects that you can make:
Vehicles[edit | edit source]
Vehicles such as the submarine or the jet are the first type of object that we will discuss. They need parameters for their type: boat, submarine, mining, flying, and spaceship. These define default statistics about your vehicle. If you do not add any, it will have ground as the default statistic. However, making a vehicle is a lot more complicated than all that, because you need to add animations for everything that it does, and a tilesheet for those animations. The easiest way to make a vehicle is by having it extend another vehicle. For example, say you wanted to make a car. The easiest way to do this would be to put <vehicle id="car" extends = "jeep"/> This would make your car vehicle identical to a jeep, except that you could not equip the jeep weapons on it. Now say that you wanted it to be able to mine. You would change it to <vehicle id="car" extends = "jeep" mine ="5"/> This makes it able to mine tiles with a mine strength of five. If you want to learn more about making vehicles, you should join the Aground discord and ask there.
Enemies[edit | edit source]
Enemies are made in a similar way to vehicles, but they won't have their own type. They need multiple parameters and animations as well. You can extend enemies, similar to ow you can extend vehicles. You can also make an enemy version of a vehicle using the same animation, but this is more complicated.
Trees[edit | edit source]
Trees are one of the most simple types. They need an animation, like everything else, and they also need drops and health.
NPCs[edit | edit source]
NPCs are extremely complex. If you want to make one, you should definitely extend one that already exists, and make the quests yourself. The easiest way to do this however, is to simply add quests to a pre-existing NPC and not bother with your own.
Other objects[edit | edit source]
The most simple type, other objects are generally not used in many places, except in the minigames. They don't need anything more than a basic definition and an animation.