Jump to content

Why ForgeGradle?


Shadzari

Recommended Posts

I'm sorry if I seem a downer - or if I am going off-topic - but I'm failing to understand something, and if someone can offer me some enlightenment, I'd really appreciate it.

 

Why has Gradle/ForgeGradle been implemented?

 

I haven't been messing with mods or Java long - only for about seven months - but I've been coding for MC since day one of that, have gone through setting up Forge for every significant build since then, and I honestly don't see what ForgeGradle is offering in the bigger picture.  Taken at face value, the installation of the Forge src is complicated now and totally non-intuitive, and updating src builds within the installed framework doesn't seem to be much more friendly.  The older style of Forge src installation, including mod src backup and migration, could be easily automated with a custom .bat and a few mouse clicks, but this is just... I don't know.

 

Taking Gradle as a project automation tool, I can imagine that it might be useful if someone has coded a huge mod that for some reason Eclipse can't handle - but I can't visualize the likelihood or mechanics of that because Eclipse, to me, is just a coding environment with highlighting and F3 go-to-code backtracking, and all the recompiling and deobfuscating being handled through two nifty little .bats on my desktop.  (If I didn't need the go-to-code in Eclipse, I'd probably still be using CrimsonEdit, to be honest.)

 

I'll be honest - I like things simple.  I need things simple, actually, due to a lovely heaping dose of adhd.  (No, I'm not trying to invoke sympathy, I'm just sayin' that it does have an effect, and that I have had to find alternative ways to be efficient with this stuff.)  Anyway, I'm starting to derail myself, so... point is, I don't understand how Gradle/ForgeGradle is making enough of a positive change to overcome the additional pain that installation at this point looks like.  If someone who's in the know can enlighten me, I'd love ya.  If there's some benefit or future need I'm not seeing, I'd love to either be able to utilize that benefit or be prepared for that change.

 

Thanks :)

Shad

Link to comment
Share on other sites

One reason why ForgeGradle has been added is because it is simpler and easier to use!

another is for people with OCD like me with ForgeGradle you don't have loads of .bat, .sh or .py files you just have two files!

I'm sure there are a lot more reasons as to why it should be used but to be honest the old way to build and decompile was better because it never used to take up 1GB+ of memory for all of the mods I have!

Link to comment
Share on other sites

Forge installation:

While it might be a bit more complex than before, take in mind that you won't need to do it ever again.

ForgeGradle will update to newer version as soon as you ask. No need to download a new forcesrc package extract run bat files then rebuild the project. It is done for you automatically. And you can downdate as easily.

Building automation:

You might already know, but with the Gradle plugin in Eclipse, you can run Gradle tasks within Eclipse. No longer need to run your own automated bat files to build.

 

Granted, if you had already automated everything for modding, I don't think Gradle is giving you much. But it isn't much of an hassle to convert to, as you can probably include your scripts into Gradle.

All in all, it is a great progress for new modders, whose work is going to be automated without them thinking much about it.

For old modders, you can test your mods with multiple Minecraft+Forge versions really fast.

Link to comment
Share on other sites

New != Complex

From the users point of view, The old system, and the new System is EXACTLY the same level of complexity.

The ONLY thing that could possibly cause it to be more 'complex' is that we do not ship all those dozens of .bat/.sh files.

That decision was made because I got sick and tired of people coming along and watching 1 line helper scripts or every fucking thing and no two operating systems working the same way -.- So it's up to the end modder to figure it out. {Seriously.. if you can't run a simple command, or make the script yourself.. you shouldn't be modding}

 

Now, look at the things that Gradle provides:

Cleaner code

Cleaner work spaces

Separation of Mod code from Minecraft Code

Dependency Management

Automated deployment

OS independence

 

And the list goes on.

 

Basically, I give 0 shits about anyone who says the new system is 'More Complex'. that just makes you look ignorant/scared of change.

 

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Link to comment
Share on other sites

I don't like the Gradle 'update' and imo it is a major mistake.

[*]Gradle adds nothing that Maven + Ant couldn't have done as well.

[*]Gradle is not supported by the most common IDEs and force the developer to use unsupported/buggy plugins.

[*]With no build-in support, changing settings/properties becomes a lot more difficult.

@LexManos: I don't really get the supporting arguments.

 

- Cleaner code/workspace

What does this have to do with the build system? A tidy environment is a question of project setup.

 

- Separation of mod code

I had this since the beginning of Forge: just add a second source directory and you are done.

 

- Dependendy management

Can be done with Maven and various other supported features of most IDEs

 

- Automated deployment

Whats the big difference between "ant dist" and "gradle dist" ?

 

- OS Independence

Which part of Java/Ant was OS dependent before?

My Mods

 

New Dawn - A completely new terrain engine for Minecraft

TwoTility - Blocks and Items for a better Minecraft

TwoGraves - Keeps your items safe on death

Link to comment
Share on other sites

That decision was made because I got sick and tired of people coming along and watching 1 line helper scripts or every fucking thing and no two operating systems working the same way -.-

 

Thank you.  That I can totally understand and I can totally get on that boat.

 

Now, look at the things that Gradle provides:

Cleaner code

Cleaner work spaces

Separation of Mod code from Minecraft Code

Dependency Management

Automated deployment

OS independence

 

This is the kind of answer that I was hoping for.  I'd like to see this list elaborated on somewhere for those who have the same concern/question but I realize that 1) you're a busy guy and 2) it isn't really your job anyhow, is it? :)

 

Anyway, thank you for taking the time to answer, and I apologize for any arguments started by the thread. 

 

Shad

Link to comment
Share on other sites

Sure. But gradle is an alternative to them. It's a personal opinion, like your favourite IDE.

I do not have opinions about tools, I use the one that fits best. And if I have to choose between two tools that can both do the same, but the one is fully supported by all major IDEs, I'd choose the supported one, because...

 

OMG, I have to edit a text file? Wtf.

It is not about having to edit a text file, it is about what to write into it. With an ant properties file (if done right), there are a few selections to make that most people who are somewhat familiar with programming can understand. With Gradle you cannot simply edit a text file, you need to write code, which means you need to know the programming language, which means you need to look through various Google resources. And if something doesn't work (as with the current Forge setup), you are basically screwed until someone with a lot more knowledge comes around and does the work for you.

 

That's the difference between editing a property file and editing the Ant build-script. There is a good reason why property files have been invented.

 

And Forge doesn't use any Ant by default.

What's the reason Forge doesn't want to use Ant?

My Mods

 

New Dawn - A completely new terrain engine for Minecraft

TwoTility - Blocks and Items for a better Minecraft

TwoGraves - Keeps your items safe on death

Link to comment
Share on other sites

With an ant properties file (if done right), there are a few selections to make that most people who are somewhat familiar with programming can understand. With Gradle you cannot simply edit a text file, you need to write code, which means you need to know the programming language, which means you need to look through various Google resources.

Sorry, but writing in a programming language is one of the best aspect of Gradle.

It is a lot easier to understand for a programmer like me.

And yes, having to know Java has been a prerequisite to mod with Forge since long ago. Don't act like you are surprised that it is used somewhere.

 

That's the difference between editing a property file and editing the Ant build-script. There is a good reason why property files have been invented.

 

And Forge doesn't use any Ant by default.

What's the reason Forge doesn't want to use Ant?

You can use Ant if you want. If you are convinced it is better, then you don't need any help to make it work.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I have been currently having this issue where if I join my server, I get one of these 2 errors. I have tried fixing this issue by looking at the output log in both Server and Client side, from what I have seen I was not able to find anything I can understand that would have helped me. These two errors pop up randomly with no pattern when attempting to join the server when it says Encrypting... I have tried removing all mods from the Client and Server side, which did nothing and still showed the same errors (I don't remember which error showed or even if it showed both), so from what I tried to do, I do not think this is a mod Issue but rather a Forge Issue. How do I fix this? Here are the errors and all the information: Internal Exception: java.lang.NoClassDefFoundError: com/google/common/util/concurrent/TrustedListenableFutureTask Debug.log: https://www.mediafire.com/file/hbtycb1tamqt1qr/debug2.log/file (PS: Debug.log file cannot be uploaded to Pastebin due to it crashing because of the Large Amount of Spam OpenGL logs) Internal Exception: Internal Exception: java.lang.NoClassDefFoundError: com/google/common/collect/LinkedHashMultiMap$ValueSet Debug.log: https://www.mediafire.com/file/o1d48z0bjfyff1e/debug.log/file (PS: Debug.log file cannot be uploaded to Pastebin due to it crashing because of the Large Amount of Spam OpenGL logs) Client Mods: Server Mods:
    • the removing of the Material class has mess up bad mi code now have to many broken things after updating mi code to 1.20.4 this are mi pipes they conect each others but to have it right i have to made a custome BlockItem  the thing its that i need to check the block im looking at  if its some something like grass or wheat i need to ignore and replace whit mi pipe block but if its something like leaves then it must respect it and set the pipe above or at the side  in x < 1.9just check the material the target block is made of     in 1.20 cannot be done like this soo i was trying to make a list of solid blocks but is much work and also it don't have in account blocks from other mods              
    • tysm, ur a life saver,, its weird immersive portals became the issue because I play-tested the mod pack once and everything ran, it only started crashing when I tried playing it a second time.
    • could it be by making a custome block whit no hitbox  or by a falling block entity  // ########## ########## ########## public FallingBlockEntity create_FallingBlock(BlockPos cursor){ this.fallingblock = FallingBlockEntity.fall(warudo, cursor, this.getBlockState() ); this.fallingblock.setNoGravity(true); warudo.addFreshEntity(this.fallingblock); return this.fallingblock; }
    • in 1.19 i notice that an have to fix by hand  in 1.20.4 this is not a problem anymore but 1.20 has its own set of new problems   // ########## ########## ########## ########## // lista de entidades atravezadas por la linea entre vi y vh|vo public ArrayList<LivingEntity> findHitEntitys() { return findHitEntitys(0.0D); } public ArrayList<LivingEntity> findHitEntitys(double grow) { double hgrow = (grow/2) * -1; Vec3 vi = this.subject.getEyePosition(); Vec3 vo = (this.vh != null) ? this.vh : this.vo; /* Double xn = Math.min(vi.x, vo.x); Double xm = Math.max(vi.x, vo.x); Double yn = Math.min(vi.y, vo.y); Double ym = Math.max(vi.y, vo.y); Double zn = Math.min(vi.z, vo.z); Double zm = Math.max(vi.z, vo.z); Vec3 vdi = new Vec3(xn,yn,zn); Vec3 vdo = new Vec3(xm,ym,zm); */ // particle(warudo, vo); AABB bb = new AABB(vi, vo).inflate(2.0D); //System.out.println( (bb.maxX - bb.minX) + ", " + (bb.maxY - bb.minY) + ", " + (bb.maxZ - bb.minZ) ); ArrayList<LivingEntity> list = new ArrayList<LivingEntity>(); Predicate<? super Entity> cosa = target -> (target instanceof LivingEntity);// for (Entity target_entity : this.warudo.getEntities(this.subject, bb, cosa)) { //System.out.println(entity1.getBoundingBox()); // is the entity in the line //if (entity1 instanceof LivingEntity) { AABB aabb = target_entity.getBoundingBox().inflate(grow); //System.out.println( "x " + (aabb.maxX - entity1.getX()) + ", " + ( entity1.getX() - aabb.minX ) ); //System.out.println( "y " + (aabb.maxY - entity1.getY()) + ", " + ( entity1.getY() - aabb.minY ) ); //System.out.println( "z " + (aabb.maxZ - entity1.getZ()) + ", " + ( entity1.getZ() - aabb.minZ ) ); Optional<Vec3> optional = aabb.clip(vi, vo); //System.out.println(aabb); if (optional.isPresent()) { list.add((LivingEntity) target_entity); } } } list.sort((o1, o2) -> (Double.compare(o1.position().distanceTo(vi), o2.position().distanceTo(vi)))); return list; }   1.20.4 has not this problem anymore
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.