#Infinite generating mine with infinite mine reseting

1 messages · Page 1 of 1 (latest)

nova zenith
#

Im also going to make it so the deeper u go the different layers there will be to unlock and harder to find ores. I'm obsessed with this.

nova zenith
#

just added layer 2 you can see the transition, with different ores spawning at different rates

#

made layer 3 etc etc

#

also anti x-ray^^^

placid hare
#

This is smart

nova zenith
bright nymph
#

would it just regenerate

#

or is it only when player breaks a block

nova zenith
#

player break only

bright nymph
#

rip

nova zenith
#

not rip

bright nymph
#

big rip

nova zenith
#

u cant nuke anyway

bright nymph
#

not that type of nuke

#

i have a custom enchant that just “nukes” a 10x10 circle

#

💀

nova zenith
#

okay?

bright nymph
#

yea would it theoretically work

#

i guess not

nova zenith
#

no

#

no script event allows for breakblock

#

only player break block

bright nymph
bright nymph
#

why not bruh

nova zenith
#

the generation replaces structure voids

#

therefore stopping it from replacing already broken blocks

bright nymph
nova zenith
#

idk if this videos show it i have alot

bright nymph
#

wouldn’t you temporarily store broken block locations in the item used to break it with dynamic properties and then completely get rid of the structure blocks?

#

i would say that’s more efficient

#

i want to recreate this now

nova zenith
#

plus im already using this for a realm idea.

bright nymph
#

oh nice

#

good work btw

#

nostalgia from mining simulator on roblox 😭

nova zenith
#

its based of rarity miner on roblox

#

new game

#

with infinite mining room

#

like mine

bright nymph
#

that’s sick

#

nice work again tho. have you tried with multiple people to see how it handles?

nova zenith
bright nymph
#

damn that’s nice

nova zenith
#

even with it looking like this.

bright nymph
#

WHY IS IT

#

USING COMMANDS

nova zenith
#

im not that good at scripts

bright nymph
#

it’s really bum but better than command

#

lol

nova zenith
#

idek what that is

bright nymph
#

less stress on your game

nova zenith
#

what i do then

bright nymph
#

erm

#

one second

#

i’ll try uh replicate what you have

nova zenith
#

i can just send them all if u want

#

... i gotta do this for every layer 😭

#

so each block placed is a random one from the layer1 function

bright nymph
#

if (block && block.typeId === "minecraft:structure_void") {
const randomBlockType = layerOneBlocks();
block.setPermutation(BlockPermutation.resolve(randomBlockType));

#

that could work

#

that’s simple way

nova zenith
#

heh

bright nymph
#

i guess

#

it’s weird

#

😭

nova zenith
#

heh

#

makes 0 sense what im looking at

bright nymph
#

yea

#

i’ll try recreate what you have with block permutation and then send you it

#

cuz commands is not the way 😭

nova zenith
#

alrighty

bright nymph
bright nymph
thick fulcrum
nova zenith
#

breh

bright nymph
#

LOL

thick fulcrum
nova zenith
#

if yall wanna make one which randomizes every block

#

then sure

#

this is thefunction

bright nymph
#

say less

nova zenith
#

function layer1() {
let random = Math.ceil(Math.random(1) * 200)
if (random >= 1 && random <= 130) return "minecraft:stone"
if (random >= 131 && random <= 170) return "minecraft:coal_ore"
if (random >= 171 && random <= 189) return "minecraft:copper_ore"
if (random >= 190 && random <= 198) return "minecraft:iron_ore"
if (random >= 199 && random <= 200) return "minecraft:coal_block"
}

thick fulcrum
#
world.beforeEvents.playerBreakBlock.subscribe((data) => {
    let { block, player, dimension, itemStack: item } = data;
    let { x, y, z } = block.location;

    if (!item?.typeId.endsWith("pickaxe")) return;

    system.run(() => {
        let positions = [
            { x: x, y: y - 1, z: z },
            { x: x, y: y + 1, z: z },
            { x: x, y: y, z: z + 1 },
            { x: x, y: y, z: z - 1 },
            { x: x - 1, y: y, z: z },
            { x: x + 1, y: y, z: z }
        ];

        let oreDistribution;

        if (y > -54) {
            oreDistribution = [
                { typeId: "minecraft:stone", probability: 0.60 },
                { typeId: "minecraft:iron_ore", probability: 0.15 },
                { typeId: "minecraft:copper_ore", probability: 0.10 },
                { typeId: "minecraft:gold_ore", probability: 0.10 }
            ];
        } else {
            oreDistribution = [
                { typeId: "minecraft:cobbled_deepslate", probability: 0.70 },
                { typeId: "minecraft:deepslate_iron_ore", probability: 0.12 },
                { typeId: "minecraft:deepslate_copper_ore", probability: 0.08 },
                { typeId: "minecraft:deepslate_gold_ore", probability: 0.07 },
                { typeId: "minecraft:deepslate_diamond_ore", probability: 0.03 }
            ];
        }

        positions.forEach(pos => {
            if (dimension.getBlock(pos).typeId === "minecraft:structure_void") {
                let randomValue = Math.random();
                let cumulativeProbability = 0;

                for (let ore of oreDistribution) {
                    cumulativeProbability += ore.probability;
                    if (randomValue < cumulativeProbability) {
                        dimension.setBlockType(pos, ore.typeId);
                        break;
                    }
                }
            }
        });
    });
});
thick fulcrum
#

its simple

nova zenith
#

i dont feel like remaking my system

thick fulcrum
#

I think 128

nova zenith
#

?

thick fulcrum
nova zenith
#

the probability doesnt even add up to 100

thick fulcrum
#

wait I send you a video

nova zenith
#

well my way goes like this

thick fulcrum
nova zenith
#

ive looked thru ur code to understand it but i need some help understanding

nova zenith
#

also i do have like a request kindaof

#

ill use ur system but could u add a way to where it will only run if the block that was broken is in an array

#

const allBlocks = [
"minecraft:stone",
"minecraft:coal_ore",
"minecraft:copper_ore",
"minecraft:iron_ore",
"minecraft:coal_block",
"minecraft:diorite",
"minecraft:iron_block",
"minecraft:andesite",
"minecraft:gold_ore",
"minecraft:emerald_ore",
"minecraft:diamond_ore"
]

#

i use this for mine

#

so i can still build at that height

#

actually nvm

#

i can add that ignore me

thick fulcrum
#

its generate a random nummer 0-1
for loop get the ore propability and typeId from the list than
its add the ore propability to a empty variable than it looks if the ore.propability is under the generated number if yes its set a block/ore

nova zenith
#

so the probability

#

is like percentage?

#

0.1 = 10%?

#

then 0.0025 = 0.25%?

#

in the probability?

thick fulcrum
nova zenith
rugged crystal
nova zenith
rugged crystal
#

istg i did to

#

like a day ago

nova zenith
#

forgor who u r tho ngl

rugged crystal
#

thats crazy

thick fulcrum
nova zenith
#

i need 0.25%

#

which from everything im seeing, would be 0.0025

#

probability

nova zenith
#

yea i said that already 😭

thick fulcrum
#

oh I didn't really saw that

#

sorry

#

xD

nova zenith
#

all good :)

#

ima try and see if i can convert my layering systems etc

thick fulcrum
#

here the video xD

nova zenith
thick fulcrum
#

Ik I could change that but I'm lazy

#

xD

nova zenith
#

i kinda need double layered

#

lmao

#

it needs it to be seamless

thick fulcrum
#

its just adding here some coords

    let positions = [
        { x: x, y: y - 1, z: z },
        { x: x, y: y + 1, z: z },
        { x: x, y: y, z: z + 1 },
        { x: x, y: y, z: z - 1 },
        { x: x - 1, y: y, z: z },
        { x: x + 1, y: y, z: z }
    ];
nova zenith
#

yea my brain hurts

thick fulcrum
#

xD

#

ok wait I make it for you

nova zenith
#

🙏

jaunty shadow