SetWeaponFiringRate

From Multi Theft Auto: Wiki
Revision as of 17:16, 23 December 2014 by AlexTMjugador (talk | contribs) (Added OOP syntax and Needs Example template)
Jump to navigation Jump to search

Accessories-text-editor.png Script Example Missing Function SetWeaponFiringRate needs a script example, help out by writing one.

Before submitting check out Editing Guidelines Script Examples.

This function sets the firing rate to be used when a custom weapon is in firing state.

Syntax

bool setWeaponFiringRate ( weapon theWeapon, int firingRate )

OOP Syntax Help! I don't understand this!

Method: weapon:setFiringRate(...)
Variable: .firingRate
Counterpart: getWeaponFiringRate


Required Arguments

  • theWeapon: The weapon to modify the firing rate of.
  • firingRate: The weapon firing rate. It seems to be a kind of frecuency value, so the lower the quicker the custom weapon will shoot.

Returns

Returns true on success, false otherwise.

Requirements

Minimum server version n/a
Minimum client version 1.3.0-9.04555

Note: Using this feature requires the resource to have the above minimum version declared in the meta.xml <min_mta_version> section. e.g. <min_mta_version client="1.3.0-9.04555" />

See also