Adding a new Skill [SOLVED]

4 posts / 0 new
Last post
#1
Adding a new Skill [SOLVED]

Hello!

This is my first attempt on modding with little to no knowledge about it whatsoever and a minimal experience in programming.

I wanted to try and add another skill in Neo-Scavenger. So I decided to start out with a more powerful copy of the "Strong" skill so I can figure out how it works.

So I copied and modified the following:

A "condition" for the skill.
I modified the id as the immediate successor of the last one, and the names as well. Modifiers have been changed to make it obvious that it works. The rest remained the same.

Spoiler: Highlight to view
table name="conditions">
column name="id"847</column

column name="strName"StrongTEST</column

column name="strDesc"&lt;us&gt; is strongTEST, and can carry more than most.</column

column name="aFieldNames"m_fEncumberanceLimit,m_fMorale,AttDmgMult</column

column name="aModifiers"50,10.0,10.0</column

column name="aEffects"</column

column name="bFatal"0</column

column name="vIDNext"0</column

column name="fDuration"0</column

column name="bPermanent"0</column

column name="vChanceNext"0</column

column name="bStackable"0</column

column name="bDisplay"0</column>

column name="bDisplayOther"1</column

column name="bDisplayGameOver"1</column

column name="nColor"2</column

column name="bResetTimer"1</column

column name="bRemoveAll"0</column

column name="bRemovePostCombat"0</column

column name="nTransferRange"-1</column

column name="aThresholds"</column

/table

An "itemtypes" for the skill.
I changed the ID just as I did for the previous one. And the Subgroup ID to be the 20th skill, as the last one was 19. Also changed the description of the skill.
I also added a custom image (made the writing red so it can be obvious).
Inside the getimage folder I added an extra line so it can pick it up (and tested it with the normal Strong skill, the game picks it up and uses the image just fine).
The possessed conditions I made it 214=847, which is the ID of the condition. I saw almost every other skill had it this way. Not sure about this one.

Spoiler: Highlight to view
table name="itemtypes"

column name="id"519</column

column name="nGroupID"91</column

column name="nSubgroupID"20</column

column name="strName"skill: strongTEST</column

column name="strDesc"can carry A LOT more without being encumbered, melee attacks are A LOT more damaging, can create obstacle in combat</column

column name="strDescAlt"</column

column name="nCondID"1</column

column name="vImageList"ItmSkillStt.png</column

column name="vSpriteList"</column

column name="vImageUsage"0,0,0,0,0,0</column

column name="fWeight"0</column

column name="fMonetaryValue"0</column

column name="fMonetaryValueAlt"0</column

column name="fDurability"1</column

column name="fDegradePerHour"0</column

column name="fEquipDegradePerHour"0</column

column name="fDegradePerUse"0</column

column name="vDegradeTreasureIDs"3,3</column

column name="aEquipConditions"</column

column name="aPossessConditions"214=847</column

column name="aUseConditions"</column

column name="aCapacities"</column

column name="vEquipSlots"214</column

column name="vUseSlots"</column

column name="bSocketLocked"0</column

column name="vProperties"86</column

column name="aContentIDs"11</column

column name="nFormatID"5</column

column name="nTreasureID"0</column

column name="nComponentID"3</column

column name="bMirrored"0</column

column name="nSlotDepth"0</column

column name="strChargeProfiles"</column

column name="aAttackModes"</column

column name="nStackLimit"1</column

column name="aSwitchIDs"</column

column name="aSounds"cuePickup,cuePutdown</column

/table

And yet, after all this, when I start a new game I cannot see the new skill appear in the skill selection screen.

What else do I have to do? Is there anything I did wrong?

Thanks in advance for the help!

PS - This is not how the code looks inside the XML file. I modified it here so it won't interfere with the BBCode tags. :)

Solved!

After checking out the code a little more, I figured I had to add this in the "skill selection list" treasuretable along with the others. That was the last thing I had to do.

It now works.

Topic can be closed!

I am also trying to figure this out, but every single time I do this, I get a hang on "Updating template-based items. row:0"

It seems other people have solved it, but neglected to put how they actually solved it. Google has been of no help.

I attempting to add a new Flaw (i.e. Trait). I am directly copying the code for "trait: basic human" and modifying only the ID and nSubGroupID. In this case, ID 537 and SubGroupID 12. This throws up the above hang.

When I only create an override for the treasure table to add "Default" (i.e. Basic Human) into the Flaws list, this works just fine. But the instant I try to do anything of my own, it hangs.

I am literally just copy-pasting working code from the example mod and primary game XML and only changing IDs, and it's failing. Why?

EDIT / ANSWER:

Alright, so it looks like the reason this hang is occurring is because certain sections of XML MUST be referenced from the original data set (i.e. "0"), changing the following to include 0: prior to each string or value fixed the problem:

vImageList (otherwise you get a big red X)
vDegradeTreasureIDs
nFormatID
nTreasureID
nComponentID
aSounds (presumably, you get no sounds if this is not referencing the original data set)

For example, (column name="vDegradeTreasureIDs")0:3,0:3(/column)

I had that issue too but managed to figure it out. Sorry I wasn't here earlier to tell you :(

As for making the mod a different file, I suggest getting one of the bigger mods and taking a look at how they do it. It might be just what you need. That way you can share more easily!

Good luck!