public class Weapon
extends java.lang.Object
Constructor and Description |
---|
Weapon(int id,
MovableEntity parent) |
Modifier and Type | Method and Description |
---|---|
int |
getId() |
Point |
getImpactPoint()
returns the position of the laserdot, the point where the aiming impacts
|
java.lang.String |
getName() |
int |
getReloadingTime() |
static int |
getScaling() |
int |
getShots() |
int |
getShotsLoaded() |
static com.badlogic.gdx.graphics.g2d.TextureAtlas |
getSpritesheetBig() |
static void |
init() |
void |
reload() |
void |
renderBig(GameView view,
int x,
int y)
Renders a big version of the image
|
void |
setFire(com.badlogic.gdx.backends.lwjgl.audio.Wav.Sound fire) |
void |
setReload(com.badlogic.gdx.backends.lwjgl.audio.Wav.Sound reload) |
static void |
setSpritesheetBig(com.badlogic.gdx.graphics.g2d.TextureAtlas spritesheetBig) |
void |
shoot() |
void |
update(float delta)
Manages the weapon
|
public Weapon(int id, MovableEntity parent)
id
- parent
- public static void init()
public void renderBig(GameView view, int x, int y)
view
- x
- y
- public static com.badlogic.gdx.graphics.g2d.TextureAtlas getSpritesheetBig()
public int getId()
public static int getScaling()
public void update(float delta)
delta
- t in mspublic void shoot()
public void reload()
public int getShotsLoaded()
public int getShots()
public java.lang.String getName()
public int getReloadingTime()
public static void setSpritesheetBig(com.badlogic.gdx.graphics.g2d.TextureAtlas spritesheetBig)
spritesheetBig
- public void setFire(com.badlogic.gdx.backends.lwjgl.audio.Wav.Sound fire)
fire
- public void setReload(com.badlogic.gdx.backends.lwjgl.audio.Wav.Sound reload)
reload
- public Point getImpactPoint()