Garry's Mod Wiki

Revision Difference

ENTITY:TranslateActivity#560031

<function name="TranslateActivity" parent="ENTITY" type="hook"> <added>2023.11.16</added> <description> Called by the engine to alter NPC activities, if desired by the NPC.⤶ <note>This hook only exists for `ai` type SENTs.</note> </description> <realm>Server</realm> <args> <arg name="act" type="number">The activity to translate. See <page>Enums/ACT</page>.</arg> </args> <rets> <ret name="" type="number">The activity that should override the incoming activity. See <page>Enums/ACT</page>. Do not return anything to not override.</ret> </rets> </function>