Coder Social home page Coder Social logo

Upgrading forge and gradle about vsminecraft HOT 1 OPEN

microsoft avatar microsoft commented on May 18, 2024
Upgrading forge and gradle

from vsminecraft.

Comments (1)

brezeeger avatar brezeeger commented on May 18, 2024

OK, I figured it out. It's not completely straightforward - especially to a new mod maker. I'll try to make a step-by-step solution. Throughout this, I did a number of compiles, and closed/reopened visual studio (though closing the solution and reopening probably would've also worked).

Step 1) Back it all up. Just in case.

Step 2) Download the desired forge-version-mdk.zip file. Extract it somewhere safe. When you rebuild, it will probably download this all again, but it may yell at you because of gradle being a different version.

Step 3) Replace the gradlew and gradlew.bat in your solution directory with the gradlew and gradlew.bat from the forge src zip file.

Step 4) In your solution directory, there is the gradle directory leading to the gradle-wrapper.jar and gradle-wrapper.properties. Replace those with the equivalents in the downloaded forge src zip file.

Step 5) In the build.gradle file: change
mavenCentral() to jcenter()

classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
to
classpath 'net.minecraftforge.gradle:ForgeGradle:2.0-SNAPSHOT'

apply plugin: 'forge'
to
apply plugin: 'net.minecraftforge.gradle.forge'

version = "1.8-11.14.1.1357" to version = "1.8-11.14.4.1563"

Step 6) Go to your ProjectName.javaproc file. Look for all instances of 1.8-11.14.1.1357 and replace them with the forge version of your choice. Two JarReference tags, one Content tag, and MinecraftForgeVersion at the top. Note, these can not necessarily be edited in Visual Studio. In particular, the reference leading to GradleStart...

Step 7) Do the same thing as step 6 in the .classpath file. On compile, one of these may generate the other, but I don't know which way it goes.

Step 8) Same thing again, except for classpath.vs.build.xml

Step 9) Same thing again, except the .project file.

I believe steps 6-9 will properly update the 'references' code section in the solution.

Step 9) Copy the forge-version-mdk.zip file, and paste it into project/packages/com.microsoft.minecraftmod.0.5.4.0/tools and then replace the 'mdk' with 'src'

Step 10) In the solution - the .gradle folder. Add the 2.7 folder (or whichever newer version of gradle you are using) to the project, and exclude the 2.0 folder from the project (assuming gradle is updated). This may require an attempted clean/rebuild to create this folder.

Step 11) It may be necessary to copy the eclipse folder from the forge zip and replace the eclipse folder in your solution.

Step 12) Clean solution/project and rebuild.

I believe this is everything I did, and it works on my end. However, I may have missed a step. There was a lot of flailing as I've never worked with Java or gradle before. Basically, it is just a matter of replacing old files with new files, updating the build.gradle file, and catching all references to the old stuff and replacing it with the new. Best of luck!

from vsminecraft.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.