Garry's Mod Wiki

Revision Difference

GM:EntityFireBullets#519056

<function name="EntityFireBullets" parent="GM" type="hook"> <ishook>yes</ishook> <description> Called every time a bullet is fired from an entity. <warning>This hook is called directly from <page>Entity:FireBullets</page>. Due to this, you cannot call <page>Entity:FireBullets</page> inside this hook or an infinite loop will occur crashing the game.</warning> </description> <realm>Shared</realm> <predicted>No</predicted> <args> <arg name="ent" type="Entity">The entity that fired the bullet</arg> <arg name="data" type="table">The bullet data. See <page>Bullet</page></arg>⤶ <arg name="data" type="table">The bullet data. See <page>Structures/Bullet</page></arg>⤶ </args> <rets> <ret name="" type="boolean">Return true to apply all changes done to the bullet table. Return false to suppress the bullet.</ret> </rets> </function>