public interface DamagingProjectileAPI extends CombatEntityAPI
| Modifier and Type | Method and Description |
|---|---|
void |
addDamagedAlready(CombatEntityAPI c)
Only supported by damaging explosions, not other types of projectiles.
|
boolean |
didDamage()
Whether the projectile already did its damage and is now fading out.
|
float |
getBaseDamageAmount()
Does not include damage reduction from projectile fading out or having done damage
|
float |
getBrightness() |
DamageAPI |
getDamage() |
float |
getDamageAmount() |
java.util.List<CombatEntityAPI> |
getDamagedAlready() |
CombatEntityAPI |
getDamageTarget() |
DamageType |
getDamageType() |
float |
getElapsed()
Time the projectile has been alive.
|
float |
getEmpAmount() |
default DamagingExplosionSpec |
getExplosionSpecIfExplosion() |
float |
getMoveSpeed()
Projectile movement is entirely defined by moveSpeed and facing.
|
ProjectileSpecAPI |
getProjectileSpec() |
java.lang.String |
getProjectileSpecId() |
ShipAPI |
getSource()
Generally a ShipAPI for the ship that ultimately fired this weapon.
|
org.lwjgl.util.vector.Vector2f |
getSpawnLocation() |
ProjectileSpawnType |
getSpawnType() |
org.lwjgl.util.vector.Vector2f |
getTailEnd()
Only non-null for "moving ray" and "ballistic projectile" type projectiles, not missiles/plasma shots/etc.
|
WeaponAPI |
getWeapon() |
boolean |
isFading() |
boolean |
isFromMissile() |
void |
removeDamagedAlready(CombatEntityAPI c)
Only supported by damaging explosions, not @Override
other types of projectiles.
|
void |
setDamageAmount(float damage) |
void |
setFromMissile(boolean fromMissile)
Should be set to true for BALLISTIC, BALLISTIC_AS_BEAM, and PLASMA_SHOT projectiles
spawned from a missile.
|
void |
setSource(ShipAPI source) |
getAI, getAngularVelocity, getCollisionClass, getCollisionRadius, getCustomData, getExactBounds, getFacing, getHitpoints, getHullLevel, getLocation, getMass, getMaxHitpoints, getOwner, getShield, getVelocity, isExpired, isPointInBounds, removeCustomData, setAngularVelocity, setCollisionClass, setCollisionRadius, setCustomData, setFacing, setHitpoints, setMass, setOwner, wasRemovedDamageType getDamageType()
float getDamageAmount()
float getBaseDamageAmount()
float getEmpAmount()
void setDamageAmount(float damage)
WeaponAPI getWeapon()
boolean didDamage()
CombatEntityAPI getDamageTarget()
java.lang.String getProjectileSpecId()
ShipAPI getSource()
boolean isFading()
ProjectileSpawnType getSpawnType()
float getElapsed()
boolean isFromMissile()
void setFromMissile(boolean fromMissile)
fromMissile - void removeDamagedAlready(CombatEntityAPI c)
c - void addDamagedAlready(CombatEntityAPI c)
c - float getMoveSpeed()
org.lwjgl.util.vector.Vector2f getSpawnLocation()
ProjectileSpecAPI getProjectileSpec()
float getBrightness()
org.lwjgl.util.vector.Vector2f getTailEnd()
java.util.List<CombatEntityAPI> getDamagedAlready()
default DamagingExplosionSpec getExplosionSpecIfExplosion()