No categories assigned
LUA:SetFactionID
- Last edited 3 years ago by Vlash Nytefall
LUA:AllFunctions - SetFactionID
Return to: LUA:AllFunctions | Tutorials | Portal | Forum | Project Manager | Bug Tracker
Sets the faction of a spawn to a faction id
Syntax
SetFactionID(param1, param2)
Parameters
- Required - param1 (Spawn), param2 (int32)
- param1 is the spawn to change the faction of
- param2 is the id of the faction we want to use
Example
function hailed(NPC, Player) SetFactionID(NPC, 1) end
An NPC with this script will set it's faction to 1 when hailed.