Back to mods
RandomJS project artwork

Modrinth · Minecraft mod

RandomJS

Added a new category of block presets to KubeJS, allowing players to set custom survival rules for created blocks.

Choose a version Pick your version below, then grab the matching file.

This page is having a moment, so a few details may be a little behind.

Quick answer

Which RandomJS release should I use?

Updated 2 years ago
Latest stable file 1.0.0-A
Game version 1.20.1, 1.20.2, 1.20.3
Loader Forge

RandomJS 1.0.0-A targets 1.20.1, 1.20.2, 1.20.3 with Forge. Installation on the client is optional. Installation on the dedicated server is optional. 1 required mod needs checking.

Where it goes

Is RandomJS required on the client, server, or both?

Installation on the client is optional. Installation on the dedicated server is optional.

Client Optional
Dedicated server Optional
Loader for this release Forge
Required install it here Optional supported, not mandatory Not supported do not install here Source doesn’t say do not assume

The source marks this as usable on both the client and server.

What else does RandomJS 1.0.0-A need?

1.0.0-A. Change the file and its required mods may change too.

1 required mod needs checking

Install project umyGl7zF first. 1 required mod still needs checking for this exact setup.

Project umyGl7zF Needed by RandomJS 1.0.0-A
required
Still checking

We only count dependency files that match this setup. A file for another loader does not fill the gap.

Before you install it

Add RandomJS without breaking your instance.

Built for RandomJS 1.0.0-A. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use 1.0.0-A. It targets 1.20.1, 1.20.2, 1.20.3 with Forge; another release may have different loader, side or dependency requirements.

  2. 02

    Bring the mods it needs

    Install project umyGl7zF first. 1 required mod still needs checking for this exact setup.

  3. 03

    Put it on the correct side

    Installation on the client is optional. Installation on the dedicated server is optional.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside 1.0.0-A. It opens that exact file at the source.

About this project

What does RandomJS add?

Added a new category of block presets to KubeJS, allowing players to set custom survival rules for created blocks. (More features coming soon)

Currently added kinds:

  • Determination of the bottom block
  • Determination of whether the immediate neighboring faces are complete or not

The full list of methods is below:

  • customSurviveRule( Json ) (use json to customize the survival rule)
  • surviveType( String ) (select a preset rule for surviving blocks, see below for details)
  • catchAllDirection( Boolean ) (enable full face all match mode)

Optional json statement:

  • "setFaceSturdy" : String[]
    • (set a list of directions, make the blocks detect if the neighboring faces of the directions in the list are all faces, if any direction meets the condition, all matches need to enable all-face-match mode)
    • (optional values: "up" "down" "east" "west" "south" "north")
  • "setBelowBlock" : String[]
    • (set a list of blocks so that blocks must be placed on the blocks in the list)
    • (optional: full block id, e.g. "minecraft:stone", no way to match blockstate yet because it's not done yet)

Future plans:

  • More survival rules with preset types
  • Custom HUD
  • Custom GUI

Usage examples:

StartupEvents.registry ("block", e=> {
    e.create ("block_name", "super_block")
        .surviveType ("custom")
        .customSurviveRule (
            {
                "setFaceSturdy" : ["up", "down"],
                "setBelowBlock" : ["minecraft:stone", "minecraft:oak_log", "minecraft:campfire"]
            })
         .catchAllDirection (false)
})

Project description from Modrinth.

Pick your setup

RandomJS by Minecraft version and loader

Choose the version and loader you play, then open the matching release.

4 available setups

Check the dependencies, then try the file in a copied instance before changing a world you care about.

Recent files

RandomJS versions and loaders

1 of 1 releases match

Looking for an older file? The official Modrinth project page is in Resources.