Jump to content

class specific armor, and no utility slot?


davidlallen

Recommended Posts

For the playable advent mod, I am trying to prevent the aliens from equipping human armor. For *weapons*, there is a class requirement system, but for armor, there is no class requirement. Has anybody else experimented with class specific armor?

 

I was able to add four armor types (one for each current alien type; of course the Viper has a "Viper Breastplate" armor type), and I can force the created alien soldiers to start with any items including this armor. So I can get the initial display correct. But, these armors don't show up in the locker (the picklist you get when you go to select a new armor type). So if I equip one of them with a human armor, say by mistake, then I can't put it back. I' mot sure why they don't show up.

 

I tried to hack something; in the loadout screen, I can check if the character template is an alien, and if so, I can disable the button to even bring up the locker. In UIArmoryLoadout, I can override UpdateEquippedList where it calls InitLoadoutItem and pass in a disabled reason (fourth argument). This works, but it's ugly. At the bottom of the post is an image showing how this works. Can anybody suggest a better way?

 

I have a related problem with viper spit. Viper spit is implemented as a grenade. I can't quite figure out how to limit this to one class. If I have a playable viper and I unequip its viper spit, then any human can equip it. The grenade is sneaking out of the viper's utility slot into the global locker list. If I could make armors with no utility slot, but still have this item in the viper's inventory, I *think* that would work. So my question here is, how can I make an armor with zero utility slots?

 

The screenshot shows one other problem; I have found several problems where the alien inventory items have the wrong image path. For example, the alien grenade graphics path in X2Item_DefaultGrenades.uc is:

Template.strImage = "img:///UILibrary_StrategyImages.InventoryIcons.Inv_AlienGrenade";
But it should be:
Template.strImage = "img:///UILibrary_StrategyImages.X2InventoryIcons.Inv_Alien_Grenade";

 

For each one I have to override the class function. My list of overridden classes keeps getting bigger. I haven't overridden the bayonet one, which is why it shows up with the rainbow broken img.

 

Finally, a side bump to this unanswered question; our mecs and mutons fill the screen in the armory and squad select screens, I want to zoom out:

http://forums.nexusmods.com/index.php?/topic/3865570-any-way-to-pull-back-camera-in-soldier-view/

 

http://i.imgur.com/4ZTdHG3.png

Edited by davidlallen
Link to comment
Share on other sites

Well, my hack for armors works well enough (a few lines change in UIArmory_Loadout.uc), and I did figure out class specific weapons in the loadout; the trick I had missed was adding the item into the HQ inventory.

 

I am totally stuck on how to prevent everybody from equipping viper spit. Any leads on class specific grenades?

 

I am also stuck on how to make the Chryssalid have zero utility slots. Surprisingly, setting eStatUtilityItems = 0 has no effect; there is still one utility slot.

Edited by davidlallen
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...