Package megamek.common.weapons.handlers
Class NarcHandler
java.lang.Object
megamek.common.weapons.handlers.WeaponHandler
megamek.common.weapons.handlers.AmmoWeaponHandler
megamek.common.weapons.handlers.MissileWeaponHandler
megamek.common.weapons.handlers.NarcHandler
- All Implemented Interfaces:
Serializable,AttackHandler
- See Also:
-
Field Summary
Fields inherited from class megamek.common.weapons.handlers.MissileWeaponHandler
multiAMSFields inherited from class megamek.common.weapons.handlers.AmmoWeaponHandler
ammoFields inherited from class megamek.common.weapons.handlers.WeaponHandler
advancedPD, ammoType, amsBayEngaged, amsBayEngagedCap, amsBayEngagedMissile, amsEngaged, announcedEntityFiring, apdsEngaged, attackingEntity, attackValue, bDirect, bGlancing, bLowProfileGlancing, bMissed, bSalvo, calcDmgPerHitReport, CapMissileAMSMod, CapMissileArmor, CapMissileMissed, CounterAV, damageType, firstHit, game, gameManager, generalDamageType, hit, insertedAttacks, isJammed, isStrafing, isStrafingFirstShot, missed, nDamPerHit, nRange, nSalvoBonus, nukeS2S, numRapidFireHits, numWeapons, numWeaponsHit, originalAV, parentBayHandler, pdBayEngaged, pdBayEngagedCap, pdBayEngagedMissile, pdOverheated, roll, secondShot, sSalvoType, subjectId, target, throughFront, toHit, typeName, underWater, weapon, weaponAttackAction, weaponEntity, weaponType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected intCalculate the damage per hit.protected intCalculate the number of hitsprotected intCalculate the clustering of the hitsprotected voidhandleEntityDamage(Entity entityTarget, Vector<Report> vPhaseReport, IBuilding bldg, int hits, int nCluster, int bldgAbsorbs) Handle damage against an entity, called once per hit by default.protected voidSets the appropriate AMS Bay reporting flag depending on what type of missile this isprotected voidSets the appropriate PD Bay reporting flag depending on what type of missile this isprotected booleanNarcs apply "damage" all in one block for AMS purposes This was referenced incorrectly for Aero damage.Methods inherited from class megamek.common.weapons.handlers.MissileWeaponHandler
calcAttackValue, getAeroSanityAMSHitsMod, getAMSHitsMod, handle, handleSpecialMiss, isAdvancedAMS, isNemesisConfusable, isThunderBoltMethods inherited from class megamek.common.weapons.handlers.AmmoWeaponHandler
checkAmmo, doAmmoFeedProblemCheck, doChecks, explodeRoundInBarrel, getNumberWeapons, useAmmoMethods inherited from class megamek.common.weapons.handlers.WeaponHandler
absorbBuildingDamage, addGlancingBlowReports, addHeat, allShotsHit, announcedEntityFiring, applyGlancingBlowModifier, applyGlancingBlowModifier, calcAeroDamage, calcCapMissileAMSMod, calcCounterAV, calculateNumClusterAero, canEngageCapitalMissile, cares, checkLI, checkPDConditions, checkTerrain, getAttacker, getAttackerId, getBracketingMultiplier, getCapMisMod, getCapMissileAMSMod, getClusterModifiers, getCounterAV, getFireTNRoll, getLargeCraftHeat, getParentBayHandler, getSalvoBonus, getTotalGlancingBlowFactor, getWeaponAttackAction, handleArtilleryDriftMarker, handleBuildingDamage, handleClearDamage, handleClearDamage, handleIgnitionDamage, handlePartialCoverHit, initHit, insertAttacks, isLowProfileGlancingBlow, isStrafing, isStrafingFirstShot, reportMiss, reportMiss, restore, setAnnouncedEntityFiring, setDone, setGlancingBlowFlags, setParentBayHandler, setStrafing, setStrafingFirstShot, specialResolution, unitGainsPartialCoverFromWater, unitStickingOutOfBuildingMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface megamek.common.weapons.handlers.AttackHandler
getBuildingDamageAdjustment, producesReportThisPhase
-
Constructor Details
-
NarcHandler
public NarcHandler(ToHitData t, WeaponAttackAction w, Game g, TWGameManager m) throws EntityLoadingException - Throws:
EntityLoadingException
-
-
Method Details
-
calcHits
Description copied from class:WeaponHandlerCalculate the number of hits- Overrides:
calcHitsin classMissileWeaponHandler- Parameters:
vPhaseReport- - theVectorcontaining the phase report.- Returns:
- an
intcontaining the number of hits.
-
setAMSBayReportingFlag
protected void setAMSBayReportingFlag()Sets the appropriate AMS Bay reporting flag depending on what type of missile this is- Overrides:
setAMSBayReportingFlagin classMissileWeaponHandler
-
setPDBayReportingFlag
protected void setPDBayReportingFlag()Sets the appropriate PD Bay reporting flag depending on what type of missile this is- Overrides:
setPDBayReportingFlagin classMissileWeaponHandler
-
calculateNumCluster
protected int calculateNumCluster()Description copied from class:WeaponHandlerCalculate the clustering of the hits- Overrides:
calculateNumClusterin classMissileWeaponHandler- Returns:
- a
intvalue saying how much hits are in each cluster of damage.
-
usesClusterTable
protected boolean usesClusterTable()Narcs apply "damage" all in one block for AMS purposes This was referenced incorrectly for Aero damage.- Overrides:
usesClusterTablein classMissileWeaponHandler
-
calcDamagePerHit
protected int calcDamagePerHit()Description copied from class:WeaponHandlerCalculate the damage per hit.- Overrides:
calcDamagePerHitin classMissileWeaponHandler- Returns:
- an
intrepresenting the damage dealt per hit.
-
handleEntityDamage
protected void handleEntityDamage(Entity entityTarget, Vector<Report> vPhaseReport, IBuilding bldg, int hits, int nCluster, int bldgAbsorbs) Description copied from class:WeaponHandlerHandle damage against an entity, called once per hit by default.- Overrides:
handleEntityDamagein classWeaponHandler
-