From OpenLieroX Wiki

Jump to: navigation, search

Please add on any examples you wanna add. Simple, hard, just make sure to make it readable and all the code should be between <pre><code>text</code></pre> tags. ;)

Weapon Examples

Asrack's Basic Weapon Example
In this tutorial I will show you a a basic weapon example. This weapon will shoot a projectile file and explode when it hits the player. There will be two files to this weapon. The weapon file which we will name w_gun.txt and the projectile file which will be p_bullet.txt. For the sake of examples.

  • Weapon File - "w_gun.txt"
Name = Gun
Recoil = 0
Recharge = 2
Drain = 25
ROF = 250

Amount = 1
Speed = 300
Spread = 5
Projectile = p_bullet.txt
  • Projectile File "p_bullet.txt"
Colour1 = 0, 0, 0
Trail = TRL_NONE

Type = Explode
Damage = 1

Type = Explode
Damage = 3

Compile your mod after adding this to the main.txt and test it out. Very easy weapon. =)