Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
epoxy
GitHub Repository: epoxy/proj11
Path: blob/master/SLICK_HOME/src/org/newdawn/slick/state/BasicGameState.java
1457 views
1
package org.newdawn.slick.state;
2
3
import org.newdawn.slick.GameContainer;
4
import org.newdawn.slick.Input;
5
import org.newdawn.slick.SlickException;
6
7
/**
8
* A simple state used an adapter so we don't have to implement all the event methods
9
* every time.
10
*
11
* @author kevin
12
*/
13
public abstract class BasicGameState implements GameState {
14
/**
15
* @see org.newdawn.slick.ControlledInputReciever#inputStarted()
16
*/
17
public void inputStarted() {
18
19
}
20
21
/**
22
* @see org.newdawn.slick.InputListener#isAcceptingInput()
23
*/
24
public boolean isAcceptingInput() {
25
return true;
26
}
27
28
/**
29
* @see org.newdawn.slick.InputListener#setInput(org.newdawn.slick.Input)
30
*/
31
public void setInput(Input input) {
32
}
33
34
/**
35
* @see org.newdawn.slick.InputListener#inputEnded()
36
*/
37
public void inputEnded() {
38
}
39
40
/**
41
* @see org.newdawn.slick.state.GameState#getID()
42
*/
43
public abstract int getID();
44
45
/**
46
* @see org.newdawn.slick.InputListener#controllerButtonPressed(int, int)
47
*/
48
public void controllerButtonPressed(int controller, int button) {
49
}
50
51
/**
52
* @see org.newdawn.slick.InputListener#controllerButtonReleased(int, int)
53
*/
54
public void controllerButtonReleased(int controller, int button) {
55
}
56
57
/**
58
* @see org.newdawn.slick.InputListener#controllerDownPressed(int)
59
*/
60
public void controllerDownPressed(int controller) {
61
}
62
63
/**
64
* @see org.newdawn.slick.InputListener#controllerDownReleased(int)
65
*/
66
public void controllerDownReleased(int controller) {
67
}
68
69
/**
70
* @see org.newdawn.slick.InputListener#controllerLeftPressed(int)
71
*/
72
public void controllerLeftPressed(int controller) {
73
74
}
75
76
/**
77
* @see org.newdawn.slick.InputListener#controllerLeftReleased(int)
78
*/
79
public void controllerLeftReleased(int controller) {
80
}
81
82
/**
83
* @see org.newdawn.slick.InputListener#controllerRightPressed(int)
84
*/
85
public void controllerRightPressed(int controller) {
86
}
87
88
/**
89
* @see org.newdawn.slick.InputListener#controllerRightReleased(int)
90
*/
91
public void controllerRightReleased(int controller) {
92
}
93
94
/**
95
* @see org.newdawn.slick.InputListener#controllerUpPressed(int)
96
*/
97
public void controllerUpPressed(int controller) {
98
}
99
100
/**
101
* @see org.newdawn.slick.InputListener#controllerUpReleased(int)
102
*/
103
public void controllerUpReleased(int controller) {
104
}
105
106
/**
107
* @see org.newdawn.slick.InputListener#keyPressed(int, char)
108
*/
109
public void keyPressed(int key, char c) {
110
}
111
112
/**
113
* @see org.newdawn.slick.InputListener#keyReleased(int, char)
114
*/
115
public void keyReleased(int key, char c) {
116
}
117
118
/**
119
* @see org.newdawn.slick.InputListener#mouseMoved(int, int, int, int)
120
*/
121
public void mouseMoved(int oldx, int oldy, int newx, int newy) {
122
}
123
124
/**
125
* @see org.newdawn.slick.InputListener#mouseDragged(int, int, int, int)
126
*/
127
public void mouseDragged(int oldx, int oldy, int newx, int newy) {
128
}
129
130
/**
131
* @see org.newdawn.slick.InputListener#mouseClicked(int, int, int, int)
132
*/
133
public void mouseClicked(int button, int x, int y, int clickCount) {
134
}
135
136
/**
137
* @see org.newdawn.slick.InputListener#mousePressed(int, int, int)
138
*/
139
public void mousePressed(int button, int x, int y) {
140
}
141
142
/**
143
* @see org.newdawn.slick.InputListener#mouseReleased(int, int, int)
144
*/
145
public void mouseReleased(int button, int x, int y) {
146
}
147
148
/**
149
* @see org.newdawn.slick.state.GameState#enter(org.newdawn.slick.GameContainer, org.newdawn.slick.state.StateBasedGame)
150
*/
151
public void enter(GameContainer container, StateBasedGame game) throws SlickException {
152
}
153
154
/**
155
* @see org.newdawn.slick.state.GameState#leave(org.newdawn.slick.GameContainer, org.newdawn.slick.state.StateBasedGame)
156
*/
157
public void leave(GameContainer container, StateBasedGame game) throws SlickException {
158
}
159
160
/**
161
* @see org.newdawn.slick.InputListener#mouseWheelMoved(int)
162
*/
163
public void mouseWheelMoved(int newValue) {
164
}
165
166
}
167
168