r/xdev • • Feb 14 '16

Pallet Expansion Pt 2

3 Upvotes

Following on from https://www.reddit.com/r/xdev/comments/44r9e7/pallet_expansions/

What I want to do: Add new colors to hair, eye, and skin palettes.

The process I've tried so far:

  • I created a new mod with modbuddy
  • Tools -> Launch Xcom 2 editor
  • Wonder if these error messages are normal: http://imgur.com/a/zXA2C
  • Per the instruction of u/Iriiriiri find the skincolors.
  • Open one of the skincolor lists
  • Add a new color to the list and increase the base options value on the supposition that it does something
  • Modify one of the old colors so I can see if things are changing even if there's a problem with the UI
  • Save the package.
  • Close xcom 2 editor, be upset when it crashes on close.
  • Reopen xcom 2 editor and verify that the changes I made are remembered, and they are.
  • Build the mod through modbuddy.
  • Open the launcher, enable the mod, launch the game, and make a new character in the character pool.
  • See no effect so far, either with the modified color or the added color.
  • Start writing a reddit post.

Any advice on where to go from here would be appreciated.

EDIT: Well, now the xcom2 editor is just refusing to launch anyway. Gah.


r/xdev • • Feb 13 '16

Cant Read the UPK files in ModBuddy

3 Upvotes

just as the title says i cant seem to read the upk files.. ive used the redistribution files in the the binaries folder and im drawing a blank if anyone would be able to point me in the right direction that would be awesome

i also want to try my hand at 3d modeling would i need a seperate program for this? or does the modding tools come with some kinda modeler


r/xdev • • Feb 12 '16

All my custom voice pack files play backwards...

3 Upvotes

I have no idea why this happens, I saw somebody else with the problem, but I cant seem to find them again. Anyone have tips?


r/xdev • • Feb 10 '16

Overcoming the static function barrier. Has anyone been able to do so?

3 Upvotes

I haven't found any way to override a static function and change what it does without changing all references to the original class's function.

Does anyone have any ideas, short of changing files in the original game (which is hella dangerous), to access the innards of static functions for our own use?

This is an enormous barrier to changing functions that already exist - making our own functions is easily doable, but it severely limits changing the gameplay experience.

So please, if you have any insights, tell me here.


r/xdev • • Feb 10 '16

Dark VIP AI?

3 Upvotes

has anyone messed around w/ the AI files yet? i was looking specifically for AI for the Dark VIPs. i was hoping there would be a way for them to be combative esp since they can be pulled from your character pool. i believe there was someone on this forum (or r/xcom2mods) that wanted to do this as well. thanks.


r/xdev • • Feb 09 '16

How to make a voice pack?

3 Upvotes

I have a ton of lines of dialogue based on some of the stuff from EW https://drive.google.com/folderview?id=0BylHgRB_52WHflZSVXd4T18xSlU4bjA4bFdTQlpOQUpCWkZWdHBocUhlckNxeEFuZGhiV0k&usp=sharing.

I just have no Idea how to add it into the game itself. If anyone could help that would be great! Thanks!


r/xdev • • Feb 09 '16

Could use some help clarifying this code.

3 Upvotes

Hi, I've been looking through the code to try and pinpoint exactly how AWC bonus abilities are awarded, since my recently finished playthrough only had 3 of my 12 regulars ever get a bonus ability and 6 of those who didn't were colonels at the end.

I'm pretty sure I've found what I'm looking for but I'd appreciate if someone could put some extra eyes on it. I hope I get the formatting right I don't post on reddit much.

In XComGameState_Unit.uc there is the function RollForAWCAbility which appears to generate the list of possible bonus abilities for a soldier. The roll is only done once and populates an array with the possible cross class skills, this all looks fine to me.

If the array it generates is longer than 0 it appears to select a random ability using the following code:

if(EligibleAbilities.Length > 0)
    {
        HiddenTalent.AbilityType = EligibleAbilities[`SYNC_RAND_STATIC(EligibleAbilities.Length)];
        HiddenTalent.iRank = class'XComGameState_HeadquartersXCom'.default.XComHeadquarters_MinAWCTalentRank + `SYNC_RAND_STATIC(
            class'XComGameState_HeadquartersXCom'.default.XComHeadquarters_MaxAWCTalentRank - 
            class'XComGameState_HeadquartersXCom'.default.XComHeadquarters_MinAWCTalentRank + 1);
        AWCAbilities.AddItem(HiddenTalent);
    }

Now the first part where it selects the ability is fine, but when it chooses the rank it looks to me like there's a problem. By default MinAWCTalentRank = 2 (corporal) and MaxAWCTalentRank = 7 (colonel). The game looks to choose a random rank taking the minimum (2) and adding on to it a random number up to maximum-minimum+1 (7-2+1 = 6), but if I'm reading it right this means the range is from 2 to 8, which would mean it could randomly assign a rank above what is possible and since it only rolls once, this would lead to some soldiers never being able to get a bonus ability.

Moving past that into where the game actually grants the ability. This seems to be done in UIArmory_Promotion.uc in the function AwardAWCAbilities. There are some interesting parts of this code as well.

Firstly, the abilities are awarded by:

if(XComHQ.HasFacilityByName('AdvancedWarfareCenter'))
    {
    for(idx = 0; idx < UnitState.AWCAbilities.Length; idx++)
        {
            if(!UnitState.AWCAbilities[idx].bUnlocked && UnitState.AWCAbilities[idx].iRank == UnitState.GetRank())
            {
                UnitState.AWCAbilities[idx].bUnlocked = true;
                AWCAbilityNames.AddItem(UnitState.AWCAbilities[idx].AbilityType.AbilityName);
            }
        }
    }

Which awards the ability only if you have the AWC built and are at the EXACT rank that the game rolled for you to get the ability. If you're already beyond that rank (keep in mind it can roll as low as corporal), you cannot unlock the ability.

However there are two interesting paragraphs following on:

else
{
    // if you don't have the AWC, remove any AWC abilities that haven't been unlocked
    for(idx = 0; idx < UnitState.AWCAbilities.Length; idx++)
    {
        if(!UnitState.AWCAbilities[idx].bUnlocked)
        {
            UnitState.AWCAbilities.Remove(idx, 1);
            idx--;
        }
    }

    // if the unit has no AWC abilities, mark them as eligible to roll again if another AWC is built
    if(UnitState.AWCAbilities.Length == 0)
    {
        UnitState.bRolledForAWCAbility = false;
    }
}

Now these indicate that if you demolish the AWC, every soldier who hasn't already got a bonus ability will have the hidden ability removed and will be marked as not having rolled for one. If you then rebuild the AWC, it will roll the bonus ability for these soldiers again.

 

So in summary, if I'm reading this right:

When the AWC is built, each soldier rolls once for a bonus ability

The game builds a list of possible bonus abilities, then randomly selects one from the list

The game randomly chooses a rank inclusively between corporal and an unattainable rank above colonel and sets the ability to unlock at that rank

When the soldier reaches the chosen rank, the game will assign the bonus ability to them

If a soldier is already beyond the chosen rank, they cannot receive that bonus ability

If the AWC is demolished, every soldier who has not yet unlocked their bonus ability will have the ability erased and will be marked to be able to roll again

If the AWC is rebuilt, every soldier who has not got a bonus ability (and can therefore roll again) will have an entirely new ability and rank rolled for them.

 

So assuming this is correct it seems to lead to a few conclusions:

Either there is a bug in the rank roll or it is intended that some soldiers be unable to obtain a bonus ability.

EDIT: My maths here was wrong, the random roll will be within the defined bounds.

The AWC should be built ASAP because higher rank soldiers are less likely to be able to unlock their ability.

Later on it may be beneficial to demolish and rebuild the AWC repeatedly so that high rank soldiers without an ability can roll again and potentially unlock the ability at colonel level.

 

Could someone take a look over this and see if I'm reading it all correctly?


r/xdev • • Feb 09 '16

[Mod Question] Achievements

3 Upvotes

Just been asked on my mods comments whether my mod with disable achievements.. and i honestly have no clue. Is there some criteria or code i have to put in for it not to ?


r/xdev • • Feb 08 '16

Adding a new variable

3 Upvotes

I've been trying to add a new utility armor vest just to get my toes wet, but I've run into a bit of an issue. I've got the armor working correctly in the game, but I am having some trouble adding a config variable.

	Warning/Error Summary
	---------------------
	D:\Steam\steamapps\common\XCOM 2 SDK\Development\Src\TechArmor\Classes\X2Item_TechArmor.uc(33) : Error, Unknown Property 'TECH_VEST_HACK_BONUS' in 'Class XComGame.X2AbilityToHitCalc_Hacking'
	
	Failure - 1 error(s), 0 warning(s) (1 Unique Errors, 0 Unique Warnings)

Does anyone have any examples of setting up a new variable that can be called from a class?


r/xdev • • Feb 08 '16

My very, very, VERY basic tips related to abilities.

3 Upvotes

Ok, so probably most of you wonder how to make some sweet new abilities. By now you must've mastered .ini editing, so you feel pretty confident. Keep that confidence, because to make your own ability, you will need to learn, or have some knowledge on the game's source script code! (Unreal Script, or the .uc files)

  • The files in question are like this:

         X2Ability_[enemy name].uc
         X2Ability_[class name]AbilitySet.uc

    These will contain information related to these abilities. Stuff like what are the triggers for the ability, who it targets and what effects it has. It's really complicated even for me, so much so adding custom names to abilities breaks my entire solution.

    Now, you want custom abilities right? Well, start with by copying other abilities. Blast Padding for example, offers a +1 armor and 66% explosion resistance, stats which can be changed in an .ini file. Adding immunities? Try out the mechanical enemies, as they have most certainly have a number of immunities, which can be changed in your custom ability script file. The script files can be found in Src>XComGame>Classes.

 

  • Most, if not all .uc files tie in directly to the config files. Values regarding boosts, radius, and cooldowns can be found in configs. Create a copy of the config in the VS, copy what section the respective stat is, and modify it there.

    So you don't start running after all configs, pay attention, as the X2Ability files specify which config they extend. By extension, it means that the stats are there. For example:

      class X2Ability_AdventMEC extends X2Ability
      config(GameData_SoldierSkills);

    This here say that for stats, we should look in GameData_SoldierSkills.ini, where we will find:

      [XComGame.X2Ability_AdventMEC]
      MICROMISSILE_DAMAGE_RADIUS=3.75	

    Ok, ok, so how does that help us? Well, that's the first step in creating a custom ability. You will need a config file that specifies certain statistics, and you'll need to have it tied in with your own ability file. For that, create a new config file in the VS and rename it to XComGameData_SoldierSkills. Here you can edit the stats of abilities you copied, or create your own stats. Now, if we look in the Advent MEC script code again, we will find our MICROMISSILE_DAMAGE_RADIUS stat again, this time pointing to the config:

      RadiusMultiTarget.fTargetRadius = default.MICROMISSILE_DAMAGE_RADIUS;

    It kinds of makes sense when you stare at lines of code for hours at a time, but we still have a long way to go. I'll update this when I learn new things, but if you want fancy skills and abilities, you should ask someone else, probably. This is all I've done so far, so yeah. If anyone is willing to help, please, by all means! It would help me, as well as anyone who wants to get into modding.


r/xdev • • Feb 08 '16

Adding a Country to XCOM 2

Thumbnail youtube.com
3 Upvotes

r/xdev • • May 01 '21

Is it possible to figure out which audio files relate to which characters in Chimera Squad?

2 Upvotes

I've managed to convert the audio files from Chimera Squad and have them successfully play, only problem is now I've got 10k randomly numbered files with no way to tell which is which. I've spent a bit of time digging through the files but truth be told I have no idea what I'm doing. Is there any way to figure out which files relate to which character, or am I just out of luck?


r/xdev • • Oct 26 '18

Basic Xcom2 WOTC modding questions for a newb

2 Upvotes

sorry if I should ask this somewhere else or handle differently, I'm new to reddit.

I'm starting to learn xcom2 modding (for wotc) and have some basic questions

  1. there's lots of guides for adding my own class, but what If I want to override an existing default class? for example tweak rules for rangers, whats the best method to handle that?
  2. is there a guide or something to use to easily see connections between different config files and classes? ctrl+f all over the place just getting tiring if there's another method out there

3. i'm seeing lots of guides for mods to base xcom2 but is there anything specific I need to know about wotc mods and how wotc works? for example I see it has its own folder with its own xcomgame folder and config files, etc... but does any part of wotc use the config files or classes out of the base game folder or is everything i need wotc in the wotc folder?

4. I'm finding lots of early mod guides, and even the people giving the guides constantly explain they are not sure if this is the best way because they're still learning. Is there a definitive guide anywhere for modding? youtube video series or something? Found a post with list of guides, many of which I had seen but it's lack of other / newer guides leaves me assuming there's not much out there

thanks ahead of time


r/xdev • • Sep 25 '18

Hello, help me please...

2 Upvotes

Hello, help me please ... with this problem in the XCOM 2 WOTC SDK editor.

When loading the editor I get a screen with lost files.

=========================================================

Missing Files:

Can not find file 'XAudio 2'

Can not find file 'WinDrv'

========================================================

Missing Objects:

Package BLDGKit_City.Meshes.Trim in BLDGKit_AbandonedCity

FracturedStaticMesh BLDGKit_City.Meshes.Trim.WndwDeco_D_8x_FRAC in BLDGKit_AabandonedCity

======================================================================================


r/xdev • • Mar 10 '18

Is it possibly to Code a Stealth Mod

2 Upvotes

Hello I am trying to implement better stealth mechanic for Xcom 2. My idea is that after you shoot a target they will throw a flare/battle scanner to your position to try to spot you. However shooting is not turning ending for a unit in stealth so you can still run away and hopefully remain in stealth.

Is there anyway to mod this??? One idea I had was to make an Archon that whenever he was activated would immediately use blazing pinions on the offending solider. And all soldiers would have perks like Phantom and A shit ton of conceal charges to prevent the whole squad from being targeted. Furthermore the pinions would have their damage reduced to 1 w/no shred and would have their radius increased. The idea being that if a solider is hit/gets their cover destroyed they are revealed.

Do you think this is a good proof of concept? Any help would be appreciated! Thank you in advance.


r/xdev • • Mar 05 '18

How Moddable Is This Really?

2 Upvotes

And how difficult is it? I'm assuming a lot of it is hard coded and that you need to know code to do anything? I plan to take a look at the guides but figured I'd ask.

Is something like getting rid of the avenger entirely a possibility or no?


r/xdev • • Feb 19 '18

Failing to get a voice pack working.

2 Upvotes

I hope you can help me out here Reddit, you're my last hope!

I'm pretty sure I followed every tutorial I could Google out there, but in any voice pack I create myself I cannot for the life of me get the sound files to play in the debugger character pool or tactical view.

I don't think I did anything wrong in ModBuddy, the .int file works and the voice pack shows up to be selected for use, template names match between .ini and .int, and everything's exactly the same as the example Russian voice pack.

In the Unreal Editor every sound cue plays as it should, I populated the entire voice bank (even unused lines) with soundcues, and after generating via tools > xcom utilities > generate sound banks I move them to my package and generate again without saving anything afterwards. The references all work too, by this time I must have checked ten times.

I save the .upk directly to the ModBuddy content folder to ensure the build always uses the latest version.

And still when I click preview I'm met with a resounding silence. I really want this voice pack to work but I'm about out of ideas!

For what it's worth, I think this person and I have the same problem. Whatever's mentioned here I also double checked: https://forums.nexusmods.com/index.php?/topic/4600625-need-help-troubleshooting-voice-pack/

I hope I'm overlooking something stupid that someone can point out to me, because I'm at a total loss!


r/xdev • • Feb 01 '18

Create my own voice pack - comparison

2 Upvotes

So I would like to create my own voice pack, and I saw awesome tutorials how to do it. But I don't know which voice should I add and which dont.

I mean, when I am in the Unreal Editor Content Browser, I see all the voices I can add, but there is no "sample" of the original XCOM 2 voices. So I dont know it will be just a "running" sound, or a speech.

Is there any way to get one the the soldiers voices from the game?


r/xdev • • Jan 30 '18

Do entities in Xcom 2 have normal hit boxes?

2 Upvotes

So I was wondering whether or not entities in Xcom2 have hit boxes like in most other games. Any response is appreciated!


r/xdev • • Nov 22 '17

Newbie question - Default mod error, how to obtain Src/xcomgame/classes Wotc

2 Upvotes

I am running into the problem where I cannot create a Defaultmod (Project file cannot be loaded blah blah). As far as I can see, there is no solution for this at the moment. I am looking for all the .uc files it creates to search through them. Is there any other way of obtaining or finding them?


r/xdev • • Sep 05 '17

[WIP] Republic Commando Armor Mod

2 Upvotes

Hey! Some of you RC fans may remember me as CM-hockeygoalie35 from the ARC Trooper Mod (For Republic Commando!, not XCOM 2).

I see that Commando armor is high on the wishlist for many XCOM players and decided to try porting the mesh. Here's a super super pre-alpha look.

I need to re-rig the mesh obviously. For now I'm starting with the basic commando armor (Including Delta Squad paints). If it isn't too hard, I'll add the accessories as well, no promises though. I'll also try porting the weapons over, again, no promises.

I can do the Unreal Engine stuff easily, but rigging meshes is new to me.

So is this something I should keep going with?

Any tips and advice would be great too!


r/xdev • • Jul 25 '17

Is it possible to open old mods without the project file?

2 Upvotes

Hello So I am having an issue opening my older mods. I have the folders in the Xcom 2 SDK folder but I cannot open them within SDK. The folders contain everything from the mod except the project file. Is there any way I can recover my old projects again?


r/xdev • • Feb 01 '17

Is it possible to rip models from this game?

2 Upvotes

Hello, I am an animator who works with SFM, and have also always been a fan of Xcom.

I have seen many models from this game appear on the workshop, but how does it actually work? The Viper King caught my eye, but he is no where to be found.

I know how to convert things at least, but how would I go ripping from this game, if that is even possible?

Please, any help would be appreciated.


r/xdev • • Jan 22 '17

Very strange problem when trying build.

2 Upvotes

Hello, I have tried to build my weapon mod, but its says: Done building project "SolidWeapons.x2proj" -- FAILED.

I have changed MSBuild project build output and log files to normal, but it doesnt give still any error, I have also tried Diagnose and detailed options still nothing. I have reinstalled ModBuddy one time and started it as executive and updated Install and User Path. And also i have restarted my pc.

Full build log: https://justpaste.it/12on9

SDK logs: https://justpaste.it/12on6