No categories assigned

LUA:GetArchetypeName

LUA Functions: GetArchetypeName(Spawn)

Returns the string value of a spawn's archetype. Example, if used on a spawn with the adventure class "Assassin" will return the string value "Scout".

Back to LUA Functions Index


Syntax

GetArchetypeName(Spawn)


Usage

 function hailed(NPC, Spawn)
   Say(NPC, "Your archetype is " .. GetArchetypeName(Spawn) .. "!")
 end

This makes the NPC respond to the player who hails it with the player's archetype.