Applet Permission

Guys I wanna deploy my game as an applet. While running the applet on browser I got nullpointer error and nothing detailed. However I look it up with appletviewer it gives me this error:

[java]java.lang.ExceptionInInitializerError
at main.GameApplet.init(GameApplet.java:56)
at sun.applet.AppletPanel.run(AppletPanel.java:435)
at java.lang.Thread.run(Thread.java:724)
Caused by: java.security.AccessControlException: access denied (“java.util.PropertyPermission” “user.home” “read”)
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:372)
at java.security.AccessController.checkPermission(AccessController.java:559)
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
at java.lang.SecurityManager.checkPropertyAccess(SecurityManager.java:1302)
at java.lang.System.getProperty(System.java:707)
at chessgame.ChessGameController.<clinit>(ChessGameController.java:26)
… 3 more[/java]

Okay it looks like I have to sign my jar which keeps my game’s classes. I have done that before and also signed the dependent jars. The jars I have signed are below:
[java]game.jar(keeps my classes I have written)
jinput.jar
jME3-core.jar
jME3-desktop.jar
jME3-lwjgl.jar
jME3-lwjgl-natives.jar
lwjgl.jar[/java]

They are all signed. And also I have put the line "JmeSystem.setLowPermissions(true); " for just in case :S

One more info. Here is the my applet.html:
[java]<html>
<body>
<applet
archive=“game.jar, jinput.jar, jME3-core.jar, jME3-desktop.jar, jME3-lwjgl.jar, jME3-lwjgl-natives.jar, lwjgl.jar”
codebase="./"
code=“main.GameApplet.class”
width=800
height=600>
</applet>
</body>
</html>[/java]

Please dont say “with the sdk you can deploy it via one click” if you cant stop yourself, instead pls help me understand the protocol on the applet.

Due to the native libraries you need an actual certificate. Use the SDK BasicGame template and the “LWJGL Applet” checkbox in the settings to make a lwjgl signed applet.

1 Like

Well thx. Can you also tell me where I can find the “LWJGL Applet” checkbox? Which settings are you talking about?

@ErayT said: Well thx. Can you also tell me where I can find the “LWJGL Applet” checkbox? Which settings are you talking about?

The project settings, right-click the project.

<cite>@normen said:</cite> Due to the native libraries you need an actual certificate. Use the SDK BasicGame template and the "LWJGL Applet" checkbox in the settings to make a lwjgl signed applet.

I was searching on the internet about the lwjgl applets and found that article :
http://lwjgl.org/wiki/index.php?title=Deploying_with_the_LWJGL_Applet_Loader_1_-_Basics

I have two unclear points about this link.
1-) Can I use that approach to deploy my applet? (I am gonna create an applet holding the game canvas)
2-) You said I need an actual certificate; however, in the article it signs the lwjgl applet in the way I have already done. (http://lwjgl.org/wiki/index.php?title=Signing_Jar_Files)

@ErayT said: I was searching on the internet about the lwjgl applets and found that article : http://lwjgl.org/wiki/index.php?title=Deploying_with_the_LWJGL_Applet_Loader_1_-_Basics

I have two unclear points about this link.
1-) Can I use that approach to deploy my applet? (I am gonna create an applet holding the game canvas)
2-) You said I need an actual certificate; however, in the article it signs the lwjgl applet in the way I have already done. (http://lwjgl.org/wiki/index.php?title=Signing_Jar_Files)

Please ask the lwjgl team, I can only help you with the SDKs lwjgl Applet creation, which works fine.