57 proto native
bool CanFire(
int muzzleIndex);
59 proto native
bool DryFire(
int muzzleIndex);
159 proto
bool GetCartridgeInfo(
int muzzleIndex, out
float ammoDamage, out
string ammoTypeName);
226 proto native
bool TestAttachMagazine(
int muzzleIndex, Magazine mag,
bool do_occupancy_test,
bool do_script_check);
bool IsChamberFull(int idx)
proto native float GetCurrentZeroing(int muzzleIndex=0)
returns currently used value of zeroing in config array of weapon or attached optics
proto native bool PushCartridgeToChamber(int muzzleIndex, float ammoDamage, string ammoTypeName)
push cartridge to chamber
proto native owned string GetCurrentModeName(int muzzleIndex)
proto native float GetZoomMin(int muzzleIndex)
gets FOV minimum
proto native bool CreateRound(int muzzleIndex)
proto native UnderSlugLauncher GetAttachedLauncher()
proto native bool IsChamberFiredOut(int muzzleIndex)
detects presence of fired out casing in chamber
proto native bool CanAttachMagazine(int muzzleIndex, Magazine mag)
query if a magazine can be attached to weapon
proto native bool DryDryFire(int muzzleIndex)
proto native void SetMuzzleMode(int muzzleIndex, int modeIndex)
proto native bool EjectCasing(int muzzleIndex)
ejects casing from chamber
proto native bool DryFire(int muzzleIndex)
proto bool GetInternalMagazineCartridgeInfo(int muzzleIndex, int cartridgeIndex, out float ammoDamage, out string ammoTypeName)
get info about the cartridge in the internal magazine of a muzzle
proto native float GetZeroingDistanceZoomMin(int muzzleIndex)
Gets Zeroing distance at opticsZoomMin.
proto native ItemOptics GetAttachedOptics()
proto native bool IsChamberEmpty(int muzzleIndex)
detects empty chamber
proto native int GetInternalMagazineMaxCartridgeCount(int muzzleIndex)
proto native bool SetZoom(float percent)
sets current zoom (in %)
proto native bool FlashlightOff()
attempt to turn off flashlight
proto native float GetReloadTime(int muzzleIndex)
defines time from one shot to another
proto native void EffectBulletHide(int muzzleIndex)
reset effect cartridge in weapon
proto native int GetStepZeroing(int muzzleIndex=0)
returns position of currently used value in zeroing config array
proto native bool StepZeroingUp(int muzzleIndex=0)
sets zeroing to next defined (respective to current) value in zeroing config array
proto native bool TestAttachMagazine(int muzzleIndex, Magazine mag, bool do_occupancy_test, bool do_script_check)
query if a magazine can be attached to weapon
proto native int GetTotalCartridgeCount(int muzzleIndex)
proto bool PopCartridgeFromChamber(int muzzleIndex, out float ammoDamage, out string ammoTypeName)
removes cartridge from chamber
proto native bool IsChamberFull(int muzzleIndex)
maximum number of cartridges in chamber
proto native int GetInternalMagazineCartridgeCount(int muzzleIndex)
bool IsInternalMagazineFull(int muzzleIndex)
maximum number of cartridges in internal magazine
proto native void SelectionBulletShow()
proto native bool SetStepZeroing(int muzzleIndex, int step)
proto native owned string GetRandomChamberableAmmoTypeName(int muzzleIndex)
proto native bool CanFire(int muzzleIndex)
query whether the weapon can be fired or not
proto native float GetZoom()
returns current percentage of zoom
proto native void Synchronize()
Force synchronizes the weapon state from Server to Client. Use with caution.
proto native bool StepZoomIn()
sets zoom to next defined (respective to current) value in zoom fov config array
proto native void GetCameraPoint(int muzzleIndex, out vector pos, out vector dir)
gets camera position & direction in model space of weapon entity
proto native void SelectionMagazineHide()
proto native bool IsInOptics()
is weapon in optics mode or not
proto native owned string GetMaxMagazineTypeName(int muzzleIndex)
proto native int GetMagazineTypeCount(int muzzleIndex)
proto native void SetCurrentMuzzle(int muzzleIndex)
sets index of active muzzle
proto native int GetSlotFromMuzzleIndex(int muzzleIndex)
conversion muzzleIndex -> slotId
proto native int GetMuzzleCount()
proto native bool GetCurrentModeAutoFire(int muzzleIndex)
proto native Magazine GetMagazine(int muzzleIndex)
proto native void EffectBulletShow(int muzzleIndex, float dmg, string type)
push effect cartridge to Weapon
proto native void SetGroundAnimFrameIndex(int groundAnimFrameIndex)
sets animation frame for ground state when animation is specified in config
void StepZeroingDownAllMuzzles()
proto native ItemSuppressor GetAttachedSuppressor()
proto native float GetZeroingDistanceZoomMax(int muzzleIndex)
Gets Zeroing distance at opticsZoomMax.
proto native bool AttachMagazine(int muzzleIndex, Magazine mag)
perform attachment of a magazine to weapon
bool IsChamberFullEx(int muzzleIndex)
proto native bool ZoomOut()
moves current zoom by 1% down
proto native owned string GetChamberedCartridgeMagazineTypeName(int muzzleIndex)
query the type of magazine the cartridge can be unloaded to
proto bool PopCartridgeFromInternalMagazine(int muzzleIndex, out float ammoDamage, out string ammoTypeName)
removes top-most cartridge from internal magazine
proto native int GetStepZoom()
returns position of currently used value in zoom config array
proto native bool Fire(int muzzleIndex, vector pos, vector dir, vector speed)
proto native int GetCurrentMode(int muzzleIndex)
proto native void SelectionMagazineShow()
proto native int GetTotalMaxCartridgeCount(int muzzleIndex)
proto native owned string GetChamberAmmoTypeName(int muzzleIndex)
proto bool GetCartridgeInfo(int muzzleIndex, out float ammoDamage, out string ammoTypeName)
get info about the cartridge in the chamber of a muzzle
proto native bool PushCartridgeToInternalMagazine(int muzzleIndex, float ammoDamage, string ammoTypeName)
push cartridge into internal magazine
proto native bool IsFlashlightOn()
query state of flashlight
proto native float GetZoomMax(int muzzleIndex)
gets FOV maximum
proto native bool ZoomIn()
moves current zoom by 1% up
proto native bool SetStepZoom(int step)
sets zoom to fov value defined at given position in zoom fov config array
proto native void SelectionBulletHide()
proto native bool EnterOptics()
switches to optics mode if possible
proto native int GetMuzzleModeCount(int muzzleIndex)
proto native bool ExitOptics()
switches out of optics mode (if possible)
proto native int GetCurrentModeBurstSize(int muzzleIndex)
proto native bool IsChamberEjectable(int muzzleIndex)
detects presence of ejectable cartridge in muzzle's chamber
proto native bool IsChamberJammed(int muzzleIndex)
detects presence of damaged cartridge in chamber
proto native void SetNextMuzzleMode(int muzzleIndex)
proto native int GetCurrentMuzzle()
proto native void SetCurrentMode(int muzzleIndex, int mode)
proto native float GetZeroingClamp(int muzzleIndex=0)
returns maximum allowed discrete distance for the muzzle. Limits attached optics zeroing only!...
proto native bool HasInternalMagazine(int muzzleIndex)
proto native float GetZoomInit(int muzzleIndex)
gets FOV value, when entering optics
proto native bool StepZoomOut()
sets zoom to previous (respective to current) defined value in zoom fov config array
proto native bool CanChamberFromMag(int muzzleIndex, Magazine mag)
query if a bullet from magazine can be loaded into chamber
proto native bool StepZeroingDown(int muzzleIndex=0)
sets zeroing to previous (respective to current) defined value in zeroing config array
void StepZeroingUpAllMuzzles()
proto native bool FlashlightOn()
attempt to turn on flashlight
proto native owned string GetRandomMagazineTypeName(int muzzleIndex)
script counterpart to engine's class Weapon