aliens

Author Topic: Unit using builtInWeaponSets dropped no loot when dies. Intended feature or bug?  (Read 561 times)

Offline LobsterKing

  • Sergeant
  • **
  • Posts: 14
    • View Profile
Hi, I have units in my mod using builtInWeaponSets. When the unit was killed, it drops no loot. Only when it was stunted, then the loot it carries was dropped. Is this an intended feature that the unit dropped no loot unless it is stunted?

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 10209
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
No, such weapons should be dropped normally.

Check if they're not marked as built-in weapons.

Offline LobsterKing

  • Sergeant
  • **
  • Posts: 14
    • View Profile
I assume built-in weapons as weapons or items having   

fixedWeapon: true?

I don't have anything like this in the code for my items or weapons that's included within the builtInWeaponSets for my units.

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 10209
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Can you paste your code? It's hard to think of what could have gone wrong, because anything could have gone wrong. :)

Offline LobsterKing

  • Sergeant
  • **
  • Posts: 14
    • View Profile
Here is a sample of my code.

Code: [Select]
units:
  - type: STR_POLICE_MALE
    race: STR_CIVILIANGROUP
    rank: STR_LIVE_SOLDIER
    stats:
      tu: 45
      stamina: 65
      health: 30
      bravery: 80
      reactions: 40
      firing: 50
      throwing: 50
      strength: 24
      psiStrength: 5
      psiSkill: 0
      melee: 50
    armor: POLICE_MALE_ARMOR
    aggroSound: 951
    moveSound: 952
    deathSound: [41, 42, 43]
    standHeight: 21
    kneelHeight: 14
    value: 30
    intelligence: 4
    energyRecovery: 20
    builtInWeaponSets:
      - - STR_MAGNUM_CLIP
        - STR_MAGNUM  
items:
  - type: STR_MAGNUM
    size: 0.1
    costBuy: 800
    costSell: 600
    requires:
      - STR_MAGNUM
    weight: 2
    bigSprite: 753
    floorSprite: 628
    handSprite: 605
    bulletSprite: 1
    fireSound: 4
    compatibleAmmo:
      - STR_MAGNUM_CLIP
    accuracySnap: 60
    accuracyAimed: 70
    tuSnap: 35
    tuAimed: 60
    aimRange: 6
    snapRange: 3
    battleType: 1
    invWidth: 1
    invHeight: 2
    recoveryPoints: 2
  - type: STR_MAGNUM_CLIP
    size: 0.1
    costBuy: 70
    costSell: 52
    requires:
      - STR_MAGNUM
    weight: 1
    bigSprite: 754
    floorSprite: 629
    hitSound: 22
    hitAnimation: 26
    power: 45
    damageType: 1
    clipSize: 6
    battleType: 2
    armor: 12
    recoveryPoints: 2
alienDeployments:
  - type: STR_SMALL_SCOUT
    data:
      - alienRank: 0
        lowQty: 1
        highQty: 1
        dQty: 1
        percentageOutsideUfo: 50
        itemSets:
          -
            []
          -
            []
          -
            []
    width: 90
    length: 90
    height: 9
alienRaces:
  - id: STR_CIVILIANGROUP
    membersRandom:
      - [STR_POLICE_MALE]

There is a strong and specific reason that I did not include any weapons in the itemset for the small scout's alien deployment. I strongly wanting to use the unit's builtInWeaponSets to replace the itemset. The primary reason is because I wish to utilize the memberRandom feature in the alienRaces to the fullest, by having a lot of random units with their own builtInWeaponSets.  So I can have unpredictable encounters whenever a small scout is shot down.

My main problem is, if the enemy unit was stunted, all its items were recoverable.  If the unit was killed, all its items are missing but its corpse.
« Last Edit: February 04, 2021, 05:19:07 pm by LobsterKing »

Offline R1dO

  • Colonel
  • ****
  • Posts: 354
    • View Profile
Just to be sure.

While testing you did not accidentally had the "Alien weapons self-destruct" set (see attached screenclip)?

Offline LobsterKing

  • Sergeant
  • **
  • Posts: 14
    • View Profile
I can confirm that option was enable. It is the source of my ills. Thanks for the help everyone.