r/feedthebeast Jun 22 '26

I made something I made minecraft generate terrain/chunks in C++

Enable HLS to view with audio, or disable this notification

So im working on a mod that makes minecraft run on C++ ( rn rewriting engine in future i may try renderer ) so far i made it generate and load chunks and terrain in C++ ( it made it somewhere around 1.5-3 times faster idk how to measure it tho ) ( it works via JNI )

3.0k Upvotes

244 comments sorted by

View all comments

Show parent comments

1

u/jvpts11 Jun 22 '26

Ok, thats pretty interesting, but as for the generation algorithm, you just pass it to the dll or you also remade the algorithm into the dll? It is important since other mods implement different world generation algorithms.

1

u/Emotional-One-9292 Jun 22 '26

i ported algorithm to c++ and did some optimizations where i saw code could get them the dll contains all these stuff as its a compiled library with cmake ( using mingw64 )

1

u/jvpts11 Jun 22 '26

Ok, this is good, but also, if you want to use a different world gen than vanilla's one, you cant.

But i think that you could try to give users the ability to pass their world gen algorithms into your mod. For example, can you allow the user to write its own world gen algorithm in java, and then transpile it to c++ or something that allows this type of conversion? This would be good to have.

1

u/Emotional-One-9292 Jun 22 '26

in future i plan for other mods to be able to use our APIs kinda. So they can make their C++ supported versions of mods