-
Notifications
You must be signed in to change notification settings - Fork 0
DotNet.Ships.Class.Weapons
EliteDangerousAlmanac / Ships / Weapons
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:243
Damage per second, capacitor draw per second, heat per second, and how the damage splits by type.
A weapon's catalogue record gives damage per round. Turning that into damage per second means folding in the rounds per shot and the rate of fire, and, for the sustained figures, the clip and the reload, because a weapon that stops to reload is not firing.
Beam and mining lasers are continuous. They carry no rate of fire, and their damage, draw and thermal load are already per second, so the per-second figures collapse to the raw stats.
Reference implementation: EDCD/Coriolis, src/app/shipyard/Module.js, cross-checked against EDSY. The algorithm is ported as fact rather than as code. See ATTRIBUTIONS.md for credit and licence terms.
staticArmourPiercingFactor(armourPiercing,hardness):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:432
How much of a weapon's damage a hull's hardness lets through.
double
The weapon's piercing rating.
double
The target hull's hardness. No hardness disables the scaling, which is what to pass where the hardness is unknown.
double
A factor from zero through one: the whole of it where the weapon out-pierces the hull, and the piercing over the hardness otherwise. No hardness always answers the whole of it, because it disables the scaling.
This applies to hull damage alone. Shields do not care.
ArgumentOutOfRangeException
An argument is not a finite number of zero or more.
staticCombinedRateOfFire(weapon):double?
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:293
The combined rate of fire a weapon's firing cycle implies, which is the journal's own rate rebuilt from its parts.
The weapon's stats, post-engineering.
double?
The shots per second, or null for a continuous-fire weapon, or for a cycle that does not resolve to a time above zero.
A cycle fires its burst rounds a burst rate apart, then waits out the burst interval before the next one. A charge time is the delay before a shot lands, and not part of the cadence Frontier reports.
The cycle is rebuilt the way the game builds it, a float stored after every operation and then written to six decimal places, so the answer is the figure the game reports rather than one a little beside it. Use it for parts changed by hand: a recipe that gives a weapon a two-round burst changes the rate of fire without naming it. A weapon read from a build needs no recomputation, because its rate is already this figure.
ArgumentNullException
weapon is null.
staticDamageFalloff(weapon,metres):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:400
How much of a weapon's damage still lands at a given range.
The weapon's stats.
double
The range to the target, in metres.
double
A factor from zero through one: the whole of it inside the falloff range, tapering to nothing at the largest range and staying there beyond it. A weapon with no falloff data reports the whole of it up to its largest range.
The projectile boundary parameters are deliberately ignored: this is attenuation, not projectile reach.
ArgumentNullException
weapon is null.
staticDamagePerSecond(weapon):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:347
The damage per second while the trigger is held, reloads ignored.
The weapon's stats.
double
The damage per second. A continuous-fire weapon reports its damage unchanged, because that stat is already per second.
ArgumentNullException
weapon is null.
staticEnergyPerSecond(weapon):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:369
The weapons-capacitor draw per second, in megawatts.
The weapon's stats.
double
The capacitor draw per second, reloads ignored. For firing endurance, use WeaponsCapacitor.Metrics, which compares the pip-scaled recharge with the sustained draw rather than this burst rate.
ArgumentNullException
weapon is null.
staticHeatPerSecond(weapon):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:380
The heat generated per second.
The weapon's stats.
double
The heat per second, reloads ignored.
ArgumentNullException
weapon is null.
staticMetrics(weapon):WeaponMetrics
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:448
Everything an outfitting screen shows about one weapon: the damage per second, the sustained damage per second, the capacitor and heat cost of firing it, and the damage split by type.
The weapon's stats, post-engineering.
The weapon's metrics.
ArgumentNullException
weapon is null.
staticSplitDamage(damage,distribution):DamageSplit
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:255
Splits a per-second or per-shot damage figure by damage type.
double
The figure to split.
The weapon's damage distribution. An absent one treats the whole figure as absolute damage, which no resistance reduces.
The share of the damage in each type. The anti-xeno share overlays conventional damage rather than partitioning it, and the other shares sum back to the figure.
staticSum(metrics):WeaponTotals
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:481
Adds several weapons' metrics together, for a build's total firepower.
IReadOnlyList<WeaponMetrics>
The per-weapon metrics to sum.
The additive totals. An empty list answers no firepower at all.
ArgumentNullException
metrics is null.
staticSustainedDamagePerSecond(weapon):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:358
The damage per second averaged over reloads, which a long engagement sees.
The weapon's stats.
double
The sustained damage per second.
ArgumentNullException
weapon is null.
staticSustainedFireFactor(weapon):double
Defined in: dotnet/src/EliteDangerousAlmanac/Ships/Weapons.cs:321
The factor that turns a weapon's while-firing figures into sustained ones: the share of the time it spends shooting rather than reloading.
The weapon's stats.
double
A factor above zero and at most one. It is one for anything that never stops to reload, and less for a weapon whose clip runs dry.
A clip's worth of fire takes the rounds after the first burst at the rate of fire, plus the time to finish the last burst, and then the reload. The sustained rate is the clip divided by that whole cycle. A part clip is held to whole rounds, rounding up, which only a hand-built or journal-stated figure can be: an engineered clip is rounded to a whole burst where the roll is computed.
ArgumentNullException
weapon is null.
Guides
Astronomy
Classes (16)
Records (29)
- AbsoluteBoxel
- AtmosphereComponent
- BodyComposition
- BodyParent
- BodyProperties
- BodyRing
- BodyScanEvent
- BoxelCodexRegion
- BoxelLetters
- CodexRegion
- CodexRegionBounds
- DecodedSystemAddress
- GalacticPlanePosition
- GalacticPosition
- HandAuthoredRegion
- HandAuthoredSphere
- MassStabilityAssessment
- NamingRegionOrigin
- Nebula
- NebulaNearby
- OrbitExtents
- PermitLock
- PermitLockedSystem
- RingDynamics
- RocheLimits
- SectorGridPosition
- SpinOrbitResonance
- SurfaceMaterial
- SystemNameParts
Commodities
Classes (2)
Records (1)
Enumerations (1)
Equipment
Classes (8)
Records (19)
- FittedPersonalModification
- FittedPersonalWeapon
- PersonalEngineeringIngredient
- PersonalModification
- PersonalModifier
- PersonalMount
- PersonalTool
- PersonalWeapon
- PersonalWeaponGrade
- PersonalWeaponMetrics
- ReloadTime
- ScopeMagnification
- Suit
- SuitGrade
- SuitIdentity
- SuitLoadout
- SuitLoadoutEvent
- SuitLoadoutImportOutcome
- SuitLoadoutModuleEvent
Materials
Classes (5)
Records (2)
Enumerations (4)
Ships
Classes (42)
- Ammunition
- Armour
- BlueprintCatalogue
- BlueprintCosts
- BlueprintJournal
- BuildMetrics
- BuildSlots
- CalculationResult\<T\>
- CalculationResult
- DefaultLoadouts
- Distributor
- Engineering
- EngineeringOptions
- ExperimentalEffectCatalogue
- ExperimentalEffectCosts
- Gunsights
- Heat
- JumpRange
- LoadoutCalculations
- LoadoutEditException
- LoadoutValidator
- Mobility
- MobilityCapacitor
- ModuleCapabilities
- ModuleCatalogue
- ModuleLimits
- ModuleStats
- OutfittingFamilies
- Power
- PreEngineeredCatalogue
- PreEngineeredStats
- Resistances
- ShieldCapacitor
- ShieldRecovery
- Shields
- ShipCatalogue
- ShipLoadout
- Slef
- SlotRestrictions
- SourcePurchase
- Weapons
- WeaponsCapacitor
Records (115)
- AmmunitionCapacity
- ApplyBlueprintOptions
- ArmourInput
- ArmourMetrics
- AvailableBlueprint
- Blueprint
- BlueprintCost
- BlueprintFeature
- BlueprintGrade
- BuildCost
- BuildCredits
- BuildLoad
- BuildMass
- BuildSlot
- BuildWeaponMetrics
- BulkheadParams
- CalculationIssue
- CellBankInput
- CellBankMetrics
- CellBankSummary
- CoreSlots
- DamageComponents
- DamageDistribution
- DamageSplit
- DamageTypeValues
- DefaultLoadout
- DefaultLoadoutModule
- DistributorCapacitorMetrics
- DistributorInput
- DistributorMetrics
- DistributorPips
- EngineeringAmbiguous
- EngineeringEditDetail
- EngineeringGradeEdit
- EngineeringMaterial
- EngineeringModifier
- EngineeringOptionGroup
- EngineeringRerolled
- EngineeringUnresolved
- ExperimentalContribution
- ExperimentalEffect
- ExperimentalEffectEdit
- FittedModule
- FittedWeaponMetrics
- FixedMountRepair
- FrameShiftDriveParams
- GunsightOffset
- GunsightPoint
- HardpointSlotSpec
- HeatInput
- HeatMetrics
- HeatState
- HeatWeapon
- HullReinforcementParams
- JumpRangeSummary
- LoadoutCalculationModule
- LoadoutEvent
- LoadoutExportOptions
- LoadoutFuelCapacity
- LoadoutImportOutcome
- LoadoutIssue
- LoadoutMass
- LoadoutModule
- LoadoutSlot
- LoadoutValidation
- LoadoutValidationInput
- MobilityCapacitorMetrics
- MobilityInput
- MobilityMetrics
- ModuleDefaulted
- ModuleEmptied
- ModuleEngineering
- ModuleFitProblem
- ModuleLimitEntry
- ModuleLimitIncrease
- ModuleLimitUsage
- ModuleReinforcementParams
- OptionalSlotSpec
- OutfittingModule
- ParsedSlot
- PowerBand
- PowerBudget
- PowerConsumer
- PowerConsumerResult
- PreEngineeredModifier
- PreEngineeredVariant
- ProjectileRangeBoundaries
- ShieldBoosterParams
- ShieldCapacitorInput
- ShieldCapacitorMetrics
- ShieldGeneratorParams
- ShieldInput
- ShieldMetrics
- ShieldRecoveryInput
- ShieldRecoveryMetrics
- Ship
- ShipSlots
- SlefDiagnostic
- SlefEntry
- SlefExportOptions
- SlefHeader
- SlefInspection
- SourceModuleValue
- SourcePurchaseRecord
- StandardLoadFigures
- ThrusterCurveParams
- ThrusterParams
- TotalRangeDetails
- UnpricedModule
- ValidationModule
- WeaponMetrics
- WeaponsCapacitorInput
- WeaponsCapacitorMetrics
- WeaponStats
- WeaponTotals
Interfaces (1)
Enumerations (35)
- BlueprintRoute
- CalculationField
- CalculationIssueReason
- CoreSlotType
- DamageType
- EngineeringEditCode
- EngineeringEditKind
- EngineeringGroupId
- FixedMountRepairStatus
- ImmovableReason
- LoadoutCredits
- LoadoutEditErrorCode
- LoadoutImportAction
- LoadoutIssueCode
- LoadoutIssueSeverity
- LoadoutModuleOrder
- ModifierMethod
- ModuleCategory
- ModuleExclusionGroup
- ModuleFitConstraint
- ModuleGuidance
- ModuleLimitGroup
- ModuleMount
- ModuleRating
- ModuleSlot
- ModuleStat
- OutfittingFamilyId
- PreEngineeredAcquisition
- ShipSize
- SlefConstraint
- SlefDiagnosticCode
- SlotKind
- SlotRestriction
- StandardLoad
- ThrusterLoad