Garry's Mod Wiki

duplicator.Allow

  duplicator.Allow( string classname )

Description

Allow entities with given class name to be duplicated. See duplicator.Disallow for the opposite effect.

duplicator.IsAllowed can be used to poll the status of a particular entity class.

duplicator.Allow is automatically called by scripted_ents.Register and weapons.Register, unless the associated entity table has ENT.DisableDuplicator set to true.

This is also automatically called by duplicator.RegisterEntityClass.

In addition to that most spawnmenu content, such as engine weapons and pickup-ables, as well as most engine NPCs in Sandbox-derived gamemodes are also allowed by default.

Arguments

1 string classname
An entity's classname to allow duplicating.