Difference between revisions of "GetCombatState - Actor"
Jump to navigation
Jump to search
Added an example using the player.
imported>Jlundin (Created page with 'Category:Scripting Category:Papyrus '''Member of:''' Actor Script Gets the actor's current combat state. == Syntax == <source lang="papyrus"> int Function GetCombat…') |
imported>Xander9009 (Added an example using the player.) |
||
Line 25: | Line 25: | ||
Debug.Trace("Careful! That filthy pirate is looking around...") | Debug.Trace("Careful! That filthy pirate is looking around...") | ||
endIf | endIf | ||
</source> | |||
<source lang="papyrus"> | |||
;Is the player in combat? | |||
If ( Game.GetPlayer().GetCombatState() == 0 ) ;State is 0, so player is peaceful | |||
Debug.Notification("Player is not in combat") | |||
Else ;State is not 0, so player is not peaceful | |||
Debug.Notification("Player is in combat") | |||
EndIf | |||
</source> | </source> | ||
== See Also == | == See Also == | ||
*[[Actor Script]] | *[[Actor Script]] |