OpenXcom Forum

Modding => Work In Progress => Topic started by: Solarius Scorch on February 15, 2014, 06:32:31 pm

Title: How to make Plasma Beam consume Elerium?
Post by: Solarius Scorch on February 15, 2014, 06:32:31 pm
Hello,

As an attempt to balance aircraft weapons just a little, I tried to make Plasma Beam consume Elerium-115 as ammo. I didn't want to make special clips, I just wanted 1 shot cost 1 Elerium (so fully charging the weapon would take 100 Elerium).

What I have is:

Quote
craftWeapons:
  - type: STR_PLASMA_BEAM_UC
    clip: STR_ELERIUM_115
items:
  - type: STR_PLASMA_BEAM
    clipSize: 100

Sadly, whatever I do, it doesn't seem to work. If I have no E-115 on base, it says the cannon cannot be charged; howev er, if I do, no Elerium is used. Changing clipSize to 1 doesn't seem to change anything either.

Now, can Elerium be used as ammo directly? Or do I need to make some sort of big plasma cannon clip?
Title: Re: How to make Plasma Beam consume Elerium?
Post by: SupSuper on February 15, 2014, 09:59:46 pm
clipSize goes in the ammo (STR_ELERIUM_115), not the launcher.
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Solarius Scorch on February 15, 2014, 10:26:54 pm
clipSize goes in the ammo (STR_ELERIUM_115), not the launcher.

Aaaah, I see.
I hope it won't hutr Elerium in its other instances? :) (Fuelling ships etc.)
Title: Re: How to make Plasma Beam consume Elerium?
Post by: redv on February 15, 2014, 10:28:46 pm
Now, can Elerium be used as ammo directly? Or do I need to make some sort of big plasma cannon clip?

I use this ruleset:
Code: [Select]
craftWeapons:
  - type: STR_PLASMA_BEAM_UC
    ammoMax: 50
    rearmRate: 10
    clip: STR_ELERIUM_115
items:
  - type: STR_ELERIUM_115
    clipSize: 1

- Plasma beam can shoot 50 times.
- One Elerium piece uses for 10 shots.
- Full reloading of weapon take 5 hours.

Try something similar.
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Solarius Scorch on February 15, 2014, 10:32:39 pm
- Plasma beam can shoot 50 times.
- One Elerium piece uses for 10 shots.
- Full reloading of weapon take 5 hours.

Try something similar.

That's exactly what I was looking for! (You don't need so many shots anyway.)
Thanks, guys!
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Mr. Quiet on February 15, 2014, 11:24:19 pm
That's exactly what I was looking for! (You don't need so many shots anyway.)
Thanks, guys!
Don't forget to release it pleasee 8)
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Solarius Scorch on February 15, 2014, 11:46:19 pm
Don't forget to release it pleasee 8)

It's just redv's code above, so I can't really release it under my name. :)
But I can just attach it here...
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Mr. Quiet on February 16, 2014, 09:20:13 pm
Thanks as always, Solarius. I always imagined the Plasma Beam using up some Elerium.
Title: Re: How to make Plasma Beam consume Elerium?
Post by: Solarius Scorch on March 28, 2014, 02:34:57 am
Thanks as always, Solarius. I always imagined the Plasma Beam using up some Elerium.

Me too. The same goes for Hovertank/Plasma, actually.

EDIT:

I just wanted to say that this is my favourite mod of my own making (or at least design). It does wonders to the game economy; you no longer have hundreds of units of Elerium in every base, you have to fight fiercely to stay supplied. I love it!