Author Topic: Multiple weapons per unit behaviour  (Read 4220 times)

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11728
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Multiple weapons per unit behaviour
« on: August 19, 2014, 01:17:03 pm »
It seems that if you define two or more weapons for the same unit, only one of these weapons is actually used, and the other(s) are ignored. It also seems that the game chooses the weapon at random.

Can someone confirm this please, or explain in greater detail how it works? Because I smell great modding opportunities (like making more weapon choices without increasing the number of loadouts).

Offline Falko

  • Commander
  • *****
  • Posts: 802
    • View Profile
Re: Multiple weapons per unit behaviour
« Reply #1 on: August 19, 2014, 01:26:01 pm »
no idea how it works
i think trying to determine how it works now is a waste of time since there will/need to be changes for tftd some time in the future

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11728
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Multiple weapons per unit behaviour
« Reply #2 on: August 19, 2014, 01:49:43 pm »
no idea how it works
i think trying to determine how it works now is a waste of time since there will/need to be changes for tftd some time in the future

Ah yes, because of the thermal lances.

I agree - making mods based on this assumption would be a bad idea...

Offline Harald_Gray

  • Colonel
  • ****
  • Posts: 142
    • View Profile
Re: Multiple weapons per unit behaviour
« Reply #3 on: August 19, 2014, 02:43:19 pm »
Well, I've tried this some time ago and then I've mind-controlled the aliens in question. Turned out the game doesn't even give the weapons to them, they didn't have them in their inventory. I didn't test the details of this behaviour because when I know the game only gives them one weapon, I saw no reason to question which one.

You can give the aliens a weapon, ammo and grenades, but that's about it. I've also tried giving them proximity grenades and while those do not disappear they are unable to use them.

I'm afraid this is the same as the aliens not being willing to use autofire if youre more than four steps away. We would need a new AI to be able to take advantage of the possibilities modding gives us. It would not have to be *that* smart but smarter that the current one and it would not behave as in the original game, so maybe we could suggest it as a new option. We have the Sneaky AI now and this one would be Trigger-happier AI  ;D

Offline LeBashar

  • Colonel
  • ****
  • Posts: 119
    • View Profile
Re: Multiple weapons per unit behaviour
« Reply #4 on: August 19, 2014, 03:28:15 pm »
I have also notice the secondary weapon is not given to the alien (I have try to give pistols to alien who have only heavy weapon like small launcher or blaster, but they have never the pistol in their inventory)

Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: Multiple weapons per unit behaviour
« Reply #5 on: August 19, 2014, 08:36:42 pm »
In my experience secondary weapons are not given to the AI... about 95% of the time. 5% of the time, the secondary weapon takes the place of the primary, which is baffling. And yes, any "irrelevant" ammo is discarded.
Oh, and in addition to Harald's list, you can also give aliens electroflares. They won't use them, but the items won't disappear.
This AI is actually very "smart": it knows better than the modder what an alien equipment loadout should look like :)