public abstract class AbstractClouds extends java.lang.Object implements BackgroundComponent
Constructor and Description |
---|
AbstractClouds(java.lang.String path,
int cloudWidth,
int cloudHeight,
boolean wide,
int screenWidth,
int decY,
int factor) |
Modifier and Type | Method and Description |
---|---|
void |
render(java.awt.Graphics2D g) |
void |
setSpeed(int line,
float speed)
Set cloud line speed (usually, line 0 is faster than last line).
|
void |
setY(int line,
int y)
Set cloud line height (usually, line 0 is higher than last line).
|
void |
update(int x,
int y,
float speed,
float extrp) |
public AbstractClouds(java.lang.String path, int cloudWidth, int cloudHeight, boolean wide, int screenWidth, int decY, int factor)
public final void setY(int line, int y)
line
- cloud line (0 = top, last = bottom).y
- cloud height.public final void setSpeed(int line, float speed)
line
- cloud line (0 = top, last = bottom).speed
- cloud speed.public void update(int x, int y, float speed, float extrp)
update
in interface BackgroundComponent
public void render(java.awt.Graphics2D g)
render
in interface BackgroundComponent