Lode Runner remake

Hi everyone,

My first try at some java game programming. Only 55 levels yet, more coming. Press F1 for Help.

Website
Webstart
Linux 32
Linux 64
Windows 32
Windows 64
Solaris 32
Solaris 64
Mac OSX
Applet

http://java-expert.nl/games/test/splash.jpg

http://java-expert.nl/games/test/lr9.jpg

Vista64, JDK7 32bit:

java.lang.NoSuchMethodError: checkAndLoadMain
Error: A JNI error has occurred, please check your installation and try again
Exception in thread “main”

(Didn’t run)

Cas :slight_smile:

Thanks for testing!

You probably need the 64 bits native lwjgl libraries.
Download the latest lwjgl (lwjgl.org) and copy the native/windows/*64.dll to LodeRunner/native/

I’ll put the native libs on my website too, hopefully lwjgl releases for Android and iOS too, that would be cool.

why not using the fantasitc AppletLoader ? it works really well .

Why don’t you just include the 64 bit natives?
Also, princec is the one who started LWJGL :wink:

And for Android and iOS, there’s libGDX :smiley:

Win7 64-bit.
java.lang.UnsatisfiedLinkError: C:\Users\Mads Horndrup\Downloads\loderunner\LodeRunner\native\lwjgl.dll: Can’t load IA 32-bit .dll on a AMD 64-bit platform
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(Unknown Source)
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.loadLibrary0(Unknown Source)
at java.lang.System.loadLibrary(Unknown Source)
at org.lwjgl.Sys$1.run(Sys.java:73)
at java.security.AccessController.doPrivileged(Native Method)
at org.lwjgl.Sys.doLoadLibrary(Sys.java:66)
at org.lwjgl.Sys.loadLibrary(Sys.java:82)
at org.lwjgl.Sys.(Sys.java:99)
at Game.(Game.java:70)
Could not find the main class: Game. Program will exit.
Exception in thread “main”

Did not run.

Filesize :slight_smile: Would be around 6 MB. The actual java classes are only 92 KB, feels wrong to have such a large file for such a small game.
I’ll create downloads for all different platforms, like puppy does.

Does it then only run in a browser? Does it reload the natives each time?
What about sound? Does that play in a browser?

It’s called an Applet for a reason.
And of course sound is played :stuck_out_tongue:

I’ll give it a go. For now I’ve just created a lot of links :slight_smile:

Linux 32
Linux 64
Windows 32
Windows 64
Solaris 32
Solaris 64
Mac OSX

Hm get the same problem with both 32/64 bit zips. My machine may not be as sane as it should be though.

Cas :slight_smile:

Hmm, something can’t find the LodeRunner ‘main’ maybe?

I used a copy of the spaceinvaders tutorial by Kevin Glass ( public static void main(String argv[]) ).
I’ve now changed it to ‘public static void main(String[] args)’.

Could you try it again?

the reason why it fails for princec above is because you’ve split the 32bit and 64bit natives, LWJGL tries to load the 32bit natives first, if that fails, it then loads the 64bit natives. Since it doesn’t find the 32bit natives at all on windows64 it assumes that all natives are missing and fails.

What would be a better idea is to bundle 32 and 64 bit natives together and just have a bundle for each platform (windows, linux, mac and solaris). Its such a small overhead that it hardly matters on today’s computers and internet speeds.

Ah, that makes sense :slight_smile: I’ll fix my downloads. Maybe LWJGL should try for the 64bit natives at least ???

Yeh, LWJGL shouldn’t really require the 64bit natives and 32bit natives to function on 64bit systems. However there is a patch on the LWJGL forums that could potentially change this in future releases.

I’m trying to make it work, but all I end up with is a blank screen.

Lode Runner Retro applet

Is there any way to debug what is happening?

Yes, enable the Java Console from the Java Control Panel (this will then show while the applet runs in the browser).

The problem however seems to be with your main Game class’s initialising method, just make sure its in the form

public Game() {
....
}

and not something like public Game(String blah, int blah) {} this is because a newInstance() of your main class is needed.

Well that helped a bit :slight_smile:

Now I get a whole lot of stacktrace, the only thing I can make out is:

at Game.<clinit>(Game.java:70)

which is private static long timerTicksPerSecond = Sys.getTimerResolution();

The above uploaded applet still shows the old error, so I guess its not updated yet, can you please paste more of the java console output of the error or update the above uploaded applet.

thx

Uploaded the new one. Thanks for helping.