Fractal Softworks Forum

Please login or register.

Login with username, password and session length

Author Topic: Is there a way to disable hullmods for AI?  (Read 1002 times)

Hiroyan495

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Is there a way to disable hullmods for AI?
« on: July 12, 2020, 01:38:54 AM »

Is it possible to remove hullmods from the pool of those, that the A.I. can freely pick in their loadouts?
Logged

Mondaymonkey

  • Admiral
  • *****
  • Posts: 777
    • View Profile
Re: Is there a way to disable hullmods for AI?
« Reply #1 on: July 12, 2020, 01:45:38 AM »

Why not just remove it from faction "known hullmods" section?
Logged
I dislike human beings... or I just do not know how to cook them well.

Hiroyan495

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Re: Is there a way to disable hullmods for AI?
« Reply #2 on: July 12, 2020, 01:47:44 AM »

Oh, thank you very much. That was exactly the simple solution I was looking for. Bless you.  8)

Edit: What do the tags mean in those .faction files? Are they inclusive of a set of hullmods or do they have some other purpose?
« Last Edit: July 12, 2020, 01:55:41 AM by Hiroyan495 »
Logged

Mondaymonkey

  • Admiral
  • *****
  • Posts: 777
    • View Profile
Re: Is there a way to disable hullmods for AI?
« Reply #3 on: July 12, 2020, 02:19:51 AM »

Oh, thank you very much. That was exactly the simple solution I was looking for. Bless you.  8)

Edit: What do the tags mean in those .faction files? Are they inclusive of a set of hullmods or do they have some other purpose?

OK. Lets take an example. Why not hegs?

Spoiler
   "knownHullMods":{
      "tags":["base_bp", "hegemony"],
      "hullMods":[
         "advancedshieldemitter",
         "turretgyros",
         "armoredweapons",
         "augmentedengines",
         "autorepair",
         "expanded_deck_crew",
         "magazines",
         "missleracks",
         "extendedshieldemitter",
         "frontemitter",
         "frontshield",
         "heavyarmor",
         "insulatedengine",
         "targetingunit",
         "nav_relay",
         "operations_center",
         "fluxbreakers",
         "stabilizedshieldemitter",
         "frontshield",  # makeshift
         "surveying_equipment",
         "efficiency_overhaul",
      ],
[close]

List of "hullMods" determine the id of hullmods they know. Simple yet, right?

"tags" will add to this list all hullmods that have those listed tags. We have "base_bp" and "hegemony" tags. So, lets go to the hull_mods.csv and see which hullmods it is. OK that was bad example, as non of vanilla hullmods does not contain those  tags, but if they are - they would be added. Also, IIRC faction have access to all by-default allowed hullmods (true in unlocked column), which are:
Spoiler
Auxiliary Thrusters
Blast Doors
Dedicated Targeting Core
Flux Coil Adjunct
Flux Distributor
Hardened Subsystems
Reinforced Bulkheads
Safety Overrides
Unstable Injector
Additional Berthing
Auxiliary Fuel Tanks
Expanded Cargo Holds
Militarized Subsystems
[close]
Logged
I dislike human beings... or I just do not know how to cook them well.

Hiroyan495

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Re: Is there a way to disable hullmods for AI?
« Reply #4 on: July 12, 2020, 02:22:23 AM »

Daaaaamn, thanks a lot, you really took some of your time for me there, but it helped me understand a lot.  ;D
Logged

Mondaymonkey

  • Admiral
  • *****
  • Posts: 777
    • View Profile
Re: Is there a way to disable hullmods for AI?
« Reply #5 on: July 12, 2020, 02:31:59 AM »

Daaaaamn, thanks a lot, you really took some of your time for me there, but it helped me understand a lot.  ;D

Also, I have never seen someone actually used it, but FactionAPI.java contains some weird strings:

   void addPriorityHullMod(String modId);
   void removePriorityHullMod(String modId);
   boolean isHullModPriority(String modId);
   Set<String> getPriorityHullMods();
In other words, it possibly possible (sic!) to add priority section for hullmods:

Code
	"priorityHullMods":{
"tags":[],
"hullMods":[
],
},

Similar to other priority sections in faction file if you wish faction use that hullmod <almost> mandatory. Purely theoretical.
Logged
I dislike human beings... or I just do not know how to cook them well.