How should I update my gradle for the jcenter change?

I usually run my game with gradle run offline but today I tried to be “online” to check the latest alpha build and…

Could not resolve all files for configuration ':compileClasspath'.
> Could not resolve org.jmonkeyengine:jme3-core:[3.1,).
  Required by:
      project :
      project : > com.simsilica:lemur-props:1.0.1
      project : > com.pesegato:GoldMonkey:0.4.2-SNAPSHOT
      project : > com.pesegato:GibbonDice:0.1.0-SNAPSHOT
      project : > com.pesegato:BigBanana:0.1.0-SNAPSHOT
      project : > com.pesegato:MonkeySheet:0.6.0-SNAPSHOT
   > Failed to list versions for org.jmonkeyengine:jme3-core.
      > Unable to load Maven meta-data from https://jcenter.bintray.com/org/jmonkeyengine/jme3-core/maven-metadata.xml.
         > Could not HEAD 'https://jcenter.bintray.com/org/jmonkeyengine/jme3-core/maven-metadata.xml'. Received status code 502 from server: Bad Gateway

My build.gradle:

repositories {
    mavenLocal()
    jcenter()
    maven { url "https://jitpack.io" }
    maven { url "https://dl.bintray.com/riccardo/effekseer" }
}

dependencies {

    compile "org.jmonkeyengine:jme3-core:$jmeVersion"
    compile "org.jmonkeyengine:jme3-desktop:$jmeVersion"
    compile "org.jmonkeyengine:jme3-lwjgl:$jmeVersion"
...
}

What should I change to:

  • try the latest alpha
  • use 3.3.2 (or whatever is the latest 3.3 stable)

Thanks!

1 Like

It’s nice to know I wasn’t the only person impacted by last night’s outage. I regard it as a preview of what’s going to break when JCenter goes down in May 2022.

Switching versions of the Engine won’t help this issue. We need to start removing all our dependencies on JCenter. See issue 1468.

2 Likes

It wasn’t last night. It is RIGHT NOW. So it looks like I’ve chosen the perfect timing to test. How lucky of me!

1 Like

Add mavenCentral() to your repositories section.

Edit: I mean, it doesn’t fix that “jars not yet on maven central” long run issue but given that jcenter is going away, having mavenCentral() in that section should be standard now… even if you also include jcenter() for the time being.

2 Likes

Well… now it works. I’ve tried the 3.4 alpha and noticed something changed:

  • text aliased
  • gamma correction enabled

Now I want to go back, so I changed

jmeVersion = "[3.1,)"

to

jmeVersion = "3.3.2"

But now I get:

Could not resolve all files for configuration ':compileClasspath'.
> Could not find org.jmonkeyengine:jme3-core:3.3.2.
  Searched in the following locations:
    - file:/C:/Users/Pesegato/.m2/repository/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.pom
    - file:/C:/Users/Pesegato/.m2/repository/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.jar
    - https://repo.maven.apache.org/maven2/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.pom
    - https://repo.maven.apache.org/maven2/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.jar
    - https://jcenter.bintray.com/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.pom
    - https://jcenter.bintray.com/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.jar
    - https://jitpack.io/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.pom
    - https://jitpack.io/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.jar
    - https://dl.bintray.com/riccardo/effekseer/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.pom
    - https://dl.bintray.com/riccardo/effekseer/org/jmonkeyengine/jme3-core/3.3.2/jme3-core-3.3.2.jar
  Required by:
      project :
1 Like

Maybe add a -stable to the end?

2 Likes

It looks like the gamma correction makes the whole display aliased (on both 3.3.2 and 3.4-alpha). Is it normal? (Intel integrated GPU)

1 Like

One thing I noticed is that my GUIs tend to look different with gamma enabled. At first I thought it was color conversion related but I did various tests that seemed to rule that out.

I’ve started to believe it’s alpha related… which could also affect the strength of aliasing of BitmapText (which will always have some aliasing no matter what).

1 Like