Jump to content

My java source file uses a java script plugin system. Not sure what I'm doing. help?

Mandem

Not entirely sure if this is the right area to post this, but I might as well at this point. I've been working on this "bug" fix for awhile now. I'm programming a game based on another game. This is the problem I have.

 

The scripts I use are handled by ScriptManager.java, here is that:

 

http://paste.ee/p/X2SG8

 

 

These were the imports I used before I've started editing the file. (These are imported in the .js file)

importPackage(org.resolution.game.world)importPackage(org.resolution.game.world.entity.player)importPackage(org.resolution.game.content.skills.agility)importPackage(org.resolution.game.world.entity.masks)importPackage(org.resolution.game.world.pathfinders)importPackage(java.util)

These did cause some errors of course. If you need them I can supply these too.

 

 

These are my top fields (imports) after edits.

Load("nashborn:mozilla_compat.js");importPackage(Packages.org.resolution.game.world)importPackage(Packages.org.resolution.game.world.entity.player)importPackage(Packages.org.resolution.game.content.skills.agility)importPackage(Packages.org.resolution.game.world.entity.masks)importPackage(Packages.org.resolution.game.world.pathfinders)importPackage(java.util)

My eclipse error:

java.nio.file.InvalidPathException: Illegal char <:> at index 47: C:/Users/Administrator/Desktop/reso530/nashborn:mozilla_compat.js	at sun.nio.fs.WindowsPathParser.normalize(Unknown Source)	at sun.nio.fs.WindowsPathParser.parse(Unknown Source)	at sun.nio.fs.WindowsPathParser.parse(Unknown Source)	at sun.nio.fs.WindowsPath.parse(Unknown Source)	at sun.nio.fs.WindowsUriSupport.fromUri(Unknown Source)	at sun.nio.fs.WindowsFileSystemProvider.getPath(Unknown Source)	at java.nio.file.Paths.get(Unknown Source)	at jdk.nashorn.internal.runtime.Source.baseURL(Source.java:755)	at jdk.nashorn.internal.runtime.Source.sourceFor(Source.java:405)	at jdk.nashorn.internal.runtime.Source.sourceFor(Source.java:392)	at jdk.nashorn.internal.runtime.Context.load(Context.java:651)	at jdk.nashorn.internal.objects.Global.load(Global.java:877)	at jdk.nashorn.internal.scripts.Script$\^eval\_.runScript(<eval>:1)	at jdk.nashorn.internal.runtime.ScriptFunctionData.invoke(ScriptFunctionData.java:535)	at jdk.nashorn.internal.runtime.ScriptFunction.invoke(ScriptFunction.java:209)	at jdk.nashorn.internal.runtime.ScriptRuntime.apply(ScriptRuntime.java:378)	at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:568)	at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:525)	at jdk.nashorn.api.scripting.NashornScriptEngine.evalImpl(NashornScriptEngine.java:521)	at jdk.nashorn.api.scripting.NashornScriptEngine.eval(NashornScriptEngine.java:187)	at javax.script.AbstractScriptEngine.eval(Unknown Source)	at org.resolution.game.ScriptManager.loadScripts(ScriptManager.java:108)	at org.resolution.game.RS2Server.start(RS2Server.java:70)	at org.resolution.Server.main(Server.java:48)

Again I highly doubt this is the right place to post this, but I've been trying for so long I figured why not. I'm somewhat knowledgeable in java but not so much in Java Script.

 

Thanks in advance.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×