Jump to content

How do perk entry points dynamically consult Actor Values?


Recommended Posts

Perk entries in CK dynamically consult Actor Values, which allows them to keep the function you are trying to execute up to date. Let's say i want to modify a perk entry with an actor value, the perk handles that and dynamically modifies the perk entry whenever the actor value changes. How does it do it? How can i do this with a script?

 

I am currently trying to modify an actor value with another actor value via a script which in simple terms is ActorValue1 = ActorValue1 + ActorValue2. I want to dynamically change the result of this equation whenever ActorValue2 changes. Any ideas?

 

https://www.creationkit.com/index.php?title=Perk_Entry_Point

Edited by FatalityGrogen
Link to comment
Share on other sites

You can't as there is no EVENT triggered by an ActorValue value changing.

 

What you need to do is look upstream for the event that triggers the ActorValue modification process like levelup, number of kills, dialog ... or whatever.

 

If there is no system event associated with that trigger, what infact is causing the value to be updated ?

 

ps a really really nasty "workaround" is to run a timer to constantly check for updates, but that is unscalable behavior.

Link to comment
Share on other sites

I'm fairly certain that perks are always dynamic, they will update the values as they occur. If you want something specific to happen within the perk when the value changes, you need to add another rank and use the priority portion to control the order of operations(higher takes precedence).

 

 

example.

rank 1 - priority 10 = expected value is 2

rank 2 - priority 9 = expected value = 3 (it will check this to see if the value has indeed changed to 3)

 

(probably don't need to increase the rank number themselves but it's good for organization)

 

As for how they do this dynamic updating, it's beyond the scope of my knowledge. Probably does polling under the hood in more efficient manner than what we can do with papyrus.

Link to comment
Share on other sites

You can't as there is no EVENT triggered by an ActorValue value changing.

 

What you need to do is look upstream for the event that triggers the ActorValue modification process like levelup, number of kills, dialog ... or whatever.

 

If there is no system event associated with that trigger, what infact is causing the value to be updated ?

 

ps a really really nasty "workaround" is to run a timer to constantly check for updates, but that is unscalable behavior.

Thanks a bunch. The Actor Value i'm referring to is the Agility SPECIAL. While level up has an event associated with it which is OnStoryIncreaseLevel, an increase in a SPECIAL AV is only linked to a quest that just increases its value by one. Maybe i can work something out from there or use timers like you said (indeed nasty).

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...