#raising the boiling point

9 messages · Page 1 of 1 (latest)

grave quiver
#

is Kubejs capable of making it so water DOESN'T evaporate in the nether?

teal crestBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

turbid cedar
# grave quiver is Kubejs capable of making it so water DOESN'T evaporate in the nether?

iirc the water evaporating logic locates in bucket items, so you should be able to add the water block back with block.set in BlockEvents.rightClicked.

You just need to check if the dimention is ultraWarm()
https://lexxie.dev/forge/1.19.2/net/minecraft/world/level/dimension/DimensionType.html#ultraWarm()

And check if the block clicked is LiquidBlockContainer (able to be water logged)
https://lexxie.dev/forge/1.19.2/net/minecraft/world/level/block/LiquidBlockContainer.html

And if that's false check if the block at the direction you click is air

Place water when suitable, and if all that are false, replace the empty bucket in hand with a full water bucket.

grave quiver
turbid cedar
#

well, I can write some example code later

grave quiver
#

Your the best bro

turbid cedar
#
BlockEvents.rightClicked(event => {
    const {item, level, block, facing, player, hand} = event
    if(item.id != "minecraft:water_bucket") return;
    if(!level.dimensionType().ultraWarm()) return;
    const waterloggedPropertyOptional = block.blockState.properties.stream().filter(property => property.getName() == "waterlogged").findFirst()
    if(waterloggedPropertyOptional.present){
        const [propertyTrue, propertyFalse] = [true, false].map(boolean => waterloggedPropertyOptional.get().getValue(`${boolean}`).get())
        if(block.blockState.getValue(waterloggedPropertyOptional.get() == false)){
            block.blockState.setValue(propertyTrue)
            return;
        }
    }

    const /**@type {Internal.BlockContainerJS} */ targetedBlock = block[facing]
    if(targetedBlock.blockState.isAir()) {
        targetedBlock.set("minecraft:water")
        return;
    }

    player.setItemInHand(hand, "minecraft:water_bucket")
})
grave quiver
#

this also worked on create:honey

#

thanx bro