Jump to content
ParaToxic

Java lib for Leadwerks 2

Recommended Posts

Hey ya, I wan't to use java for a schoolproject with leadwerks and looked at the tutorial for that kind of stuff.

Well I have some problems to get the Graphics command work in my sample.

I just use the same code as in the tutorial but use System.loadLibrary("engine"); to load the engine because with Native.register I get the following error: Unable to load library 'engine': Das angegebene Modul wurde nicht gefunden.

 

Then I have a main function like that;

 

[size=4]public static void main(String[] args)[/size]
   {
       int a = LE.Initialize();
       System.out.println("result:" + a);
       LE.Graphics(600, 800, 32, 0, 4);
   }

 

But with the Graphics function I get the Error:

 

Exception in thread "main" java.lang.UnsatisfiedLinkError: Leadwerks.LE.Graphics(IIIII)I
at Leadwerks.LE.Graphics(Native Method)
at lo.main.main(main.java:17)
Java Result: 1

 

Hmmm, can somebody help me with that, it's very important for me get it working :)

Thanks

Share this post


Link to post

ok no probs glad you got it working.

Just tried it myself, seems there is something up with setting the working directory in net beans. I had to build the jar and drop it in the LW directory to run it.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...