#[LootJS 1.19.2] Looking for some help simplifying code

12 messages · Page 1 of 1 (latest)

drowsy onyxBOT
#

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

unreal mirage
#

Hmmm

#

ill check this with lootjs

#

time check can't take in an object

#
let seasonSpring = ()=> { return {"period":2304000, "min":0, "max":576000}; }
let todDawn = ()=> { return {"period":24000, "min":5000, "max":11000}; }
event.addLootTypeModifier("fishing").and(and => {
    and.weatherCheck({ raining: false, thundering: false }).biome("#minecraft:is_ocean", "#minecraft:is_hot").timeCheck(seasonSpring().period, seasonSpring().min, seasonSpring().max).timeCheck(todDawn().period,todDawn().min, todDawn().max)
})
    .addLoot([Item.of("aquaculture:red_grouper").withChance(100)])
#

It doesnt relaly simplify it heh

#

but to do what you are trying to do it would have to be something like this (Though it cna certainly be simplified)

#

just notice dteh ticket is closed

#

lol

outer iris
#

I got help elsewhere btw

unreal mirage
#

Can you post the solution for future people.