Class GunComponent
Inheritance
System.Object
GunComponent
Assembly: Content.Shared.dll
Syntax
public class GunComponent : Component
Fields
|
Improve this Doc
View Source
AngleDecay
Declaration
Field Value
|
Improve this Doc
View Source
AngleIncrease
How much the spread increases every time the gun fires.
Declaration
public Angle AngleIncrease
Field Value
|
Improve this Doc
View Source
AvailableModes
What firemodes can be selected.
Declaration
public SelectiveFire AvailableModes
Field Value
|
Improve this Doc
View Source
CameraRecoilScalar
A scalar value applied to the vector governing camera recoil.
If 0, there will be no camera recoil.
Declaration
public float CameraRecoilScalar
Field Value
Type |
Description |
System.Single |
|
|
Improve this Doc
View Source
ClumsyProof
Whether or not someone with the
clumsy trait can shoot this
Declaration
Field Value
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
CurrentAngle
What the current spread is for shooting. This gets changed every time the gun fires.
Declaration
public Angle CurrentAngle
Field Value
|
Improve this Doc
View Source
FireRate
How many times it shoots per second.
Declaration
Field Value
Type |
Description |
System.Single |
|
|
Improve this Doc
View Source
LastFire
Last time the gun fired.
Used for recoil purposes.
Declaration
Field Value
Type |
Description |
TimeSpan |
|
|
Improve this Doc
View Source
MaxAngle
Declaration
Field Value
|
Improve this Doc
View Source
MinAngle
Declaration
Field Value
|
Improve this Doc
View Source
NextFire
When the gun is next available to be shot.
Can be set multiple times in a single tick due to guns firing faster than a single tick time.
Declaration
Field Value
Type |
Description |
TimeSpan |
|
|
Improve this Doc
View Source
ProjectileSpeed
How fast the projectile moves.
Declaration
public float ProjectileSpeed
Field Value
Type |
Description |
System.Single |
|
|
Improve this Doc
View Source
ResetOnHandSelected
Starts fire cooldown when equipped if true.
Declaration
public bool ResetOnHandSelected
Field Value
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
SelectedMode
What firemode is currently selected.
Declaration
public SelectiveFire SelectedMode
Field Value
|
Improve this Doc
View Source
ShootCoordinates
Where the gun is being requested to shoot.
Declaration
public EntityCoordinates? ShootCoordinates
Field Value
Type |
Description |
System.Nullable<Robust.Shared.Map.EntityCoordinates> |
|
|
Improve this Doc
View Source
ShotCounter
Used for tracking semi-auto / burst
Declaration
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
ShowExamineText
Whether or not information about
the gun will be shown on examine.
Declaration
public bool ShowExamineText
Field Value
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
SoundEmpty
Declaration
public SoundSpecifier SoundEmpty
Field Value
Type |
Description |
Robust.Shared.Audio.SoundSpecifier |
|
|
Improve this Doc
View Source
SoundGunshot
Declaration
public SoundSpecifier SoundGunshot
Field Value
Type |
Description |
Robust.Shared.Audio.SoundSpecifier |
|
|
Improve this Doc
View Source
SoundModeToggle
Declaration
public SoundSpecifier SoundModeToggle
Field Value
Type |
Description |
Robust.Shared.Audio.SoundSpecifier |
|
|
Improve this Doc
View Source
UseKey
Whether this gun is shot via the use key or the alt-use key.
Declaration
Field Value
Type |
Description |
System.Boolean |
|