XCOM 2
[WOTC] PGO: Custom Projects & Bridges
Praefectus 18 Oct, 2020 @ 1:38pm
Crafting Light Shiv/Alloy Shiv.
As the current Shiv mod for some unknown reason cannot be edited-As in even if I know the location of the resource costs and edit them, they don't reflect in the game I am trying to make an alternative version to build them.

For now I did try to follow the instructions given with this:
+arrCreateCustomProject=(TechName="CraftShiv", SortingTier=0, bRepeatable=true, Rewards[0]="intshiv", TechImage="img:///UILibrary_StrategyImages.ScienceIcons.IC_shiv")
+arrCreateCustomProject=(TechName="CraftAlloyShiv", SortingTier=0, bRepeatable=true, Rewards[0]="intshiv2", TechImage="img:///UILibrary_StrategyImages.ScienceIcons.IC_shiv")
On the step 1
Step 2
[CraftShiv X2TechTemplate]
PointsToComplete=100
Cost=(ResourceCosts[0]=(ItemTemplateName="Supplies", Quantity=20), ArtifactCosts[0]=(ItemTemplateName="EleriumCore", Quantity=0))
[CraftAlloyShiv X2TechTemplate]
PointsToComplete=100
Cost=(ResourceCosts[0]=(ItemTemplateName="Supplies", Quantity=20), ArtifactCosts[0]=(ItemTemplateName="EleriumCore", Quantity=0))
Step 3
[CraftShiv X2TechTemplate]
DisplayName="Build Light Shiv"
Summary="Build a robotic shiv unit. The S.H.I.V. (Super Heavy Infantry Vehicle) is a weapons platform that can be manufactured in the proving grounds. S.H.I.V.s can be deployed as substitutes for human soldiers on missions and require a space in the XCOM HQ barracks."
[CraftAlloyShiv X2TechTemplate]
DisplayName="Build Alloy Shiv"
Summary="Build a robotic alloy shiv unit. The Alloy S.H.I.V. is a weapon platform that can be manufactured in the proving grounds. It is an variant model of the standard S.H.I.V., with superior armor and the capacity to serve as mobile cover for soldiers."

No issues related about not seeing the icon or the thing on the PG, the issue was crafting the actual item. It didn't show up in my barracks, which means 'intshiv' isn't the actual Shiv for crafting.
For reference this is the line to create a light shiv on the base mod.
static function X2DataTemplate makeshivTemplate()
{
local X2TechTemplate Template;
local ArtifactCost Resources;

`CREATE_X2TEMPLATE(class'X2TechTemplate', Template, 'intshiv');
Template.bRepeatable = true;
Template.PointsToComplete = 720;
Template.bProvingGround = true;
Template.strImage = "img:///UILibrary_StrategyImages.ScienceIcons.IC_shiv";



Template.ResearchCompletedFn = ResearchCompletedfbbg;



Resources.ItemTemplateName='supplies';
Resources.Quantity=25;
Template.Cost.ResourceCosts.AddItem(Resources);

return Template;
}
And the source mod itself is this one. https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=1527642618
Last edited by Praefectus; 18 Oct, 2020 @ 1:39pm
< >
Showing 1-7 of 7 comments
Hotl3looded  [developer] 18 Oct, 2020 @ 2:07pm 
What is the cost you want for the shiv project? we will try to alter the cost before doing the workaround of a second project.
Praefectus 18 Oct, 2020 @ 2:10pm 
Right now the default price is like 80 for each, with the latter also costing alien alloys. But as I have a buttload of mods going, it is kinda difficult to keep that price, especially when you also have to pay for the weapon squad upgrades.
So I want to have them both costing 20 supplies.
I also wanted to make the Shiv's weapons to have attachment slots, but again, for some reason the mod doesn't let me do that. For now the only thing I could alter on it were basic stuff like changing weapon damage, adding utility slot, letting the class bound with others and get AWC abilites.
But anything gear-related is a no-go and I can't figure out why those changes aren't applied even with me editing them.
Last edited by Praefectus; 18 Oct, 2020 @ 2:12pm
Hotl3looded  [developer] 18 Oct, 2020 @ 4:18pm 
You cannot edit a mod's code directly as it needs to be compiled by the SDK for the changes to work. Only variables in config files can be changed without the SDK.

So if the mod author did not include the variables you want to change in his config files, you have to use another mod or create your own to change stuff.

The changes you want have nothing to do with PGO so I am not sure why you are asking here... but try this in WSR - Configuration (in the config file):
+CHANGE_TEMPLATE=(TEMPLATE="intshiv", TECH_TEMPLATE=True, PROVING_GROUNDS_PROJECT=1, RESOURCE_COSTS[0]=(ItemTemplateName=Supplies, Quantity=20))
Praefectus 18 Oct, 2020 @ 4:25pm 
Yikes, that blows. I thought it could be changed by editing the SRC folder as it does have the supply cost for creating Shivs in one of the files.
And yeah, I know the other changes have nothing to do with PGO, I was just saying that the main issue is the cost as it does pile up with these other issues related to gear. But I assumed PGO bridge could be useful to at least create a new project with the Shiv's price lowered.

But I will try that suggestion of yours, assuming you meant to add that to Xcomweaponskinreplacer ini file in the config folder of WSR.
Praefectus 18 Oct, 2020 @ 5:11pm 
I can confirm your suggestion worked both on the light and alloy shiv, as for the latter I just had to rename 'intshiv' to 'intshiv2' on that change template you showed. Now I might read into how to decrease the production time as it is always set to 3-4 days it seems.
Something like this?
+CHANGE_TEMPLATE=(TEMPLATE="intshiv", TECH_TEMPLATE=True, PROVING_GROUNDS_PROJECT=1, POINTS_TO_COMPLETE=100))

Edit: Tested and can confirm it worked. Thanks again, dude! I am kinda code-illiterate so I do appreciate you took your time to hlep.
Last edited by Praefectus; 18 Oct, 2020 @ 7:00pm
Hotl3looded  [developer] 18 Oct, 2020 @ 7:51pm 
Np mate! just a tip, you can alter various things with the same entry. So you can add "POINTS_TO_COMPLETE=100" to the first entry that changes the cost. Like this:
+CHANGE_TEMPLATE=(TEMPLATE="intshiv", TECH_TEMPLATE=True, PROVING_GROUNDS_PROJECT=1, POINTS_TO_COMPLETE=100, RESOURCE_COSTS[0]=(ItemTemplateName=Supplies, Quantity=20))

Last edited by Hotl3looded; 18 Oct, 2020 @ 7:51pm
Praefectus 18 Oct, 2020 @ 9:45pm 
Oh, I see. For now I might keep them separated in case I do end up editing further. For now I am trying to figure out how to edit items you build on the engineering part.
I tried +CHANGE_TEMPLATE=(TEMPLATE="Cannon_SHIV_M3", SCHEMATIC_TEMPLATE=True, PROVING_GROUNDS_PROJECT=-1, RESOURCE_COSTS[0]=(ItemTemplateName=Supplies, Quantity=20))
But it is a no-go. I know that the schematic template is needed as the description points out it is exactly when you want to edit stuff involving squad upgrade.
< >
Showing 1-7 of 7 comments
Per page: 1530 50