Garry's Mod Wiki

Garry's Mod Wiki

  boolean NPC:UseFollowBehavior()

Description

This function only works on ai type SENTs.

Returns

1 boolean
If we succeeded setting the behavior.

Example

Create a base_ai that follows the player, using console commands and Lua.

ent_create base_ai targetname alyx additionalequipment weapon_ar2 ent_create ai_goal_follow goal !player formation 0 actor alyx searchtype 0 startactive 1 -- Execute Lua code below after a second: lua_run ents.FindByName("alyx")[1]:UseFollowBehavior()

This site is a community mirror of the official Garry's Mod wiki.. This site is not maintained by Facepunch Studios.

Page content is automatically updated four times a day. Edits and history are not available.

Last Parsed: Loading...