[Tutorial] New Guide on creating weapons

Discuss and distribute tools and methods for modding. Moderator - Grognak
User avatar
Auron1
Posts: 224
Joined: Thu Sep 01, 2016 7:34 pm

Re: [Tutorial] New Guide on creating weapons

Postby Auron1 » Wed Sep 28, 2016 1:33 pm

I would like to know if I can create a laser which works as described below:
shot #1 → 1 bullet
shot #2 → 2 bullets
shot #3 → 3 bullets
shot #4 → 3 bullets
and so on

It seems a "charging" weapon, but instead of firing faster it shoots more bullets for each volley. :?:
Thanks
Has anyone ever considered a Warhammer 40,000 Mod for this game? It would be awesome!
User avatar
Sleeper Service
Posts: 2305
Joined: Sun Mar 24, 2013 8:49 pm

Re: [Tutorial] New Guide on creating weapons

Postby Sleeper Service » Wed Sep 28, 2016 1:51 pm

I think someone listed finding of what can be affected by the <boost> tag in chain weapon, but I can't find it anymore. Your best bet is trying it out yourself. Give a chain vulcan to the starting ships and change its <boost> tag to affect <shots> instead of cooldown and see if that works. Like this:

Code: Select all

<boost>
   <type>shots</type>
   <amount>1</amount>
   <count>3</count>
</boost>
User avatar
Auron1
Posts: 224
Joined: Thu Sep 01, 2016 7:34 pm

Re: [Tutorial] New Guide on creating weapons

Postby Auron1 » Wed Sep 28, 2016 3:43 pm

Sleeper Service wrote:I think someone listed finding of what can be affected by the <boost> tag in chain weapon, but I can't find it anymore. Your best bet is trying it out yourself. Give a chain vulcan to the starting ships and change its <boost> tag to affect <shots> instead of cooldown and see if that works. Like this:

Code: Select all

<boost>
   <type>shots</type>
   <amount>1</amount>
   <count>3</count>
</boost>


Cool, I'll give it a shot!
thanks :mrgreen:
Has anyone ever considered a Warhammer 40,000 Mod for this game? It would be awesome!
User avatar
Auron1
Posts: 224
Joined: Thu Sep 01, 2016 7:34 pm

Re: [Tutorial] New Guide on creating weapons

Postby Auron1 » Thu Sep 29, 2016 10:27 am

Metzelmax wrote:Overview value tags:

Code: Select all

<type> //declares type of weapon (possible: LASER, MISSILE,BOMB,BEAM) (all)
Only difference between missile and Laser is that Missile projectiles are not animated
<damage> //how much Hull damage a shot does (all)
<ion> // how much ion damage a weapon does (all, buggy on the beam ie will deplete any shields regardeless of rooms hit
<sysDamage> //how much damage it will do to a system (all)
<persDamage> // how much damage it will do to crew (all) minus values heal but apparently only on bombs
<shots> // how many shots it fires (only Missile, Laser, Bomb)
<sp> // How many shields it pierces (all,but useless on bombs)
<fireChance> //how high the chance of fire is (between 0-10) (all)
<breachChance> //how high the chance of a breach is (between 0-10) (all)
<cooldown>// the cooldown of the weapon (all)
<power> //the amount of power needed to power the weapon (all)
<cost> //how much a weapon costs to purchase (all)
<missiles> // how many missiles a weapon needs to fire (all)
<speed> //how fast a weapon shot flies (by a beam it's the speed it goes over hull) (all)
<length> //how long a beam is (beam only)
<hullBust> //determines whether the weapon does 2x times damage on systemless rooms.(0-1 only) (all)
<lockdown> //the crystal lock-down thingy... I shouldnt work on beams, but never tried it myself (all but beams)
<rarity> //how rare it is (0-5) (all)
       
<explosion> //adds a explosion animation to the weapon when hitting (laser missile bomb)
 <image> //projectile image/animation for the weapon (Beam contact image on beams) (all)
<weaponArt> // the weaponart for the gun attached to your ship itself (all)


You can add those tags in any order into the weaponsblueprint. It would just look better if the damaging values were at the top and graphics at the bot.


Maybe it has been said somewhere, but when looking at some recently-made weapons, there are some other tags unlisted here:

Code: Select all

<radius> //target area: a bigger number means a bigger hit-zone
<stun> //unclear if it is the % to stun or the stun duration - anyway, the other tag is unlisted above
<drone_targetable> //probably if defensive drones can aim/fire against shots; likely is only 0-1
<spin> //unknown


Can anyone help me explaining how those work?
Has anyone ever considered a Warhammer 40,000 Mod for this game? It would be awesome!
User avatar
Sleeper Service
Posts: 2305
Joined: Sun Mar 24, 2013 8:49 pm

Re: [Tutorial] New Guide on creating weapons

Postby Sleeper Service » Thu Sep 29, 2016 10:46 am

Code: Select all

<radius> //target area: a bigger number means a bigger hit-zone
This is used for flak weapons for example, the value defines how large the hit radius for the individual projectiles is. Larger radius makes the weapon less likely to hit the targeted room or hit at all if few rooms are adjacent to the targeted room. Uses pixels as unit. For reference: A room tile is 35x35 pixels large.

Code: Select all

<stun> //unclear if it is the % to stun or the stun duration - anyway, the other tag is unlisted above
This is the stun duration. Stun chance is defined as <stunChance>. If <stunChance> is omitted but <stun> is present in the blueprints, stun chance will default to 10 (100%). Look at stun ions and heavy lasers for examples.

Code: Select all

<drone_targetable> //probably if defensive drones can aim/fire against shots; likely is only 0-1
Yep, works as described. Mostly used to make flaks weapons drone targetable. "MISSILE" type weapon seem to be drone targetable by default, although I think one can make a missile untargetable by using this tag at 0...

Code: Select all

<spin> //unknown
Since AE, projectiles can spin as they travel, defined by this tag. Look at Flak weapons for an example. I think the value is degrees per second.
User avatar
Auron1
Posts: 224
Joined: Thu Sep 01, 2016 7:34 pm

Re: [Tutorial] New Guide on creating weapons

Postby Auron1 » Thu Sep 29, 2016 11:50 am

Sleeper Service wrote:

Code: Select all

<stun> //unclear if it is the % to stun or the stun duration - anyway, the other tag is unlisted above
This is the stun duration. Stun chance is defined as <stunChance>. If <stunChance> is omitted but <stun> is present in the blueprints, stun chance will default to 10 (100%). Look at stun ions and heavy lasers for examples.


Stun duration - indicated in seconds, right?

Thanks for solving my doubts :D
Has anyone ever considered a Warhammer 40,000 Mod for this game? It would be awesome!
User avatar
stylesrj
Posts: 3644
Joined: Tue Jul 08, 2014 7:54 am

Re: [Tutorial] New Guide on creating weapons

Postby stylesrj » Thu Sep 29, 2016 7:09 pm

So you can't have a weapon that say has a 10% stun chance, but stuns the enemy for about 30 seconds when it does work?
User avatar
Sleeper Service
Posts: 2305
Joined: Sun Mar 24, 2013 8:49 pm

Re: [Tutorial] New Guide on creating weapons

Postby Sleeper Service » Thu Sep 29, 2016 8:12 pm

Yeah, should be possible. Not completely tested though. If <stun> is unassigned it defaults to five seconds I think. That how it works for heavy laser as far as I remember.
User avatar
Auron1
Posts: 224
Joined: Thu Sep 01, 2016 7:34 pm

Re: [Tutorial] New Guide on creating weapons

Postby Auron1 » Thu Sep 29, 2016 8:13 pm

stylesrj wrote:So you can't have a weapon that say has a 10% stun chance, but stuns the enemy for about 30 seconds when it does work?


According to what Sleeper said, you can have a weapon with such effect:

Code: Select all

<stunChance>1</stunChance>
<stun>30</stun>


should do the work
Has anyone ever considered a Warhammer 40,000 Mod for this game? It would be awesome!