I successfully compiled my source using this command:
javac -classpath "..\lwjgl-2.7.1\jar\lwjgl.jar" Game.java
However, when I try to run it using:
java -classpath "..\lwjgl-2.7.1\jar\lwjgl.jar" Game
, it gives me an error:
Error: Could not find or load main class Game
What have I done wrong!? 🙁
I am certain that there are no syntactical errors and class labeling anomalies.
EDIT: I’ve also tried running the program using this command, but still nothing. T.T
java -cp "..\lwjgl-2.7.1\jar\lwjgl.jar" -Djava.library.path="..\lwjgl-2.7.1\native\windows" Game
Here is the answer, after endless hours of sitting on my toilet…
Note the semi-colon after the -cp. The SEMI-COLON. That was all that I was lacking. A FRIGGIN’ SEMI-COLON.
I hope nobody commits the mistake I did.