How can I get a JME game working in a browser, like the .io games?

I think you should give GWT aan try.

It looks like it’s a mature project.

This is the link:
http://www.gwtproject.org/?csw=1

1 Like

I recently found about http://www.jpro.io/
It may be possible through JME-JFX , idk :rolling_eyes:

Well… Mature is a weird term for gwt. It’s been very used for web apps like 5 or 6 years ago but now it’s kind of a dying project…
It was made by Google but they handed the project to the community when they started to focus on angularjs… Since then the cool kids lost interest… But still a pretty solid technology IMO.

Have spent hours on webstart/applets but at the end of the day they all need to be signed, and I can’t do that.

Evidently, GWT does not seem to be portable to from jMonkeyEngine, so it’s pretty much useless to me. :confused:

Plus, these are a dead-end as they both require Java enabled on the browser which not many people do anymore.

Otherwise, self-signing webstart apps is not hard just for testing.

Only for testing. JVM nowadays require trusted signing to run without adding website into exception list. And it is not for free afaik.
It is easier to use HTML5 + JavaScript… There are some open-source libraries. And it is fast and simple

Java web view killer’s face

1 Like

Yea but it is not JME. :frowning:

How do I self-sign them? And, how can I get them signed by other people (even if it costs)?

https://i.gyazo.com/0351257481fd93a73f557224abdb2149.png Go to project properties and try this (I don’t tried it with JME, but with JavaFX it worked. I think there is no difference).

Signing Applets Using RSA Signed Certificates It says "RSA certificates may be purchased from a Certificate Authority
(CA) that supports RSA, such as VeriSign and Thawte. " . But I have never tried by myself.

And a big part of that is that both chrome and edge (now standard for new windows installations) do not support Java in the browser at all.

The skinny is that applets and webstart are the worst parts of java. They caused so much security issues, that they should be disabled. I was surprised that they latest as long as the did.

These days most browsers support is far more consistent form of js+otherstuff all now under the html5 banner. For browser games, its the way to go. Right tool for the job. jME is great but not for browser games. There are some good game libs /“engines” for js as well. Well at least the last time i looked around.

Oh and many of my unity friends have found out how poorly doing anything but direct html5/js works for browser. Basically unity games can cross build, but in practice it doesn’t work that well.

[quote=“delt0r, post:20, topic:37213, full:true”]They caused so much security issues, that they should be disabled. I was surprised that they latest as long as the did.

[/quote]

How do they pose “security issues”? They run in a sandbox. So, no security problems at all.

You may want to just google it. A sand box can have bugs too. Hence no such thing as “no security problems”.

Yes but no more security problems than if you just downloaded it. Hence it is not “insecure”.

But I’m more raging at Oracle’s stupidity than anything else. I guess it’s just not possible with JME. :frowning:

This is probably relevant to this thread as well:

https://hub.jmonkeyengine.org/t/porting-to-browser/36343/15?u=jupake

1 Like

When people load up a URL, they hope that it doesn’t have a hidden section of the page that will take over their machine.

When they download a stand-alone game from some strange place, they should probably expect that there is a possibility that it will take over their machine.

This is why those of us who care about Java deployment were always quick to point out that this is only a Java-in-the-browser problem and not a Java problem in general. There is no presumption of a sandbox when running stand-alone therefore the sandbox cannot be broken. The web expectations are totally different.

It’s not that simple tbh. They are far from stupid. Java 8 applets are VERY secure, to the point that it’s becaume a massive pain in the A… to have them to work. IMO Oracle did this just to stop the conversations about java being insecure in a web browser while completely dissuading developers to use applets. And now in java 9 they are gone… And IMO that’s for the best.
That looks like a very clever phase out to me.

EDIT: Also note that applets not working in a browser is not just an oracle thing. Google and Mozzilla dropped the NPAPI, for their browsers. That was the basis to have applets, activex, flash to work in a browser.

Just an idea to interrupt the discussion:
You could also handle the game server-side using PHP or something and interpret Java from there. I’m sure it’s possible.

…but on the server, running Java is no problem. Why would a Java developer want to subject themselves to PHP coding? (Personally, I’d rather pull my own teeth out with broken fingers.)

Because you can get a free host for php. Haven’t found any for java yet.

Handling some traffic is impossible anyway with a free host,you need a powerful server if you want to manage a moderate amount of players.