Difference between revisions of "GetRace"

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
imported>Odessa
(Created page with "{{Function |origin = NVSE |summary = Returns the race of the specified actor |name = GetRace |returnType = race |arguments = {{FunctionArgument |Name = Actor |Ty...")
 
imported>DoctaSax
 
(One intermediate revision by one other user not shown)
Line 4: Line 4:
  |name = GetRace
  |name = GetRace
  |returnType = race
  |returnType = race
|referenceType = Actor
  |arguments =  
  |arguments =  
   {{FunctionArgument
   {{FunctionArgument
   |Name = Actor
   |Name = Actor
   |Type = NPC
   |Type = NPC
  }}
  |Optional = y}}
}}
}}
==Example==
==Example==
Line 16: Line 17:
if rRace == Ghoul
if rRace == Ghoul
     ; do something ghoulish
     ; do something ghoulish
endif
let rRace := SomeNPCRef.GetRace
if rRace == Hispanic
  ; whatever
endif
endif
</pre>
</pre>
==See Also==
==See Also==
*[[GetIsRace]]
*[[GetIsRace]] (to return a boolean)
*[[GetRaceName]] (to return a string)
[[Category:Functions_(NVSE)]]
[[Category:Functions_(NVSE)]]

Latest revision as of 20:27, 20 February 2017

< [[::Category:Functions|Category:Functions]]

A function added by the New Vegas Script Extender.

Description

Returns the race of the specified actor

Syntax

[help]
(race) Actor.GetRace Actor:NPC

Example

ref rRace
let rRace := GetRace SomeNPC
if rRace == Ghoul
    ; do something ghoulish
endif

let rRace := SomeNPCRef.GetRace
if rRace == Hispanic
  ; whatever
endif

See Also