Jump to content

2016-05-12 Patch SDK Changes


davidlallen

Recommended Posts

  • Replies 75
  • Created
  • Last Reply

Top Posters In This Topic

so if you've made a class mod, you'll need to update your xcomclassdata.ini file

 

with new info like excludedAWC, ballowawc, allowedarmors, etc

 

Is there a tutorial on the matter or some kind of explanation? I have no idea what changed with the new patch, or what I need to change in my own mod.

Link to comment
Share on other sites

= Specialists can no longer receive the Phantom ability through the Advanced Warfare Center

 

I know that there are issues with Specialists and Phantom, but I'm curious if this change was made because those issues could not be resolved any other way, or because Phantom is generally undesirable on Specialists anyways. I have a Specialist with Phantom, and have noticed in the past that aliens can still see this unit. I wonder if I will need to manually change this unit's AWC ability now.

 

= Fixed an issue where grenades were causing environmental damage on their way to the target

= Fixed an issue where explosions would occur early

 

Hopefully they break windows still. But yeah, not having the explosion go off twice is just a nice visual fix to finally have (if it works).

 

= Fixed an issue where tooltips would not show when viewing the Options menu

 

If that means that MCM can now have tooltips, then I'm happy, because now those mod options can now have tooltips most likely!

 

 

There's only two new events that I noticed by quickly glancing through the SrcOrig:

= MissionObjectiveMarkedFailed

= There's a new event that can trigger ItemState.GetMyTemplate().ItemRecoveredAsLootEventToTrigger, so it's a custom event name. Why it's not just a generic event that has the item object passed in as a parameter to the event, I don't know.

 

 

There's "Unequip all weapons" code in place now, so no mods are necessary to remove weapons from soldiers. Considering that basically all mods are broken right now, these mods will probably be removing their unequip buttons soon. There's also unequip buttons in the individual soldier screens, so you can do this without being on the squad loadout/selection screen.

 

 

Each soldier has a "has seen AWC popup" property, so every time you cycle through a soldier you will see the AWC ability popup again. The code for granting the AWC abilities has also been moved out of the UIArmory_Promotion screens and instead is done every time a soldier ranks up. This also fixes the bug of allowing AWC abilities on PSI troopers by just changing screens. AWC abilities are still only given when you exactly meet the rank requirements.

 

 

Character bio text increased from 500 to 3000.

 

 

Looks like there's new code put in place to allow item construction to have alternative item requirements, though I've never touched this stuff before so I could be inaccurate.

 

 

New code to theoretically help prevent the action camera from being blocked.

 

 

Disorientation is now its own damage type? Not entirely sure how this effects things in practice.

 

 

New engine function DoesPackageExist() which I'm assuming lets you determine if the indicated mod package is loaded? Neat.

 

 

There's also other changes and bugfixes that are difficult to determine through the UnrealScript alone, since they are native changes. For instance, mimic beacons now no longer block pathing if they despawn on XCOM's turn. (Figures that as soon as I find a good workaround they fix it!)

Link to comment
Share on other sites

X2ItemTemplate.StartingItem no longer makes items infinite. If your mod adds a starting item, you must set bInfiniteItem as well, or the player will start with just 1 of the item in their inventory.

Edited by xylthixlm
Link to comment
Share on other sites

A note on manipulating cosmetic pawns...


In X2CharacterTemplate, was added :



var(X2CharacterTemplate) delegate<OnCosmeticUnitCreated> OnCosmeticUnitCreatedFn;

However, this is used when cosmetic attachment units are created on a unit -- e.g. gremlin. This doesn't work generically whenever a cosmetic pawn is created.


For that functionality, you need to use the :


//Trigger to allow mods access to the newly created pawn
`XEVENTMGR.TriggerEvent('OnCreateCinematicPawn', SpawnedPawn, self);

called in XComGameState_Unit.CreatePawn

Link to comment
Share on other sites

If both your game and SDK are up to date, then creating a new mod will give you all the new files. To see the changes is trickier. Hopefully you put aside a zipfile of the old files before updating. If so, then you can see the changes by performing a "diff" of the old and new files. Yes, it would be nice if the devs had given us some kind of changelog. We asked, anyway.

Edited by davidlallen
Link to comment
Share on other sites

steamapps/common/XCOM 2 SDK/Development/SrcOrig should contain the most recent version. The XCOM 2 SDK/Development/Src directory is just a temporary directory that is used as part of the compilation process.

 

I've heard some people say previously that when you make a new Default project in ModBuddy, that the newly created project doesn't include all of the appropriate, most-recently-updated Src files. In this case, you just need to set up the files yourself from SrcOrig. I think the issue is that they don't update the default example projects. All the code is available though, just in Development/SrcOrig instead.

Link to comment
Share on other sites

What do you mean by set them up by myself? Is there a way to overwrite whatever ModBuddy gets Src/XComGame?

 

And no davidallen, like I said creating a new mod doesn't give me the updated files at all. Apparently I've just been very lucky that none of my mods ever needed any code that was ever changed by a patch.

Link to comment
Share on other sites

Be darned!

 

UIUtilities_Image.uc has been given a weird update to a core function...

simulated static function string GetRankIcon(int iRank, name ClassName)
{
    local X2SoldierClassTemplate ClassTemplate;
    local string strImageName;

    ClassTemplate = class'X2SoldierClassTemplateManager'.static.GetSoldierClassTemplateManager().FindSoldierClassTemplate(ClassName);
    
    if (ClassTemplate != none && ClassTemplate.RankIcons.Length > 0)
    {
        strImageName = ClassTemplate.RankIcons[iRank];
    }
    else
    {
        switch (iRank)
        {
        case 0: strImageName = "UILibrary_Common.rank_rookie";            break;
        case 1: strImageName = "UILibrary_Common.rank_squaddie";        break;
        case 2: strImageName = "UILibrary_Common.rank_lieutenant";        break;
        case 3: strImageName = "UILibrary_Common.rank_sergeant";        break;
        case 4: strImageName = "UILibrary_Common.rank_captain";            break;
        case 5: strImageName = "UILibrary_Common.rank_major";            break;
        case 6: strImageName = "UILibrary_Common.rank_colonel";            break;
        case 7: strImageName = "UILibrary_Common.rank_commander";       break;
        case 8: strImageName = "UILibrary_Common.rank_fieldmarshall";   break;
        }
    }
    return "img:///" $ strImageName;
}

Unfortunately, this means my qUIck_RCP trick (via MCController) to re-color the Ranks simultaneously in multiple screens (instead of building up a gauntlet of UIListerners) no longer works.

What does anyone make of this?

 

Is it really "necessary" and if so, how would someone alter the following script to bring back its formal functionality??

class UIMCController_qUIckRG4 extends UIMCController;

simulated function QueueString(string Param)
{
    Param = Repl(Param, "img:///UILibrary_StrategyImages.GTS.", "img:///qUIck_GTS4_UILibrary.GTS.");
    Param = Repl(Param, "img:///UILibrary_Common.rank_", "img:///qUIck_RCP_UILibrary.rank_");
    Param = Repl(Param, "img:///UILibrary_Common.psirank_", "img:///qUIck_RCP_UILibrary.psirank_");
    super.QueueString(Param);
}

Not really asking for a fix to *MY* own stuff... but, it's a very strange design switch, AFAIC.

Edited by Zyxpsilon
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...