Talk:Perk Entry Point

From the CreationKit Wiki
Revision as of 11:44, 22 August 2024 by RobinHood70 (talk | contribs) (→‎Reverse engineering: Standard indentation style)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Perk Entry Point Discussion[edit source]

  • Modify Player Magic Slowdown
    • After extensive testing, I'm fairly certain this EP does nothing. I tested it a 5.0 multiplier, a 0.2 multiplier, an Add Value of 20, an Add Value of -20, and a Set Value of 1.0. It doesn't affect the player's casting or casting speed in any way, nor does it affect incoming magic spells in any way that I can tell. I also suspected that perhaps this had something to do with the modifying the player's abilities when a Slow Time effect was active, so I tested that, but again, no effects observed--player movement speed, casting speed, attack speed, etc.. all are unmodified even while Slow Time is active. I also discovered a mod called "Belua Sanguinare" that uses this perk entry, but as far as I can tell it's not having any effect there either. Egocarib (talk) 2013-08-23T22:51:43 (EDT)
      • The entry point determines the speed of time for the player while under the effect of a Slow Time effect. The magnitude of the spell determines how fast time moves for the NPCs and the world, but the player slow down is different. The default is (as far as I can tell) 0.6. If that is modified to 1.0 (by adding 0.4 or simply setting it to 1.0), the player moves at normal speed. This can also be used to make the time move faster for NPCs and slower for the PC.Lofgren (talk) 2016-05-18T15:22:45 (EDT)
  • Modify Bow Zoom
    • Values beyond 1.0 don't appear to have an affect - the zoom distance is capped. I also noticed that certain values (like 0.80) produced buggy behavior, at least for me -- at that value the camera kept zooming in and out very rapidly and jerkily. 0.60 (the Eagle Eye perk value) and 1.0 worked fine, though. Egocarib (talk) 2013-11-22T20:40:56 (EST)
  • Apply Reanimate Spell
    • If a character has more than one perk with this entry point, only one spell will actually be applied to the target, as far as I can tell. Its usually the spell from the perk that they got first. Of note: this means that any mod that adds a perk using entry point this has the potential override 'Dark Souls'. This could be the case with the other 'Apply ___ Spell' entry points as well, but I haven't tested them --W Dog (talk) 2014-01-03T15:37:28 (EST)

I can confirm that apply weapon swing spell, sneak spell, combat hit spell, and all entry points that apply spells can only apply ONE spell at a time. However, there is a mod that 'fixes' this in scrambled bug fix. Though, doing so will often break a perk overhaul that is designed around this.


  • Apply Combat Hit Spell
Maybe I'm doing it wrong, but a script attached to the associated magic effect doesn't seem to fire when used with this perk entry.--Terra Nova2 (talk) 2015-02-22T12:31:11 (EST)
I noticed that as well I am not sure why it does that, so unless we are both doing it wrong I think it maybe a bug. --Arocide (talk) 2015-04-30T06:39:46 (EDT)
So far it is working fine for me. I created a Constant Effect Ability, OnEffectStart is being applied on first hit, OnHit is being fired on hits after that. The biggest problem seems to be that both with delivery type Self and delivery type Contact, both GetTargetActor() and GetCasterActor() are the same - the actor the spell is on. I was hoping to be able to refer to the actor who did the attack for caster on Contact... but... --Darkconsole (talk) 2015-07-16T21:07:43 (EDT)
It appears to work with Archery however it works in a weird way. In my testing the Spell is instantly applied to the combat target when an arrow is shot rather then when an arrow hits. This can depending on the effect cause an arrow to miss entirely when it should have hit (e.g Paralysis, Slow Effects or Applying Impulse Force). --Arocide (talk) 2015-04-30T06:39:46 (EDT)
yeah that archery thing is a known bug in the game. If you get the paralyze talent at the top of the archery tree, the actor will fall down before the arrow even gets to it, often resulting in a miss at long distances (lolol). --Darkconsole (talk) 2015-07-16T21:07:43 (EDT)
I am also seeing evidence that the note that it doesn't work on magic effects, is wrong. It appears to be working just fine when a spell hits the target too. --Darkconsole (talk) 2015-07-17T20:17:55 (EDT)

Bottom Lable for Add Activation Perk Entry[edit source]

This is currently broken in the 64 bit version of the Creation Kit. --Lisselli (talk) 2016-11-15T15:30:15 (EST)

Reverse engineering[edit source]

I wrote a script to dump the game's Perk Entry Point information from Skyrim Classic. Should be basically the same for SSE.

The way perk entry points work is that the game calls a varargs function, CalculatePerkData, which has two non-varargs arguments: the entry point to use (an enum) and the actor that owns the perk. The varargs arguments that follow are grouped into two sets: the first n varargs are the perk's normal arguments, and the nth argument and the next u - 1 arguments are special arguments. The precise operational definition of "special" is unknown, except that if any of them are null pointers, then the entire operation is aborted and no perk entry points are run.

The value of u is determined by an unidentified enum (unk0C in the dump below) on the perk. In practice it's always 1 or 0, but there exists an unused enum value that maps to there being three special arguments.

My current (completely untested) hypothesis is that the perk arguments influence context-specific conditions. For example, GetSpellCastingPerk returns 1 if some spell has a specific perk, but it doesn't let you specify which spell to test; it tests whatever spell happens to be relevant at the moment. For a "Mod Spell Cost" entry point, that's the spell being cast. What other entry points have a "relevant spell?" I think it's either any perk with a Spell argument, or any perk with a Spell special argument. Testing would be needed to determine which is the case.

In summary: for each perk entry point below, all of the arguments listed are the "normal" argument, and when a perk is listed as having "1 args required," the last argument is also a special argument.

Calculate Weapon Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Calculate My Critical Hit Chance: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Calculate My Critical Hit Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Calculate Mine Explode Chance: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Adjust Limb Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Attacker
    - Attacker Weapon
Adjust Book Skill Points: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Recovered Health: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Get Should Attack: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Attacker
Modify Buy Prices: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Add Leveled List On Death: 2 extra args
 - unk0C: 1 (maps to last 0 args required)
 - Args:
    - Perk Owner
    - Target
Get Max Carry Weight: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Addiction Chance: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Addiction Duration: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Positive Chem Duration: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Activate: 2 extra args
 - unk0C: 2 (maps to last 0 args required)
 - Args:
    - Perk Owner
    - Target
Ignore Running During Detection: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Ignore Broken Lock: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Enemy Critical Hit Chance: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Modify Sneak Attack Mult: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Modify Max Placeable Mines: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Bow Zoom: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
Modify Recover Arrow Chance: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Skill Use: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Telekinesis Distance: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Telekinesis Damage Mult: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Telekinesis Damage: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Bashing Damage: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Power Attack Stamina: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
Mod Power Attack Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Mod Spell Magnitude: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
    - Target
Mod Spell Duration: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
    - Target
Mod Secondary Value Weight: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
    - Target
Mod Armor Weight: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Mod Incoming Stagger: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Attacker
Mod Target Stagger: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Attack Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Mod Incoming Damage: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Attacker
    - Attacker Weapon
Mod Target Damage Resistance: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Mod Spell Cost: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Mod Percent Blocked: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Mod Shield Deflect Arrow Chance: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Mod Incoming Spell Magnitude: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Mod Incoming Spell Duration: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Mod Player Intimidation: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Player Reputation: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Mod Favor Points: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Bribe Amount: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Detection Light: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Detection Movement: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Mod Soul Gem Recharge: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Set Sweep Attack: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
Apply Combat Hit Spell: 3 extra args
 - unk0C: 4 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Target
Apply Bashing Spell: 2 extra args
 - unk0C: 4 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Apply Reanimate Spell: 3 extra args
 - unk0C: 4 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
    - Target
Set Boolean Graph Variable: 1 extra args
 - unk0C: 5 (maps to last 0 args required)
 - Args:
    - Perk Owner
Mod Spell Casting Sound Event: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify Pickpocket Chance: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
    - Item
Modify Detection Sneak Skill: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Modify Falling Damage: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Lockpick Sweet Spot: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Locked Ref
Modify Sell Prices: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Can Pickpocket Equipped Item: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
    - Item
Modify Lockpick level allowed: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Set Lockpick Starting Arc: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Set Progression Picking: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Make lockpicks unbreakable : 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Alchemy Effectiveness: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Apply Weapon Swing Spell: 3 extra args
 - unk0C: 4 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Attacker
    - Attacker Weapon
Modify Commanded Actor Limit: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Apply Sneaking Spell: 1 extra args
 - unk0C: 4 (maps to last 1 args required)
 - Args:
    - Perk Owner
Modify Player Magic Slowdown: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify Ward Magicka Absorption Pct: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify Initial Ingredient Effects Learned: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Purify Alchemy Ingredients: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Filter Activation: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
Can dual cast spell: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify Tempering Health: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Modify Enchantment Power: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Enchantment
    - Item
Modify Soul Pct Captured to Weapon: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
    - Item
Mod Soul Gem Enchanting: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Enchantment
    - Item
Mod # applied enchantments allowed: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Set Activate Label: 2 extra args
 - unk0C: 6 (maps to last 0 args required)
 - Args:
    - Perk Owner
    - Target
Mod Shout OK: 1 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
Mod Poison Dose Count: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Weapon
    - Spell
Should Apply Placed Item: 3 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target
    - Item
Modify Armor Rating: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Modify lockpicking crime chance: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Locked Ref
Modify ingredients harvested: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Item
Modify Spell Range (Target Loc.): 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify Potions Created: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Spell
Modify lockpicking key reward chance: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Locked Ref
Allow Mount Actor: 2 extra args
 - unk0C: 0 (maps to last 1 args required)
 - Args:
    - Perk Owner
    - Target

DavidJCobb (talk) 21:39, 15 August 2024 (EDT)

Many thanks for this info! I didn't know you were still around after all these years! More to the point, are you aware of how "Mod Target Damage Resistance" works? If we add a flat value, say +140, the armor rating of the target does not really increase by 140 points. What I found is that, if the gamesetting fArmorScalingFactor is 0.1 (meaning 0.1% of physical resistance for each armor rating point) and we add, say +0.14 through "Mod Target Damage Resistance", then the target armor effectively increases by 140. So my guess is that "Mod Target Damage Resistance" with "+x" will effectively increase the armor rating of the target by: x/(0.01*fArmorScalingFactor). Is this correct? (in other words, this perk entry directly affects physical resistance, not armor rating, but such effect can be interpreted as an increase in armor rating if we take the gamesetting fArmorScalingFactor into account, which represents the AR <-> physicalRes conversion factor).