Difference between revisions of "SetRefEssential"

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
imported>CSbot
(Automated import of articles)
imported>DragoonWraith
m (Reverted edits by CSbot (Talk); changed back to last version by DragoonWraith)
Line 1: Line 1:
{{BotAddedPage|CSbot|DragoonWraith}}
A command for [[:Category:Oblivion Script Extender|Oblivion Script Extender]]
{{Function
| origin = OBSE
| summary = Sets the calling ref to be essential or not.
| name = SetRefEssential
| referenceType = reference
| arguments =
  {{FunctionArgument
  | name = newIsEssential
  | type = bool
  }}
}}


[[Category:Functions]]
'''Syntax:'''
[[Category:Functions (OBSE)]]
reference.SetRefEssential isEssential:bool
[[Category:Functions (OBSE v0009)]]
 
[[Category:Actor Functions]]
[''Ref.'']setRefEssential ''booleanFlag''
[[Category:Actor Functions (OBSE)]]
 
Sets the calling ref to be essential or not.
 
==Notes==
* Essential actors cannot be killed, only knocked unconscious.
* Must be called on a reference to an actor.
* Set to 1 to flag the reference as essential or 0 to clear the flag.
 
'''Example:'''
<pre>
if ( myNPCRef.isRefEssential == 0 )
  myNPCRef.setRefEssential 1 ; make the reference essential
endif</pre>
 
==See Also==
[[IsRefEssential]]
 
[[Category: Functions]]
[[Category: Functions (OBSE)]]
[[Category: Actor Value Functions]]
[[Category: Actor Value Functions (OBSE)]]

Revision as of 19:01, 8 August 2010

A command for Oblivion Script Extender

Syntax:

reference.SetRefEssential isEssential:bool
[Ref.]setRefEssential booleanFlag

Sets the calling ref to be essential or not.

Notes

  • Essential actors cannot be killed, only knocked unconscious.
  • Must be called on a reference to an actor.
  • Set to 1 to flag the reference as essential or 0 to clear the flag.

Example:

if ( myNPCRef.isRefEssential == 0 )
  myNPCRef.setRefEssential 1 ; make the reference essential
endif

See Also

IsRefEssential