Description
Wiki Description
Sets the base value specified Actor Value on the Object Reference to the passed-in value. Any modifiers are left intact.
Documentation Comment
Sets the specified actor value
Caveats
CK Wiki - Notes
- 2 decimal float precision from -0x001FFFFF to 0x001FFFFF
- int precision from 0x00200000 to 0x00FFFFFF ( and -0x00200000 to -0x00FFFFFF )
- values not reliable when greater than 0x00FFFFFF ( or less than -0x00FFFFFF)
- Odd numbers outside range will either shift up or down to the next adjacent even number.
; This is outside the reliable range
npc.SetValue(MyActorValue, 0x0FFFFFFF)
npc.GetValue(MyActorValue) ; Returns 0x10000000
Parameters
floatafValue
CK Wiki Description
What value to set the actor value to.
Examples
ActorValue property HealthAV
; Set the player's health actor value to 50
Game.GetPlayer().SetValue(HealthAV, 50)ActorValue property HealthAV
; Set Nancy's current health actor value
Nancy.SetValue(HealthAV, 20)Auto-Generated Example
ActorValue myActorValue__akAV
float myFloat__afValue
myObjectReference__toCallFunctionOn.SetValue(myActorValue__akAV, myFloat__afValue)Related Pages
Additional References
View this function’s page on the Fallout 4 Creation Kit Wiki
