• If you have a mod, tool or prefab, please use the Resources section. Click Mods at the top of the forums.

Need help adding new modifications.

Lako

Refugee
I am trying to create new modifications for wrench. I looked through xml and copied/modified some modifications, yet i failed to find proper item to refer recipe too.

As example:

modMeleeStructuralBrace - this entry is in item_modifiers.xml yet none existent separate as item in items.xml. Only part of schematic.

When I created "dummy" item to serve modification purpose I cant use it as modification for wrench.

Dummy item example:

<append xpath="/items">

<item name="modWrenchUpgrade">

<property name="HoldType" value="45"/>

<property name="Tags" value="junk"/>

<property name="Meshfile" value="#Other/Items?Misc/sackPrefab.prefab"/>

<property name="DropMeshfile" value="#Other/Items?Misc/sack_droppedPrefab.prefab"/>

<property name="Material" value="MsmallEngine"/>

<property name="Stacknumber" value="1"/>

<property name="Material" value="MmechanicalParts"/>

<property name="Group" value="Mods"/>

<property name="EconomicValue" value="1000"/>

</item>

</append>

Based of small engine obviously :) .

Recipe:

<recipe name="modWrenchUpgrade" count="1" craft_area="workbench" tags="learnable,workbenchCrafting">

<ingredient name="resourceForgedSteel" count="100"/>

<ingredient name="resourceGlue" count="20"/>

<ingredient name="resourceMechanicalParts" count="20"/>

<ingredient name="resourceElectricParts" count="100"/>

</recipe>

Item_modification.xml entry:

<append xpath="/item_modifiers/item_modifier">

<item_modifier name="modWrenchUpgrade" installable_tags="melee,perkSalvageOperations" modifier_tags="damageIron" type="attachment">

<property name="UnlockedBy" value="meleeToolWrenchSchematic"/>

<property name="Stacknumber" value="1"/> <property name="Group" value="Mods"/>

<property name="DropMeshfile" value="#Other/Items?Misc/sack_droppedPrefab.prefab"/>

<effect_group tiered="false">

<passive_effect name="DamageModifier" operation="perc_add" value=".2" tags="metal"/>

<passive_effect name="HarvestCount" operation="perc_add" value=".2" tags="salvageHarvest"/>

<passive_effect name="AttacksPerMinute" operation="perc_add" value=".2"/>

<triggered_effect trigger="onSelfEquipStart" action="AddBuff" buff="buffHarvestXPBalance"/>

<triggered_effect trigger="onSelfEquipStop" action="RemoveBuff" buff="buffHarvestXPBalance"/>

</effect_group>

<property name="PickupJournalEntry" value="augmentGunsTip"/>

</item_modifier>

</append>

Could someone nudge me in right direction as I am a bit confused by now. I created many other xpath mods without a hiccup yet item_modifiers baffle me in A18. Still learning of course.

Thanks

 
Not the best idea to replay to your own thread, but.

I have tried many ideas I came up with without any result, I wonder is if its even possible to add new modification to the game at that point.

Can someone who succeeded post a code used to create a new modification for any item, tool or weapon whatever?

Only thing left for me is to emulate someone wiser :)

Thanks in advance.

 
At work so I can't post my code but I have some custom weapon attachments in my Wasteland Weapons mod.

What exactly isn't working for you? Recipes for mods use the name from item_modifiers.xml. They don't need an entry in items.xml to work.

 
Thanks bdubyah,

I found the problem, got so pigeon holed into different part of xml where I thought the problem was, without noticing:

<append xpath="/item_modifiers/item_modifier"> <-- adding modifier to a modifier -.-

Of course I happily copy pasted that allover my other modifications....

Anyway all good now, time to write some good and interesting modifications.

I may come back with questions regarding workstations tools, when I get to them.

Who wouldn't like more efficient engine for cement mixer quicker operation ;)

Cheers

 
Back
Top