OpenXcom Forum

OpenXcom Forks => OpenXcom Extended (OXCE) => OXCE Suggestions DONE => Topic started by: krautbernd on August 24, 2019, 01:24:35 pm

Title: [DONE][REQUEST] Hide craft munition options that haven't been researched
Post by: krautbernd on August 24, 2019, 01:24:35 pm
Craft missile lanchers can support multiple ammunition types (e.g. vanilla avalanche launcher with researchable 'upgraded' avalanche missiles etc.). Right now, those missiles appear in the craft weapon list even if they aren't available / have not been researched.

Would it be possible to hide those entries until those munitions are actually unlocked / have been researched?
Title: Re: [REQUEST] Hide craft munition options that haven't been researched
Post by: Meridian on August 24, 2019, 02:27:06 pm
You can protect the purchase and/or the manufacturing of those missiles by research.
Title: Re: [REQUEST] Hide craft munition options that haven't been researched
Post by: krautbernd on August 24, 2019, 04:18:16 pm
You can protect the purchase and/or the manufacturing of those missiles by research.
Right now, those missiles appear in the craft weapon list even if they aren't available / have not been researched.

Would it be possible to hide those entries until those munitions are actually unlocked / have been researched?

The point is that they still appear as craft weapons even if they aren't available/haven't been unlocked if they use the same launcher as missiles that have been unlocked. Right now i would have to create a separate launcher for every missile, which undermines the concept of upgraded missiles. As far as i can tell the game should check whether or not a missile type has actually been unlocked before displaying it as an option.
Title: Re: [DONE][REQUEST] Hide craft munition options that haven't been researched
Post by: Meridian on October 07, 2019, 11:19:17 pm
Done.

Code: [Select]
ufopaedia:
  - id: STR_STINGRAY_UPGRADED
    listOrder: 650
    requires:
      - STR_MOTION_SCANNER
    type_id: 2
    section: STR_XCOM_CRAFT_ARMAMENT
    image_id: UP006.SPK
    text: STR_STINGRAY_UPGRADED_UFOPEDIA

items:
  - type: STR_STINGRAY_MISSILES_UPG
    listOrder: 250
    requires:
      - STR_MOTION_SCANNER
    size: 0.4
    costBuy: 3001
    costSell: 2401
    transferTime: 48
    clipSize: 1

craftWeapons:
  - type: STR_STINGRAY_UPGRADED
    sprite: 0
    sound: 5
    damage: 71
    range: 31
    accuracy: 71
    reloadCautious: 64
    reloadStandard: 48
    reloadAggressive: 32
    ammoMax: 7
    launcher: STR_STINGRAY_LAUNCHER
    clip: STR_STINGRAY_MISSILES_UPG
    projectileType: 0
    projectileSpeed: 8
Title: Re: [DONE][REQUEST] Hide craft munition options that haven't been researched
Post by: krautbernd on October 16, 2019, 04:42:18 pm
Thanks for implementing this, I totally missed your reply.