-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLog.java
More file actions
36 lines (24 loc) · 786 Bytes
/
Log.java
File metadata and controls
36 lines (24 loc) · 786 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
public class Log extends Get {
public static final String LOG_IMAGE_FILE = "game_assets/LOG.gif";
public static final int LOG_DEFAULT_SCROLL_SPEED = 1;
private static int uniScrollSpeed = LOG_DEFAULT_SCROLL_SPEED;
public Log(){
this(0, 0);
}
public Log(int x, int y){
super(x, y, GET_WIDTH, GET_HEIGHT, LOG_IMAGE_FILE);
}
public Log(int x, int y, String imageFileName){
super(x, y, GET_WIDTH, GET_HEIGHT, imageFileName);
}
public static int getUnivScrollSpeed(){
return uniScrollSpeed;
}
public static void setUnivScrollSpeed(int newSpeed){
uniScrollSpeed = newSpeed;
}
@Override
public void scroll(){
setX(getX() - uniScrollSpeed);
}
}