Creating a new perk in the game

I Must Be Crazy 2

First time out of the vault
If I intend to make this perk obtainable through a quest, then:

1. Is there any restriction on the number that I assign to the perk in the perks.msg file?

2. Will I need anything else other than a new *.frm picture file and an editted perks.msg file for the perk?

3. How would I link the *.frm picture to the perk on the character screen?
 
Yes, I am well aware that this is an old thread ...

But what would be the method for doing this?

*EDIT*
This perk does not need to be one that can be assigned to a player but rather to a peice of armour. This is how the Power armour adds it strength and Radiation resistance. I need to get too make two new perks for

Evironmental Armour
+60% Rad resistance
+60% Poision resistance

Evironmental Armour MKII
+90% Rad resistance
+90% Poision resistance

Note: the above figures are the same as used in FOT
 
Temaperacl has a thing he found out about the perk system recently. Not sure if he's posted it here yet already. Either way, here it is:

Temaperacl said:
I believe I've figured out where Perks and Traits are stored, though (I haven't tested these in-game, so it might all be an elaborate mistake, but..):
Fallout2.exe
Traits: 0x10c184 (Just the location- I haven't looked at them any yet)
Perks: 0x1083cc (15A3A0 in mapper2.exe I believe)
Perks seem to have the following format (Up to Mutate! at least, after that it changes, and then seems to fall apart, so..):
Each perk appears to have the following format:

[00] - ? (Always 0000 0000)
[04] - ? (Always 0000 0000)
[08] - ID (Appears to be ID in PERK.MSG -29)
[0C] - Number of Ranks available.
[10] - Required Level
[14] - Stat Modified (entry in STAT.msg - 100) (FFFF FFFF = None)
[18] - Amount Stat Modified
[1C] - Skill 1 (SKILL.MSG - 100) (FFFF FFFF = None)
[20] - Amount for (in % points) Skill 1.
[24] - Type*
[28] - Skill 2 (SKILL.MSG - 100) (FFFF FFFF = None)
[2C] - Amount (in % points) for Skill 2.
[30] - Req. STR
[34] - Req. PER
[38] - Req. END
[3C] - Req. CHA
[40] - Req. INT
[44] - Req. AGI
[48] - Req. LUC

*- is 0000 0000 unless there are two skill entries (In these cases, it is a requirement I think) , in which case it looks like the entry is 0200 0000 if they are requirements and 0100 0000 if they are bonus (points the character gains).
(For the addiction perks, Ranks looks like it is always FFFF FFFF, and the Stat Req. Fields look like they are rather the change applied FEFF FFFF for -2 to the stat, for example.)

There are some problems- some perks are supposed to due more than can be encoded here, for example (Ignoring things that should be purely script based). For example, the Mr. Fixit should have requirements for 2 skills AND add points to 2 skills. In addition once we get past Mutate! / The Addiction entries, then the system appears to stop working as well- there are entries with the same ID's as earlier entries, and I'm not 100% sure all perks are accounted for. I'd guess (But it is just a guess with absolutely no backing yet) that multiple entries for a perk allow for the perk to do more than would be allowed with one entry. (Like the Mr. Fixit.)

In addition, I'm not sure about the ID- it works perfectly up through the addiction stuff, but it just seems odd to have it to be ID-29.
 
Well, maybe this is not a news. I've just added my new perk into the game.

Yes, this is for Mapper only (but all needed offsets can be found in FO too). Yes, this is not "adding" but "replacing unused". But it works.

The main idea is to replace unused "Mental block" with something that would be more use. Mental block was not comletely removed, BIS simply put 310 as needed level for this perk :-) How to change this:
1. 0x15abb4: replace [36 01] with [01 00] (min_level=1) or greater
2. replace fields with stats/skills being modified and modified ammount (see table two posts up). For example, replace this:
-----------------------------------------------
00 00 00 00-00 00 00 00 63 00 00 00
01 00 00 00 36 01 00 00-FF FF FF FF 00 00 00 00
FF FF FF FF 00 00 00 00-00 00 00 00 FF FF FF FF
00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
-----------------------------------------------
with this:
-----------------------------------------------
00 00 00 00-00 00 00 00 63 00 00 00
01 00 00 00 03 00 00 00-09 00 00 00 0A 00 00 00
FF FF FF FF 00 00 00 00-00 00 00 00 FF FF FF FF
00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00
-----------------------------------------------
This add 10 AC, perk has no stats/skills requrment and would be apear on level 3.

3. modify perk.msg by replacing lines 128/1128 with your perk name/description

4. replace .frm

This way you can only add the stats/skills bonus perks. Perks like Bonus Rate of Fire are strictly hardcoded and used directly in game algorithms.

I`m sure there is weapon perks somewhere in this perk table...

[EDIT]

Some additions to Temaperacl work:
>>[00] - ? (Always 0000 0000)
>>[04] - ? (Always 0000 0000)

This fields contains pointer on strings with perk name/description. Of course, they initialize only when game starts, in exe this fields are always filled with 0.

>>[08] - ID (Appears to be ID in PERK.MSG -29)

It`s a number of .frm for perk from art\skilldex\skilldex.lst (started from 0).

Now I search for this Type field. Seems to me that it`s a flag, which says to engine how other fields (stat/skill_1/skill_2) should be parsed.
 
Well, I checked out item perks. They work somewhat differ. Fields [30]-[48] for it is not requriments but bonuses/penalties to stats. Penalties:
0xFFFFFFFF == -1
0xFFFFFFFE == -2
0xFFFFFFFD == -3
and so on.

Still only on non-basic stat can be altered by perk so increase both rad and poiso resistances with one perk is not possible.

Example (Mapper.exe):
0x15b900 - start entry of unused item perk Armor Charisma
-----------------------------------------------
00 00 00 00 00 00 00 00 9A 00 00 00 FF FF FF FF
01 00 00 00 FF FF FF FF 00 00 00 00 FF FF FF FF
00 00 00 00 00 00 00 00 FF FF FF FF 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 00
00 00 00 00 00 00 00 00 00 00 00
-----------------------------------------------
replace with
-----------------------------------------------
00 00 00 00 00 00 00 00 9A 00 00 00 FF FF FF FF
01 00 00 00 20 00 00 00 64 00 00 00 FF FF FF FF
00 00 00 00 00 00 00 00 FF FF FF FF 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 FE FF FF FF 00 00 00 00
-----------------------------------------------

This perk increase char poison resist (20h=32=STAT_poison_resist) by 100 (64h=100) up to 95 and decrase his AG by 2 (FE FF FF FF=-2) and can be placed on any armor.
 
A new perk can be added by scripting too. Use a global variable to set the perk on or off. Use script commands to mod skills or traits or whatever. Then use the ununsed perk messages. There was some discussion about this:

http://www.nma-fallout.com/forum/viewtopic.php?t=11358&start=38

That would probably be easier than patching the executable to add new perks. However, you wouldn't be able to pick that perk on level up. If you can figure out how to add new ones that allow this, that would be very cool.
 
to dude_obj

>>A new perk can be added by scripting too.

You don`t understood. Script, added by *this* way is showed itself up into "Select new perk" window you gain every 3/4 levels. Its a real, full featured perk, not emulation like we did in New Vision with Shaman/Warior thing. I`m script a lot and I know how stuff like this can be organized :-)

>>That would probably be easier than patching the executable to add new perks. However, you wouldn't be able to pick that perk on level up.

Hm. Sorry for stupid line-by-line comments :-) Forgot all above :-)

How to add perks? Well, I think that is impossible. BUT. There is: Mental Block, Animal Friend, Children of Flowers, Alcogol_raised/lowered_HP (I think, this is a bug that was forgotten by BIS, don`t think that they planned this in final version), Autodoc_raised/lowered_HP (it`s a bug. There is no description for this perks).

It`s a 7 slots for your own perks. Also we can use perk, that used only in scripts or not used at all: Cult of Personality, Excriment Expiditor, Lte Step (forgot the name. Perk for avoiding traps). Also we can replace/modify unpopular ones: Snakeeater, Pack rat, Strongback and so on.

BTW, in Russia now moders make not addons but standalone mods - new mini games, that used fallout engine, resources and atmosphere but with new, standalone scenario, quests and so on. So ability to edit is apprecaited not less than ability to add.
 
Raven_2 said:
It`s a 7 slots for your own perks.

Cool! Well show us what to patch and how to use it, and we'll all be smiling. Hmmm, since we have virtual patchers, ideally the perk could be configured in a text file of some sort, which lists what traits are modified.

Raven_2 said:
in Russia now moders make not addons but standalone mods - new mini games, that used fallout engine, resources and atmosphere but with new, standalone scenario, quests and so on. So ability to edit is apprecaited not less than ability to add.

I have plans for one of these too. You start as a child before the bombs drop, you're the NACHLD character, out playing with other kids, when the sirens go off and adults take you to the vault. You spend some time there as a child, you fix a broken hover bot which becomes your "pet", and then gfade out and in ... time goes by and you're an adult about to leave the vault to do a bunch of quests. I didn't even plan to do this FO2 expansion, but I wanted something people can play right away and get replay value.
 
Hi. I've tried to add new perk according to Fallout Modification FAQ. Everything works but...
I have to modify 3 skills. And there are only two skill entries.

[1C] - Skill 1 (SKILL.MSG - 100) (FFFF FFFF = None)
[20] - Amount for (in % points) Skill 1
[24] - Type*
[28] - Skill 2 (SKILL.MSG - 100) (FFFF FFFF = None)
[2C] - Amount (in % points) for Skill 2

So I've decided to try it via OBJ_DUDE's critter_p_proc. It's very easy. But if dude chooses that perk, that skills are modified AFTER closing character window. Does anybody have an idea ?
 
In addition once we get past Mutate! / The Addiction entries, then the system appears to stop working as well- there are entries with the same ID's as earlier entries, and I'm not 100% sure all perks are accounted for..........................

Where are that entries with the same id ?
 
Hmmm - this might be something for Timeslip to look into. Having an easier way to add/replace perks/traits.
 
Back
Top