Garry's Mod Wiki

Revision Difference

NEXTBOT:OnStuck#510732

<function name="OnStuck" parent="NEXTBOT" type="hook">⤶ <ishook>yes</ishook>⤶ <description>Called when the bot thinks it is stuck.</description>⤶ <realm>Server</realm>⤶ <predicted>No</predicted>⤶ </function>⤶ ⤶ <example>⤶ <description>Kills the bot when getting stuck, using a new damageinfo object.</description>⤶ <code>⤶ function ENT:OnStuck()⤶ ⤶ local dmginfo = DamageInfo()⤶ dmginfo:SetAttacker( self )⤶ ⤶ self:OnKilled( dmginfo )⤶ ⤶ end⤶ </code>⤶ ⤶ </example>