Jump to content

Unlock all Decorative Armors for all Armors


marsec1

Recommended Posts

I found the function that maps character type to pawn, at least for soldiers, and in EW it is implemented in upk instead of native code.

 

The function is XGBattleDesc.MapSoldierToPawn:

static function int MapSoldierToPawn(int iArmor, int iGender, bool bGeneMod)

It's basically a big switch/case statement over iArmor, with conditionals for iGender and bGeneMod.

 

For example:

        case 59:
            if(iGender == 1)
            {
                return ((bGeneMod) ? 80 : 16);
            }
            else
            {
                return ((bGeneMod) ? 73 : 5);
            }
            break;

Simply changing both numbers for the ternary conditional with bGeneMod to the second case will result in soldiers always using the non-genemod armor pawn.

 

E.g.

return ((bGeneMod) ? 16 : 16);

So far my current game (end of June) I still don't have any genemods (went MEC route instead), and I don't really mind the genemod armor looks, so I'm not planning on working it all out, but if someone else does by all means go for it :)

Link to comment
Share on other sites

I found the function that maps character type to pawn, at least for soldiers, and in EW it is implemented in upk instead of native code.

 

The function is XGBattleDesc.MapSoldierToPawn:

static function int MapSoldierToPawn(int iArmor, int iGender, bool bGeneMod)

It's basically a big switch/case statement over iArmor, with conditionals for iGender and bGeneMod.

 

For example:

        case 59:
            if(iGender == 1)
            {
                return ((bGeneMod) ? 80 : 16);
            }
            else
            {
                return ((bGeneMod) ? 73 : 5);
            }
            break;

Simply changing both numbers for the ternary conditional with bGeneMod to the second case will result in soldiers always using the non-genemod armor pawn.

 

E.g.

return ((bGeneMod) ? 16 : 16);

So far my current game (end of June) I still don't have any genemods (went MEC route instead), and I don't really mind the genemod armor looks, so I'm not planning on working it all out, but if someone else does by all means go for it :smile:

 

I'm new to this whole xcom modding, so pardon my ignorance, but would you mind doing a step by step walkthrough of this? I'm tired of the gene-armor. I think it's fuggly.

Link to comment
Share on other sites

So, regarding the whole gene-mod armour situation, I thought I'd drop my finding in.

 

PLEASE NOTE THIS HAS NOT BEEN EXTENSIVELY TESTED

 

After digging about within XComGame.upk I came across a common theme with regard to genemod soldiers. Most of the checks regarding whether to use genemod skins or just normal skins was being determined by HasAnyGeneMod.

 

After finding this tidbit I went in search and was rewarded with XComPerkManager.HasAnyGeneMod, which basically states if any of the genemod perk values are greater than zero, then the solider has a genemod. This obviously leads to the various skins and decos being used etc.

 

Now I'ma bit useless at the whole tutorial malark but I can give it a bash at any rate. Fire up UE Explorer, open up a copy of XComGame.upk and navigate to XComPerkManager. Expand the funtions section and open HasAnyGeneMod. Right click that and select view buffer, this should give you the hex table for the code your viewing along with tooltips for all the tokens.

 

Now we get to the more complicated bit. Get a hex editor like HxD and open your copy of XComGame.upk Now, what you want to do is search with HxD using a hex string from HasAnyGeneMod; you can see these in the buffer window of UE Explorer. You'll need to search for a long enough string of characters that you only get one search result, that means you're in the right place. Now you want to find in UE Explorer all the tokens in HasAnyGeneMod that have the tag intzero. They should appear as 25 in hex code. Using HxD, you want to change the 25 to a 26, which will change the tag after you've saved the file to intone instead.

 

Now, since you can't have multiples of the same mod, you'll never have a value higher than 1. This will result in your gene mod soldiers looking exactly like your regular soldiers, deco and weapon kits et al. The only down side I've noticed so far is that your genemod soldiers lose the yellow symbol around their class symbol, but I think we can live with that :tongue:

 

Gonna go back to testing a bit but let me know if this is useful to you.

Edited by Decilete
Link to comment
Share on other sites

  • Recently Browsing   0 members

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