Author Topic: [Nightly Build] HWP Issues  (Read 16984 times)

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #15 on: July 09, 2015, 04:54:00 am »
Create a "dummy version" with the same power and the BigOb you intend to use, the article of which is unlocked exactly at the same time as the ammo, and the user will never know.

That's a trick I intend to use for weapons with more than 3 ammos as well. You unlocked the 2nd article  with any of the 4th+ ammo, in the same way the plasma cannon is unlocked by either the rifle or heavy).

Say heavy cannon:

Normal Heavy Cannon ufopaedia:
HC-AP
HC-HE
HC-I

Dummy Heavy Cannon ufopaedia (unlocked by either HC-A or HC-El):
HC-Alloy
HC-Elerium

Now you have a 2 pages UFOPaedia for the Heavy Cannon, showing the "same" weapon (the dummy having the same stats as the original), but different ammo and different text.

Ooh, that's some brilliant stuff.  That can solve the problem I am having with a few of the weapons having 5-6 ammo types.  I will have to play with this.

It's more I was creating UFOP articles for all the weapons and all the different types of ammo (I like writing up UFOP text, I have an issue, I know this) as shown below.  So when I extended that to include the ammo for HWP, it needed the HWP weapons to have a BigObs for the entry, which leads to the ammo lying on the floor of the skyranger.    I'm just gonna disable it for now.


Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #16 on: July 09, 2015, 04:58:04 am »
My improved HWPs were working fine until a month or two ago, then they started appearing on the equip screen and I had to change the settings (I also asked on the forums I think, I can't remember who provided me with the answer, unfortunately), so yes, something was changed most likely due to TFTD integration.

That explains things. I always knew that the two weapons thing was a semi hack (IIRC) that was left over from TFTD prep. 

What I really should do is get off my ass and add the entries to the wiki that explains how it's done.  Will be the first thing I do after I release the 2.0 beta version of my mod.

Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #17 on: July 09, 2015, 09:03:17 am »
Ooh, that's some brilliant stuff.  That can solve the problem I am having with a few of the weapons having 5-6 ammo types.  I will have to play with this.

It's more I was creating UFOP articles for all the weapons and all the different types of ammo (I like writing up UFOP text, I have an issue, I know this) as shown below.  So when I extended that to include the ammo for HWP, it needed the HWP weapons to have a BigObs for the entry, which leads to the ammo lying on the floor of the skyranger.    I'm just gonna disable it for now.

Check Piratez to see specifics (both multiple entries and working tanks, I had to fix them twice in the last few months). As for writing the articles, I agree - for it's the prize for finishing all the other work.

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #18 on: July 09, 2015, 05:26:00 pm »
HA! I should have known to check Piratez.. If anyone's gonna have crazy stuff, it's you ;)

So builtInWeapons defined in units, but only the auxiliary weapon, not the primary weapon (since it is already defined in the item I guess it's obvious that it should be there).

You need to list the ammo for the auxiliary weapon as well, but not for the primary weapon.

So:
1 weapon tank: Just define in items
2 weapons tank: define auxiliary weapon + ammo for auxiliary weapon in units

Offline Hobbes

  • Commander
  • *****
  • Posts: 2102
  • Infiltration subroutine in progress
    • View Profile
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #19 on: July 09, 2015, 05:27:08 pm »
HA! I should have known to check Piratez.. If anyone's gonna have crazy stuff, it's you ;)

FMP also has a lot of relevant code since Solaris adds a ton of new stuff to it.

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #20 on: July 09, 2015, 06:29:32 pm »
Very true!

But that one is.. *gasp* Actually, I wonder which is the craziest one...

Piratez VS FMP Ruleset(s) complexity competition! ;)

Probably XPiratez now.

Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #21 on: July 09, 2015, 06:33:31 pm »
Very true!

But that one is.. *gasp* Actually, I wonder which is the craziest one...

Piratez VS FMP Ruleset(s) complexity competition! ;)

Probably XPiratez now.

Doesn't matter which, Solar has copied all his HWP code from myself (except custom gfx, which was the other way around) :)

Offline Hobbes

  • Commander
  • *****
  • Posts: 2102
  • Infiltration subroutine in progress
    • View Profile
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #22 on: July 09, 2015, 06:47:26 pm »
Very true!

But that one is.. *gasp* Actually, I wonder which is the craziest one...

Piratez VS FMP Ruleset(s) complexity competition! ;)

Probably XPiratez now.

I like to check on both actually. Sometimes the differences between both regarding the same type of entries can be quite educating :)

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #23 on: July 11, 2015, 09:48:25 pm »
Check Piratez to see specifics (both multiple entries and working tanks, I had to fix them twice in the last few months). As for writing the articles, I agree - for it's the prize for finishing all the other work.

Diox, what's one of the weapons that have two entries in the UFOPedia?

Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #24 on: July 11, 2015, 09:55:06 pm »
In Piratez? STR_GRENADE_LAUNCHER & STR_ROCKET_LAUNCHER_ADV (both having a _FAUX version which allows for this Pedia trick).

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] Issues with HWP appearing in equip screen
« Reply #25 on: July 11, 2015, 11:06:34 pm »
In Piratez? STR_GRENADE_LAUNCHER & STR_ROCKET_LAUNCHER_ADV (both having a _FAUX version which allows for this Pedia trick).

I was looking for 'Dummy' and all this stuff, thanks for the tip!

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] HWP Issues
« Reply #26 on: July 14, 2015, 05:54:12 am »
Okay, new question.

Is there anyway to make the HWP weapons work like normal weapons in the fact of having 'magazines' for ammo?

If I have an Automatic Grenade Launcher as follows:

Code: [Select]
  - type: STR_TANK_AGLAUNCHER
    size: 6
    costBuy: 420000
    costSell: 320000
    transferTime: 96
    weight: 1
    bigSprite: 20326
    floorSprite: 0
    handSprite: 0
    bulletSprite: 9
    fireSound: 20334
    compatibleAmmo:
      - STR_HWP_AGLAUNCHER
    accuracyAuto: 40
    tuAuto: 40
    accuracySnap: 57
    tuSnap: 40
    accuracyAimed: 100
    tuAimed: 60
    maxRange: 200
    aimRange: 100
    snapRange: 35
    autoRange: 25
    minRange: 8
    dropoff: 2
    battleType: 1
    fixedWeapon: true
    invWidth: 2
    invHeight: 3
    turretType: 1
    arcingShot: true
    bulletSpeed: -1
    listOrder: 1120

and the Ammo as:

Code: [Select]
  - type: STR_HWP_AGLAUNCHER
    size: 1.5
    costBuy: 8000
    costSell: 6000
    transferTime: 24
    weight: 1
    #bigSprite: 20426
    floorSprite: 0
    handSprite: 0
    hitSound: 0
    hitAnimation: 0
    power: 55
    damageType: 3
    clipSize: 48
    battleType: 2
    blastRadius: 3
    invWidth: 2
    invHeight: 3
    listOrder: 1121

It seems to want me to have 48 individual instances of the STR_HWP_AGLAUNCHER ammo in my stores before I can equip it.

Is there any way around this?

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11722
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: [Nightly Build] HWP Issues
« Reply #27 on: July 14, 2015, 03:13:49 pm »
If you mean buying HWP ammo in clips, then no, sadly it's impossible.

I also dislike having to buy my tank ammo separately, especially for the Minigun HWP (which takes 200 bullets...).

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] HWP Issues
« Reply #28 on: July 14, 2015, 04:45:38 pm »
If you mean buying HWP ammo in clips, then no, sadly it's impossible.

I also dislike having to buy my tank ammo separately, especially for the Minigun HWP (which takes 200 bullets...).

That's a big box of yuck and what I kinda expected. That's gonna be a massive pain for my GMG tank much like with your minigun.

Strangely enough, it seems that the aux weapon does use ammo in clips, but I'll need to reconfirm.
« Last Edit: July 14, 2015, 05:13:25 pm by KingMob4313 »

Offline KingMob4313

  • Commander
  • *****
  • Posts: 543
  • Never let me down again.
    • View Profile
    • Mod Hub for Equal Terms 2.0
Re: [Nightly Build] HWP Issues
« Reply #29 on: July 15, 2015, 05:16:43 am »
That's a big box of yuck and what I kinda expected. That's gonna be a massive pain for my GMG tank much like with your minigun.

Strangely enough, it seems that the aux weapon does use ammo in clips, but I'll need to reconfirm.

Talking to myself again.

It seems that the Aux weapons do work on a clip system. I only bought 1 'box of ammo' for the secondary SMG on my Auto Grenade Launcher tank and it had the proper 250 rounds on it.