Garry's Mod Wiki

Revision Difference

SANDBOX:PopulatePropMenu#512835

<function name="PopulatePropMenu" parent="SANDBOX" type="hook">⤶ <ishook>yes</ishook>⤶ <description>⤶ This hook makes the engine load the spawnlist text files.⤶ It calls <page>spawnmenu.PopulateFromEngineTextFiles</page> by default.⤶ </description>⤶ <realm>Client</realm>⤶ <predicted>No</predicted>⤶ </function>⤶ ⤶ <example>⤶ <description>Source code for this hook.</description>⤶ <code>⤶ function GM:PopulatePropMenu()⤶ ⤶ -- This function makes the engine load the spawn menu text files.⤶ -- We call it here so that any gamemodes not using the default ⤶ -- spawn menu can totally not call it.⤶ spawnmenu.PopulateFromEngineTextFiles()⤶ ⤶ end⤶ </code>⤶ ⤶ </example>