Data Packs Simple

Minecraft RNG with Custom Range!

  • 2.2k views 0 today
  • save_alt 146 downloads
Compatibility
Minecraft 1.17
Changes include
  • Functions
  • Loot Tables
  • Predicates
Added CreditFuriã
  • 4
  • 3
PBalint817
Lvl 32Artisan System
7
A datapack that implements a customizable random number generator for datapack development.
This datapack adds 2 simple functions.

The simpler one is "anyrandom".
This function simply returns a random number within the integer limit.


The second one is "limitrandom"
Here, you have to first set the scores of "brng.system".
The scores are named "randomnummin" and "randomnummax" respectively.
I think it should be obvious what you have to set them to.
After you set them to whatever you want, you just run the command and let the magic happen.


You can append "entity/" to the function names to run a different version of them.
This version will use the scores of the executing entity, instead of a system score.



New: You can now append "loot/" and "loot/entity/" respectively to use a newer version of the generator. Same functionality, except faster, just in case you ever needed to generate 500 random numbers per tick.

Credit to Furiã for the idea behind this feature.

5 Update Logs

Update #5 : by PBalint817 11/02/2021 3:30:50 pmNovember 2, 2021 @ 7:30 pm UTC

Added functions based on top of Furiã's idea.
LOAD MORE LOGS

More like this

  Have something to say?

Welcome