Back to TPG

TPG.GetWeaponList

S🏷️ Weapons

Part of TPG namespace

TPG.GetWeaponList(category, includeDisabled)
View on GitHub|gamemode/config/sh_weapons.lua:389-406
📋 Has LDoc👁️ 0 viewsUpdated 1 month ago

Description

List weapons in a category, sorted by name with "None" always first. entry that is currently disabled (base toggle or explicit per-weapon toggle from TPG.Weapons.ApplyState) is left out entirely.

Parameters

NameTypeDescription
categorystring"Primary", "Secondary", or "Special".
includeDisabled?booleanWhen false (the default), an(default: false)

Returns

TypeDescription
{table,...}A list of `{ id, name, cost, enabled }`.

Examples

No examples available.

Used In

No usages found in the codebase.