Author Topic: BlastRadius won't work!  (Read 4063 times)

Offline scarf

  • Sergeant
  • **
  • Posts: 27
  • hello world
    • View Profile
    • reddit page
BlastRadius won't work!
« on: January 20, 2016, 03:34:20 am »
Hello, I'm just new in here and I wanted to make a mod that adjusts blastRadius of AC/HE and HC/HE.
But when I change it, it really does not work.
When I set the blastRadius big, only one tile gets smoke/scorched ground. It does same when I set it -1.
But somehow  HWP cannon shell works normally. (It explodes 3x3)

P.s - HWP ammos are able to carry in custom battles... What the?)
P.p.s- Can you make "HWP cannon shell box magazine" So you can load 30 shots in a single item like "Cannon x50"? (the craft weapon)

Offline yrizoud

  • Commander
  • *****
  • Posts: 1014
    • View Profile
Re: BlastRadius won't work!
« Reply #1 on: January 20, 2016, 03:42:44 am »
The first thing that limits explosion range is damage : Damage is reduced by 10 for each tile travelled, until there's no effect. For example 60 - 50 - 40 - 30 - 20 - 10 - 0
OpenXcom's "blastRadius" can reduce this, but not increase it : The above explosion with blastRadius 2 will cause damage 60 - 50 - 40 and not affect units farther than that.

Offline scarf

  • Sergeant
  • **
  • Posts: 27
  • hello world
    • View Profile
    • reddit page
Re: BlastRadius won't work!
« Reply #2 on: January 20, 2016, 03:52:51 am »
Hmm... But when I use
-Autocannon HE
There's an explosion, but no scorched grounds, even no smoke
-Heavycannon HE
There's only one tile of scorched grounds and smokes.
But I did not change neither damage nor blastradius. Now it's getting weird.

Hey, here's my recent mod. Maybe you can check what's wrong.
« Last Edit: January 20, 2016, 03:55:56 am by pig005 »

Offline R1dO

  • Colonel
  • ****
  • Posts: 442
    • View Profile
Re: BlastRadius won't work!
« Reply #3 on: January 20, 2016, 11:32:04 am »
P.p.s- Can you make "HWP cannon shell box magazine" So you can load 30 shots in a single item like "Cannon x50"? (the craft weapon)

That's possible yes via the ``clipSize`` variable (and as of commit a78d79 it also works for box sizes other than 1 or the clipsize of the USO).
Just remember the following points:
  • Clipsize of the HWP:  Amount of projectiles the HWP can carry.
  • Clipsize of the box:  Amount of projectiles each box adds to the HWP.