Перейти к содержанию

Player::getWeaponAmmo

Материал из RAGE MP Wiki Archive
Версия от 20:14, 13 октября 2019; imported>Sakatum
(разн.) ← Предыдущая версия | Текущая версия (разн.) | Следующая версия → (разн.)

Get the weapon's ammo.

Syntax

player.getWeaponAmmo(weaponHash);

Parameters

  • weaponHash: Int

Examples

Get the ammo of the weapon you are using.

Server-Side
var weapon = player.weapon;
var ammo = player.getWeaponAmmo(weapon);
player.outputChatBox("The weapon has "+ammo+" bullets.");