Skip to content

Instantly share code, notes, and snippets.

@AnOpenSauceDev
Last active November 7, 2023 11:25
Show Gist options
  • Save AnOpenSauceDev/7b83119e92fae98de52b21efa2d8bfe1 to your computer and use it in GitHub Desktop.
Save AnOpenSauceDev/7b83119e92fae98de52b21efa2d8bfe1 to your computer and use it in GitHub Desktop.
Why Faster Random is archived.

Why is Faster Random archived?

If you're reading this, you probably want an explanation on why this mod is no longer being developed. This will be separated into 3 parts.

  1. Why?
  2. What's next?
  3. What can I do with Faster Random now?

Why is the mod archived?

This section turned out to be completely wrong, disregard the older revisions Faster Random's optimized MathHelper was actually over 100x faster than vanilla, but the performance was measured in a way that didn't account for the fact that random calucations are usually called once every now-and-then, so by looking at average framerate (because methane could actually be benchmarked that way due to most of its logic happening every frame), I completely missed the whole point of benchmarking.

update with the news of 1.20.2

And on the topic of the /random command for 1.20.2, it might be faster with FasterRandom IF it was/is multithreaded, but it feels unsatisfying just to multithread a single command, and to not tackle the problem at the root which is a general lack of multithreading (which is starting to be remedied slowly by Mojang). But who knows, mojang has finally started fixing a lot of performance issues with the game recently. Patching a single poorly-done random call really wont shave many milliseconds off a frame, and if it does, that's probably a serious issue with the datapack.

What can I do with Faster Random?

Anything, as long as it follows GPLv3. That means forking it, adapting it into your own performance mods, etc. If you really want to, you can publish your own release to modrinth, just credit the original project and stuff. One condition is that i would prefer if you reached out to me at https://github.com/AnOpenSauceDev/Issue-Tracker before releasing your own fork.

@mateus3c
Copy link

this is so sad, FasterRandom did a big FPS diference on my game.

@AnOpenSauceDev
Copy link
Author

Are you sure? When I tried benchmarking server performance later on, the improvements I got were pretty minor, which i didn't see as worthy of continued development. If you did actually get better performance, I would love to see some benchmarks of that.

@Nicolol1234
Copy link

is there any alternative?

@AnOpenSauceDev
Copy link
Author

is there any alternative?

on the server side, paper does something kind of similar by unifying the random instance for mobs, but that's it. I don't think there are any other server or clientside mods for fabric that do this.

@AnOpenSauceDev
Copy link
Author

this is so sad, FasterRandom did a big FPS diference on my game.

After doing some benchmarks putting Faster Random and Vanilla side-by-side, it turns out it was surprisingly 100x faster, and the way i was benchmarking was done incorrectly. I still don't know i want to keep maintaining this, however.

@Nicolol1234
Copy link

That's a lot

this is so sad, FasterRandom did a big FPS diference on my game.

After doing some benchmarks putting Faster Random and Vanilla side-by-side, it turns out it was surprisingly 100x faster, and the way i was benchmarking was done incorrectly. I still don't know i want to keep maintaining this, however.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment