Bug - Not A Bug I can't open any .jar files after r25707 [Java 8 no longer works with Mafia]

sadoatcakes

New member
Mod note from heeheehee: if you're reading this because you're having this same problem, you most likely need to download a newer version of Java. Keep reading for suggestions.

^ What is says on the box. When I try to open both 25712 and 25718 after downloading, I get two pop-up boxes in succession from the Java Virtual Machine Launcher:

Error: A JNI error has occurred, please check your installation and try again.

Followed by:

A Java Exception has occurred

Previous iterations of mafia run without issue; I'm currently adventuring with r25707. Whatever's changed, I don't think it's on my end.
 
Last edited by a moderator:

oztrich

Member
I don't have much experience with Java other than specifically installing it to run Mafia - apologies in advance for asking silly questions here!

So, when it says that Java 9 is required, with Java 17 recommended my only Java install is the latest version of the JVM from from java.com, which appears to be this:

"Recommended Version 8 Update 301
Release date July 20, 2021"

That seems to be a long way out of date given the naming convention, but it's the version that is automatically suggested, and when I run the update tool locally it suggests I'm right up to date. What obvious thing am I missing here?

Edit: and I'm also getting the errors reported in OP.
 
You need to install the JDK not the JRE to get Java 9. The best place to install from is Adoptium and not from Oracle so you can get Java 17
 

fronobulax

Developer
Staff member
Oracle is not making life especially easier for end users. Try getting an update from https://adoptium.net/ which makes it easier to find what you need, even though it is also available from Oracle if you look hard enough.
 

oztrich

Member
Oracle is not making life especially easier for end users. Try getting an update from https://adoptium.net/ which makes it easier to find what you need, even though it is also available from Oracle if you look hard enough.

Yeah, I use Java for nothing else so just relied on java.com previously. When I looked into other versions it wasn't particularly obvious what I needed to do (or why). The link for adoptium was what I needed though, should have read the other thread properly first. Thanks!
 

heeheehee

Developer
Staff member
I've stickied this thread so anyone coming to post a new bug report about not being able to open Mafia sees it right away. Maybe.
 
Top