EigenMeat.EigenMaze
Class Projectile

java.lang.Object
  extended byEigenMeat.EigenMaze.Entity
      extended byEigenMeat.EigenMaze.MassEntity
          extended byEigenMeat.EigenMaze.Projectile
All Implemented Interfaces:
java.lang.Cloneable, Drawable, MobileEntity

public class Projectile
extends MassEntity

Basic class for any projectiles.


Field Summary
protected  float blastRadius
           
protected  boolean bounces
           
protected  short BYTE_LENGTH
           
protected  java.nio.ByteBuffer netBuffer
           
protected  short netID
           
protected  ParticleEffect peffect
           
protected  boolean weathervane
           
 
Fields inherited from class EigenMeat.EigenMaze.Entity
dead, forwardVect, position, rawVelocity, timedDeath, timeToDie, velocity
 
Constructor Summary
Projectile()
          Default constructor.
 
Method Summary
 boolean collide(MobileEntity entity)
          Called when Bomb hits something.
 void die()
          Called when the Projectile dies, either by impact or old age.
 float getDamage()
          Get the damage the projectile can inflict
 java.nio.ByteBuffer getData()
           
 short getDataSize()
           
 short getOwnerID()
           
 short getType()
           
 void receiveData(java.nio.ByteBuffer bb)
           
 void setDamage(float damage)
          Set the projectile's damage.
 void setOwnerID(short id)
           
 void update()
          Update function
 
Methods inherited from class EigenMeat.EigenMaze.MassEntity
getMass, setMass
 
Methods inherited from class EigenMeat.EigenMaze.Entity
checkCollision, clone, draw, drawShadow, getBoundingSphere, getForwardVect, getMesh, getPosition, getRawVelocity, getVelocity, getYRot, getZRot, hasShadow, isDead, setBoundingSphere, setCastShadow, setDead, setMesh, setPosition, setPosition, setTimedDeath, setVelocity, setVelocity, setYRot, setZRot, translate
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

peffect

protected ParticleEffect peffect

bounces

protected boolean bounces

weathervane

protected boolean weathervane

blastRadius

protected float blastRadius

BYTE_LENGTH

protected final short BYTE_LENGTH
See Also:
Constant Field Values

netBuffer

protected java.nio.ByteBuffer netBuffer

netID

protected short netID
Constructor Detail

Projectile

public Projectile()
Default constructor.

Method Detail

setDamage

public void setDamage(float damage)
Set the projectile's damage.

Parameters:
damage - damage

getDamage

public float getDamage()
Get the damage the projectile can inflict

Returns:
damage

update

public void update()
Update function

Specified by:
update in interface MobileEntity
Overrides:
update in class Entity

die

public void die()
Called when the Projectile dies, either by impact or old age.

Specified by:
die in interface MobileEntity
Overrides:
die in class Entity

collide

public boolean collide(MobileEntity entity)
Called when Bomb hits something.

Specified by:
collide in interface MobileEntity
Overrides:
collide in class Entity
Parameters:
entity - the entity bomb collided with

getOwnerID

public short getOwnerID()

setOwnerID

public void setOwnerID(short id)

getType

public short getType()

getDataSize

public short getDataSize()

getData

public java.nio.ByteBuffer getData()

receiveData

public void receiveData(java.nio.ByteBuffer bb)