Difference between revisions of "Talk:SetActorValue - Actor"
Jump to navigation
Jump to search
imported>Chrisbburn (Created page with "Will using the SetAV code cause a permanent change of the base value ie after a save will it still be present?") |
imported>KainXavier (An observation about using the SetActorValue function with the "DamageResist" actor value) |
||
(2 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
== A Question == | |||
Will using the SetAV code cause a permanent change of the base value ie after a save will it still be present? | Will using the SetAV code cause a permanent change of the base value ie after a save will it still be present? | ||
== Example Script: SetAV Aggression from Trigger Zone == | |||
<source lang="papyrus"> | |||
Scriptname AAMyBadGuyGetsMadScript extends ObjectReference | |||
; Attached to custom trigger zone. Previously non-hostile bandit with aggression of 0 attacks player when he or she bumps into trigger zone. | |||
Event OnTriggerEnter(ObjectReference akActionRef) | |||
if(akActionRef == Game.GetPlayer()) | |||
AAMyBadGuyREF.SetAV ("Aggression", 2) | |||
endif | |||
EndEvent | |||
Actor Property AAMyBadGuyREF Auto | |||
</source> | |||
SetAV Aggression In conjunction with [[Factions Tab|Faction Relationships]], determines when the Actor will initiate combat: | |||
{|border="1" cellpadding="5" cellspacing="0" | |||
|- | |||
! style="background:#efefef;" | Type | |||
! style="background:#efefef;" | Value | |||
! style="background:#efefef;" | Description | |||
|- | |||
|Unaggressive | |||
|0 | |||
|Will not initiate combat. | |||
|- | |||
|Aggressive | |||
|1 | |||
|Will attack Enemies on sight. | |||
|- | |||
|Very Aggressive | |||
|2 | |||
|Will attack Enemies and Neutrals on sight. | |||
|- | |||
|Frenzied | |||
|3 | |||
|Will attack anyone on sight. Actors are rarely set to Frenzied by default; this is usually the result of some other spell or effect (like the Frenzy spell). | |||
|- | |||
|} | |||
--[[User:David Brasher|David Brasher]] 14:51, 6 June 2012 (EDT) | |||
== Equipping / Unequipping Armor == | |||
Something worth noting is that armor appears to modify the base value of the "DamageResist" actor value. However, any attempts to alter the same actor value with SetActorValue() fail. The current value must be altered instead. | |||
--[[User:KainXavier|KainXavier]] ([[User talk:KainXavier|talk]]) 2014-04-23T23:33:20 (EDT) |
Latest revision as of 22:33, 23 April 2014
A Question[edit source]
Will using the SetAV code cause a permanent change of the base value ie after a save will it still be present?
Example Script: SetAV Aggression from Trigger Zone[edit source]
Scriptname AAMyBadGuyGetsMadScript extends ObjectReference
; Attached to custom trigger zone. Previously non-hostile bandit with aggression of 0 attacks player when he or she bumps into trigger zone.
Event OnTriggerEnter(ObjectReference akActionRef)
if(akActionRef == Game.GetPlayer())
AAMyBadGuyREF.SetAV ("Aggression", 2)
endif
EndEvent
Actor Property AAMyBadGuyREF Auto
SetAV Aggression In conjunction with Faction Relationships, determines when the Actor will initiate combat:
Type | Value | Description |
---|---|---|
Unaggressive | 0 | Will not initiate combat. |
Aggressive | 1 | Will attack Enemies on sight. |
Very Aggressive | 2 | Will attack Enemies and Neutrals on sight. |
Frenzied | 3 | Will attack anyone on sight. Actors are rarely set to Frenzied by default; this is usually the result of some other spell or effect (like the Frenzy spell). |
--David Brasher 14:51, 6 June 2012 (EDT)
Equipping / Unequipping Armor[edit source]
Something worth noting is that armor appears to modify the base value of the "DamageResist" actor value. However, any attempts to alter the same actor value with SetActorValue() fail. The current value must be altered instead. --KainXavier (talk) 2014-04-23T23:33:20 (EDT)