Hello JGO, haven’t posted something i’ve programmed in a while lol.
Here’s a simple abstract Game Engine i made today, all in 1 file :o.
JAR file: http://www.mediafire.com/?79g2w8c3loi23el
USAGE:
import org.elite.engine.GameEngine; // Import the GameEngine class inside the GameEngine.JAR hurr hurr
public class ExampleUsage {
static GameEngine g; // simple game instance.
static int interval = 10; // GameEngine Cycle interval
public static void main(String[] args) {
GameEngine game = new GameEngine(interval) {
public void process() { // Abstract method
methodYouCreated(); // Task being done
}
};
g = game; // simple game instance.
g.start(); // Get it running xD
}
protected static void methodYouCreated() {
// Do whatever you would normally do in a GameLoop
}
}
// few getters & setters for fast changes :)
// GameEngine.getGameSettings().setCycleInterval(1234); >> Interval changed from: 10 to: 1234.
// GameEngine.getGameSettings().getCycleInterval(); >> returns CycleInterval.
Hope somebody finds this useful :yawn: