- Edited
Alright, you want to start making your own mod, this is how you can do it.
List of needed things:
- Cosmoteer Example Mod
- Cosmoteer Data Folder
- Any text editor you want
- Any image editor you want
- Wiki https://wiki.cosmoteer.net/index.php/Modding:Modding_Main_Page
- This forum
- Ability to comprehend english
You begin by copy pasting example mod somewhere you want, preferably in folder where you can easily load it into game (your mods folder, lol)
Next step is to read comments in mod.txt of example mod. Its very informative for as long as you can read and comprehend english. For better understanding read it up to 10 times. Then you can safely remove actions outside of adding parts. Keep in mind, that data declarations use JSON-like format, so in situation like:
[{Action=AddWhatever}{Action=AddNotNeededWhatever}]
remove {Action=AddNotNeededWhatever}
so, whats left should be [{Action=AddWhatever}]
.
Armor is like hello world of modding, so, yes, this is what you should start with as its one of simplest parts possible. As basic armor template is already present, you can start modifying it. First, change the goddamn id of part, then you should change strings attached, but thats not necessary.
Next are sprites.
Here is list of sprites to make if you want your part to not look like made by caveman:
- Icon
- Blueprint
- Walls
- Floor
- Roof
But in case of parts you can ignore walls or floor, but keep the other and reuse same sprite, blueprint sprite should be tinted blue, but if you get colors bit wrong, its nothing fatal. As an option you can waste time and add damaged sprites, but its better to use same time to make quality doodads with animations for part, cuz players rarely look at damaged parts. After you add/modify text in strings en.txt, you done with armor. Speaking of doodads, here is list of additions to make your part look better:
- Doodads
- Lights
- Windows
- Roof doodads (yes, its not windows)
- Animations
Doodads can be found in any functional part, so, head to cosmoteer data folder and find shield generator, it also have lights, windows and roof doodads with animations.
Obviously making just armor isnt cool, so, lets add functional components. As you already encountered graphics in armor, you can start seeing patters and its good. So, lets make a turret. Obviously copy med cannon. Tho make sprites ready.
You will need number of component types:
- BatteryStorage (or any ammo you want)
- BatteryConsumer (crew need to deliver said ammo)
- Turret salvaged from med. cannon
- Lots of toggles salvaged from same med. cannon
- Bullet emitter
- Shot file salvaged from said cannon shot and moved in same folder as your cannon.
What you do next is move turret to center of part (simple math, half of parts size params in location)
Make shot ignore source ship by adding SourceShipCollisionDelay = 10.01
in hit component of bullet, remove all reminders, that crew must be in the part to make things simple to mod for now, cuz setting up coordinates is pain. Then you change bullet in bullet emitter component, in turret graphics, you will see actual barrel of gun, so, here goes barrel sprite. Remove stats declaration, its unnecessary for now, but definately good thing to have. And obviously change id, strings. Now you add your string in parts part of en.txt and it seems ready. If something crashes, use stacktrace to find error, its generally some stupid oversight, but keep your eyes peeled. Thats all, folks.