com.fs.starfarer.api.combat
Interface ShieldAPI


public interface ShieldAPI

Author:
Alex Mosolov Copyright 2012 Fractal Softworks, LLC

Nested Class Summary
static class ShieldAPI.ShieldType
           
 
Method Summary
 void forceFacing(float facing)
           
 float getActiveArc()
           
 float getArc()
           
 float getFacing()
           
 float getFluxPerPointOfDamage()
          Does not include shield damage taken mult, but does include absorbption mult.
 java.awt.Color getInnerColor()
           
 float getInnerRotationRate()
          For shield textures, visual only.
 Vector2f getLocation()
           
 float getRadius()
           
 java.awt.Color getRingColor()
           
 float getRingRotationRate()
          For shield textures, visual only.
 ShieldAPI.ShieldType getType()
           
 float getUnfoldTime()
           
 float getUpkeep()
          Flux/second while shield is on.
 boolean isOff()
           
 boolean isOn()
           
 boolean isWithinArc(Vector2f point)
           
 void setActiveArc(float activeArc)
           
 void setArc(float arc)
          Set the maximum arc.
 void setCenter(float x, float y)
           
 void setInnerColor(java.awt.Color color)
           
 void setInnerRotationRate(float innerRotationRate)
          For shield textures, visual only.
 void setRadius(float radius)
           
 void setRadius(float radius, java.lang.String textureInner, java.lang.String textureRing)
          Textures should be already loaded (i.e.
 void setRingColor(java.awt.Color ringColor)
           
 void setRingRotationRate(float ringRotationRate)
          For shield textures, visual only.
 void setType(ShieldAPI.ShieldType type)
           
 void toggleOff()
           
 void toggleOn()
           
 

Method Detail

setType

void setType(ShieldAPI.ShieldType type)

getType

ShieldAPI.ShieldType getType()

getFacing

float getFacing()

getArc

float getArc()
Returns:
maximum arc.

getActiveArc

float getActiveArc()
Returns:
currently open arc (0 if not on)

setActiveArc

void setActiveArc(float activeArc)

getRadius

float getRadius()

isOn

boolean isOn()

isOff

boolean isOff()

getLocation

Vector2f getLocation()
Returns:
location of the center of the shield, in engine coordinates.

isWithinArc

boolean isWithinArc(Vector2f point)

toggleOff

void toggleOff()

getFluxPerPointOfDamage

float getFluxPerPointOfDamage()
Does not include shield damage taken mult, but does include absorbption mult.

Returns:

setArc

void setArc(float arc)
Set the maximum arc.

Parameters:
arc -

setInnerColor

void setInnerColor(java.awt.Color color)

setRingColor

void setRingColor(java.awt.Color ringColor)

getInnerColor

java.awt.Color getInnerColor()

getRingColor

java.awt.Color getRingColor()

getUpkeep

float getUpkeep()
Flux/second while shield is on.

Returns:

forceFacing

void forceFacing(float facing)

setRadius

void setRadius(float radius)

setRadius

void setRadius(float radius,
               java.lang.String textureInner,
               java.lang.String textureRing)
Textures should be already loaded (i.e. via settings.json).

Parameters:
radius -
textureInner -
textureRing -

toggleOn

void toggleOn()

getUnfoldTime

float getUnfoldTime()

setCenter

void setCenter(float x,
               float y)

getInnerRotationRate

float getInnerRotationRate()
For shield textures, visual only.

Returns:

setInnerRotationRate

void setInnerRotationRate(float innerRotationRate)
For shield textures, visual only.


getRingRotationRate

float getRingRotationRate()
For shield textures, visual only.

Returns:

setRingRotationRate

void setRingRotationRate(float ringRotationRate)
For shield textures, visual only.



Copyright © 2013 Fractal Softworks, LLC. All Rights Reserved.