Weapons are the projectiles, beams and missiles used by ships to blast one another to little bits. Weapons are items, and their file names follow the format of wp_weaponname.ini.
All weapons need the line "TYPE weapon" in their .ini files.
Codes
The following commands and codes appear in the .ini files for items.
- NAME
- NAM2
- ICON
- GFXP
- FLAG
- tech - all the existing unmodded weapons have the tech flag, but it's not strictly required.
- DIST
- KEYS
- TEXT
- COST
- TYPE
- SIZE
Data Block:
Most of the functionality of a weapon is contained in the data block.
- DATA
- SPRI
- EMIT
- END DATA
- END
Nested / second-level entries on that list are flags or values that follow the first-level code before them. For example, you might have a line that reads "TYPE beam", but you wouldn't have a line that just says "TYPE" or just says "beam".
Things in bold are ones all main-game weapons have in common. It's highly likely you'll need them in your weapon file in order for it to function properly.