Client · JavaScript & Lua

GTA V Weapon natives

Weapons, ammunition, components and weapon objects.

The 123 natives of the game’s WEAPON namespace, as LS:MP client scripts call them: global functions with the same arguments in JavaScript and in Lua. Each one has its own page, with its signature, a call in both languages, its parameters and what it returns.

NativeGame nameHash
enableLaserSightRenderingENABLE_LASER_SIGHT_RENDERING0xC8B46D7727D864AA
getWeaponComponentTypeModelGET_WEAPON_COMPONENT_TYPE_MODEL0x0DB57B41EC1DB083
getWeapontypeModelGET_WEAPONTYPE_MODEL0xF46CDC33180FDA94
getWeapontypeSlotGET_WEAPONTYPE_SLOT0x4215460B9B8B7FA0
getWeapontypeGroupGET_WEAPONTYPE_GROUP0xC3287EE3050FB74C
getWeaponComponentVariantExtraCountGET_WEAPON_COMPONENT_VARIANT_EXTRA_COUNT0x6558AC7C17BFEF58
getWeaponComponentVariantExtraModelGET_WEAPON_COMPONENT_VARIANT_EXTRA_MODEL0x4D1CB8DC40208A17
setCurrentPedWeaponSET_CURRENT_PED_WEAPON0xADF692B254977C0C
getCurrentPedWeaponGET_CURRENT_PED_WEAPON0x3A87E44BB9A01D54
getCurrentPedWeaponEntityIndexGET_CURRENT_PED_WEAPON_ENTITY_INDEX0x3B390A939AF0B5FC
getBestPedWeaponGET_BEST_PED_WEAPON0x8483E98E8B888AE2
setCurrentPedVehicleWeaponSET_CURRENT_PED_VEHICLE_WEAPON0x75C55983C2C39DAA
getCurrentPedVehicleWeaponGET_CURRENT_PED_VEHICLE_WEAPON0x1017582BCD3832DC
setPedCycleVehicleWeaponsOnlySET_PED_CYCLE_VEHICLE_WEAPONS_ONLY0x50276EF8172F5F12
isPedArmedIS_PED_ARMED0x475768A975D5AD17
isWeaponValidIS_WEAPON_VALID0x937C71165CF334B3
hasPedGotWeaponHAS_PED_GOT_WEAPON0x8DECB02F88F428BC
isPedWeaponReadyToShootIS_PED_WEAPON_READY_TO_SHOOT0xB80CA294F2F26749
getPedWeapontypeInSlotGET_PED_WEAPONTYPE_IN_SLOT0xEFFED78E9011134D
getAmmoInPedWeaponGET_AMMO_IN_PED_WEAPON0x015A522136D7F951
addAmmoToPedADD_AMMO_TO_PED0x78F0424C34306220
setPedAmmoSET_PED_AMMO0x14E56BC5B5DB6A19
setPedInfiniteAmmoSET_PED_INFINITE_AMMO0x3EDCB0505123623B
setPedInfiniteAmmoClipSET_PED_INFINITE_AMMO_CLIP0x183DADC6AA953186
setPedStunGunFiniteAmmoSET_PED_STUN_GUN_FINITE_AMMO0x24C024BA8379A70A
giveWeaponToPedGIVE_WEAPON_TO_PED0xBF0FD6E56C964FCB
giveDelayedWeaponToPedGIVE_DELAYED_WEAPON_TO_PED0xB282DC6EBD803C75
removeAllPedWeaponsREMOVE_ALL_PED_WEAPONS0xF25DF915FA38C5F3
removeWeaponFromPedREMOVE_WEAPON_FROM_PED0x4899CB088EDF59B8
hidePedWeaponForScriptedCutsceneHIDE_PED_WEAPON_FOR_SCRIPTED_CUTSCENE0x6F6981D2253C208F
setPedCurrentWeaponVisibleSET_PED_CURRENT_WEAPON_VISIBLE0x0725A4CCFDED9A70
setPedDropsWeaponsWhenDeadSET_PED_DROPS_WEAPONS_WHEN_DEAD0x476AE72C1D19D1A8
hasPedBeenDamagedByWeaponHAS_PED_BEEN_DAMAGED_BY_WEAPON0x2D343D2219CD027A
clearPedLastWeaponDamageCLEAR_PED_LAST_WEAPON_DAMAGE0x0E98F88A24C5F4B8
hasEntityBeenDamagedByWeaponHAS_ENTITY_BEEN_DAMAGED_BY_WEAPON0x131D401334815E94
clearEntityLastWeaponDamageCLEAR_ENTITY_LAST_WEAPON_DAMAGE0xAC678E40BE7C74D2
setPedDropsWeaponSET_PED_DROPS_WEAPON0x6B7513D9966FBEC0
setPedDropsInventoryWeaponSET_PED_DROPS_INVENTORY_WEAPON0x208A1888007FC0E6
getMaxAmmoInClipGET_MAX_AMMO_IN_CLIP0xA38DCFFCEA8962FA
getTimeBeforeVehicleWeaponReloadFinishesNot in this build_GET_TIME_BEFORE_VEHICLE_WEAPON_RELOAD_FINISHES0xC8C6F4B1CDEB40EF
hasWeaponReloadingInVehicleNot in this build_HAS_WEAPON_RELOADING_IN_VEHICLE0x8062F07153F4446F
getVehicleWeaponReloadTimeNot in this build_GET_VEHICLE_WEAPON_RELOAD_TIME0xD0AD348FFD7A6868
getAmmoInVehicleWeaponClipNot in this build_GET_AMMO_IN_VEHICLE_WEAPON_CLIP0x2857938C5D407AFA
getAmmoInClipGET_AMMO_IN_CLIP0x2E1202248937775C
setAmmoInVehicleWeaponClipNot in this build_SET_AMMO_IN_VEHICLE_WEAPON_CLIP0x873906720EE842C3
setAmmoInClipSET_AMMO_IN_CLIP0xDCD2A934D65CB497
getMaxAmmoGET_MAX_AMMO0xDC16122C7A20C933
getMaxAmmoByTypeGET_MAX_AMMO_BY_TYPE0x585847C5E4E11709
addPedAmmoByTypeADD_PED_AMMO_BY_TYPE0x2472622CE1F2D45F
setPedAmmoByTypeSET_PED_AMMO_BY_TYPE0x5FD1E1F011E76D7E
getPedAmmoByTypeGET_PED_AMMO_BY_TYPE0x39D22031557946C1
setPedAmmoToDropSET_PED_AMMO_TO_DROP0xA4EFEF9440A5B0EF
setPickupAmmoAmountScalerSET_PICKUP_AMMO_AMOUNT_SCALER0xE620FD3512A04F18
getPedAmmoTypeFromWeaponGET_PED_AMMO_TYPE_FROM_WEAPON0x7FEAD38B326B9F74
getPedOriginalAmmoTypeFromWeaponGET_PED_ORIGINAL_AMMO_TYPE_FROM_WEAPON0xF489B44DD5AF4BD9
getPedLastWeaponImpactCoordGET_PED_LAST_WEAPON_IMPACT_COORD0x6C4D0409BA1A2BC2
setPedGadgetSET_PED_GADGET0xD0D7B1E680ED4A1A
getIsPedGadgetEquippedGET_IS_PED_GADGET_EQUIPPED0xF731332072F5156C
getSelectedPedWeaponGET_SELECTED_PED_WEAPON0x0A6DB4965674D243
explodeProjectilesEXPLODE_PROJECTILES0xFC4BD125DE7611E4
removeAllProjectilesOfTypeREMOVE_ALL_PROJECTILES_OF_TYPE0xFC52E0F37E446528
getLockonDistanceOfCurrentPedWeaponGET_LOCKON_DISTANCE_OF_CURRENT_PED_WEAPON0x840F03E9041E2C9C
getMaxRangeOfCurrentPedWeaponGET_MAX_RANGE_OF_CURRENT_PED_WEAPON0x814C9D19DFD69679
hasVehicleGotProjectileAttachedHAS_VEHICLE_GOT_PROJECTILE_ATTACHED0x717C8481234E3B88
giveWeaponComponentToPedGIVE_WEAPON_COMPONENT_TO_PED0xD966D51AA5B28BB9
removeWeaponComponentFromPedREMOVE_WEAPON_COMPONENT_FROM_PED0x1E8BE90C74FB4C09
hasPedGotWeaponComponentHAS_PED_GOT_WEAPON_COMPONENT0xC593212475FAE340
isPedWeaponComponentActiveIS_PED_WEAPON_COMPONENT_ACTIVE0x0D78DE0572D3969E
refillAmmoInstantlyREFILL_AMMO_INSTANTLY0x8C0D57EA686FAD87
makePedReloadMAKE_PED_RELOAD0x20AE33F3AC9C0033
triggerVehicleWeaponReloadNot in this build_TRIGGER_VEHICLE_WEAPON_RELOAD0x5B1513F27F279A44
requestWeaponAssetREQUEST_WEAPON_ASSET0x5443438F033E29C3
hasWeaponAssetLoadedHAS_WEAPON_ASSET_LOADED0x36E353271F0E90EE
removeWeaponAssetREMOVE_WEAPON_ASSET0xAA08EF13F341C8FC
createWeaponObjectCREATE_WEAPON_OBJECT0x9541D3CF0D398F36
giveWeaponComponentToWeaponObjectGIVE_WEAPON_COMPONENT_TO_WEAPON_OBJECT0x33E179436C0B31DB
removeWeaponComponentFromWeaponObjectREMOVE_WEAPON_COMPONENT_FROM_WEAPON_OBJECT0xF7D82B0D66777611
hasWeaponGotWeaponComponentHAS_WEAPON_GOT_WEAPON_COMPONENT0x76A18844E743BF91
giveWeaponObjectToPedGIVE_WEAPON_OBJECT_TO_PED0xB1FA61371AF7C4B7
doesWeaponTakeWeaponComponentDOES_WEAPON_TAKE_WEAPON_COMPONENT0x5CEE3DF569CECAB0
getWeaponObjectFromPedGET_WEAPON_OBJECT_FROM_PED0xCAE1DC9A0E22A16D
giveLoadoutToPedGIVE_LOADOUT_TO_PED0x68F8BE6AF5CDF8A6
setPedWeaponTintIndexSET_PED_WEAPON_TINT_INDEX0x50969B9B89ED5738
getPedWeaponTintIndexGET_PED_WEAPON_TINT_INDEX0x2B9EEDC07BD06B9F
setWeaponObjectTintIndexSET_WEAPON_OBJECT_TINT_INDEX0xF827589017D4E4A9
getWeaponObjectTintIndexGET_WEAPON_OBJECT_TINT_INDEX0xCD183314F7CD2E57
getWeaponTintCountGET_WEAPON_TINT_COUNT0x5DCF6C5CAB2E9BF7
setPedWeaponComponentTintIndexSET_PED_WEAPON_COMPONENT_TINT_INDEX0x9FE5633880ECD8ED
getPedWeaponComponentTintIndexGET_PED_WEAPON_COMPONENT_TINT_INDEX0xF0A60040BE558F2D
setWeaponObjectComponentTintIndexSET_WEAPON_OBJECT_COMPONENT_TINT_INDEX0x5DA825A85D0EA6E6
getWeaponObjectComponentTintIndexGET_WEAPON_OBJECT_COMPONENT_TINT_INDEX0xB3EA4FEABF41464B
getPedWeaponCamoIndexGET_PED_WEAPON_CAMO_INDEX0xA2C9AC24B4061285
setWeaponObjectCamoIndexSET_WEAPON_OBJECT_CAMO_INDEX0x977CA98939E82E4B
getWeaponHudStatsGET_WEAPON_HUD_STATS0xD92C739EE34C9EBA
getWeaponComponentHudStatsGET_WEAPON_COMPONENT_HUD_STATS0xB3CAF387AE12E9F8
getWeaponDamageGET_WEAPON_DAMAGE0x3133B907D8B32053
getWeaponClipSizeGET_WEAPON_CLIP_SIZE0x583BE370B1EC6EB4
getWeaponTimeBetweenShotsGET_WEAPON_TIME_BETWEEN_SHOTS0x065D2AACAD8CF7A4
setPedChanceOfFiringBlanksSET_PED_CHANCE_OF_FIRING_BLANKS0x8378627201D5497D
setPedShootOrdnanceWeaponSET_PED_SHOOT_ORDNANCE_WEAPON0xB4C8D77C80C0421E
requestWeaponHighDetailModelREQUEST_WEAPON_HIGH_DETAIL_MODEL0x48164DBB970AC3F0
setWeaponPedDamageModifierNot in this build_SET_WEAPON_PED_DAMAGE_MODIFIER0x1091922715B68DF0
setWeaponDamageModifierSET_WEAPON_DAMAGE_MODIFIER0x4757F00BC6323CFE
setWeaponAoeModifierSET_WEAPON_AOE_MODIFIER0x4AE5AC8B852D642C
setWeaponEffectDurationModifierSET_WEAPON_EFFECT_DURATION_MODIFIER0xE6D2CEDD370FF98E
isPedCurrentWeaponSilencedIS_PED_CURRENT_WEAPON_SILENCED0x65F0C5AE05943EC7
isFlashLightOnIS_FLASH_LIGHT_ON0x4B7620C47217126C
setFlashLightFadeDistanceSET_FLASH_LIGHT_FADE_DISTANCE0xCEA66DAD478CD39B
setFlashLightActiveHistorySET_FLASH_LIGHT_ACTIVE_HISTORY0x988DB6FE9B3AC000
setWeaponAnimationOverrideSET_WEAPON_ANIMATION_OVERRIDE0x1055AC3A667F09D9
getWeaponDamageTypeGET_WEAPON_DAMAGE_TYPE0x3BE0BB12D25FB305
setEqippedWeaponStartSpinningAtFullSpeedSET_EQIPPED_WEAPON_START_SPINNING_AT_FULL_SPEED0xE4DCEC7FD5B739A5
canUseWeaponOnParachuteCAN_USE_WEAPON_ON_PARACHUTE0xBC7BE5ABC0879F74
createAirDefenceSphereCREATE_AIR_DEFENCE_SPHERE0x91EF34584710BE99
createAirDefenceAngledAreaCREATE_AIR_DEFENCE_ANGLED_AREA0x9DA58CDBF6BDBC08
removeAirDefenceSphereREMOVE_AIR_DEFENCE_SPHERE0x0ABF535877897560
removeAllAirDefenceSpheresREMOVE_ALL_AIR_DEFENCE_SPHERES0x1E45B34ADEBEE48E
setPlayerTargettableForAirDefenceSphereSET_PLAYER_TARGETTABLE_FOR_AIR_DEFENCE_SPHERE0xECDC202B25E5CF48
isAirDefenceSphereInAreaIS_AIR_DEFENCE_SPHERE_IN_AREA0xDAB963831DBFD3F4
fireAirDefenceSphereWeaponAtPositionFIRE_AIR_DEFENCE_SPHERE_WEAPON_AT_POSITION0x44F1012B69313374
doesAirDefenceSphereExistDOES_AIR_DEFENCE_SPHERE_EXIST0xCD79A550999D7D4F
setCanPedSelectInventoryWeaponSET_CAN_PED_SELECT_INVENTORY_WEAPON0xB4771B9AAF4E68E4
setCanPedSelectAllWeaponsSET_CAN_PED_SELECT_ALL_WEAPONS0xEFF296097FF1E509

Other namespaces

Built-in25Script VM basics: timers, maths helpers, thread control.App data17Data blocks shared with the game's companion apps.Audio280Sounds, speech, music, radio, audio scenes and scripted conversations.Script brains11Script brains attached to objects, peds and world points.Camera248Scripted cameras, the gameplay camera, shakes, cinematic and hint cameras.Clock16In-game time and date, and the real-world clock.Cutscenes56Loading, playing and controlling cutscenes.Data files57Cloud data files and their dictionary and array structures.Decorators12Typed key/value decorators attached to entities.DLC14Presence and state of downloadable content.Entity189Anything placed in the world: position, rotation, health, attachment, collision, visibility.Events13AI and shocking events: adding, blocking and suppressing them.Shop metadata49Shop items, outfits, tattoos and weapon data declared by DLC metadata.Fire19Script fires and explosions.Graphics403Drawing: markers, lines, sprites, lights, particle effects, scaleform movies, timecycles and screen effects.HUD518Text, help and notifications, blips and the minimap, pause-menu and frontend components.IIS1The initial interactive screen shown when the game starts.Interior45Interiors, rooms and entity sets.Item sets9Script-side collections of entities and other items.Landing page4The game's landing page.Lobby8Legacy lobby state of the game's own multiplayer menu.Localization3Language and region of the game.Misc345Everything without a better home: weather, ground and area checks, maths, hashing, strings, game flow.Mobile phone25The in-game phone prop: position, rotation, scale and camera.Money357The game's online economy: earn and spend records, balances.Net shopping42The game's online catalog, baskets and transactions.Network883The game's own network layer: sessions, players, network ids, entity control, cloud content.Object166Props: creation, doors, pickups, breakable and animated objects.Controls50Player input: reading and disabling control actions, vibration, look inversion.Pathfinding60Road nodes, the navigation mesh and GPS routes.Ped614Characters: creation, appearance, health, groups, relationships, ragdoll, config flags.Physics49Ropes, and the physics state of entities.Player250The local player: wanted level, abilities, targeting, control, model, invincibility.Recording17Rockstar Editor recording control.Replay6Rockstar Editor replay and clip state.Save migration8Transfer of a saved game between platforms and accounts.Script38Game script threads and script events.Security3Tamper protection of script variables.Shape tests11Raycasts and the other world probes.Social Club84Social Club inbox, profanity checks, licence plates and presence.Stats338Player statistics, leaderboards and telemetry.Streaming121Loading assets: models, animation and texture dictionaries, particle assets, IPLs, focus.Tasks313AI tasks: movement, combat, animations, driving, scenarios and sequences.Vehicle774Vehicles: creation, mods, colours, doors, damage, handling flags.Water12Water height, waves and water probes.Zones9Map zones and population schedules.

Search them in the interactive natives reference