#My Server_Scripts Not Working on Server

51 messages · Page 1 of 1 (latest)

safe eagle
#

Hey i wrote something that fixed some recipe issues in my singleplayer world, now i am hosting a server and just copyed the file over and it don´t work.
The script should in the first line remove the old ones and in the last ones add the new ones. That is my first dive in Kubejs so it is thrown together.

unborn egretBOT
#

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

hybrid tokenBOT
#

Paste version of BrickFix_-_Kopie.txt from @safe eagle

lyric gust
#

why is your script a txt

lethal moss
#

you have a trailing comma on your array

safe eagle
lyric gust
#

you can send any file

safe eagle
lyric gust
#

its not the trailing comma

#

JS doesnt care about that

lethal moss
#

also, why are you storing your event.smelt in a constant?

lethal moss
lyric gust
#

never seen it have an issue, on any version

lethal moss
#

i had sh** broken for that =/

#

i had do remove that rule from my Linter

#

at some case it complains

safe eagle
lyric gust
#

nobody puts recipes in a list

lethal moss
#

i have never seen people storing event.smelting or something being stored in a constant/var

lyric gust
#
ServerEvents.recipes(event => {
  //Remove by item ID
  [
    'twigs:cracked_bricks',
    'blockus:charred_bricks',
    'biomemakeover:cracked_bricks'
  ].forEach(itemID => event.remove({ output: itemID }))

  //left Output right Input twigs:cracked_bricks minecraft:bricks blockus:charred_bricks biomemakeover:cracked_bricks 
  event.smelting('biomemakeover:cracked_bricks', 'minecraft:bricks')
  event.smelting('twigs:cracked_bricks', 'biomemakeover:cracked_bricks')
  event.smelting('blockus:charred_bricks', 'twigs:cracked_bricks')
})
lethal moss
#

@lyric gust he claims it works on singleplayer, that is super sus 😐

lyric gust
#

yeah theres something definitey wrong on the user side

#

->

#

not the script

#

show me your server log

hybrid tokenBOT
#

You can find your KubeJS server log in /minecraft/logs/kubejs/server.log.
If you are on 1.18 or below it will be called server.txt.
Please send it if asked, as it contains helpful information.

lethal moss
#

KubeJS loaded with no errors
"works for me on single" heh
hope it was not the case and he actually checked recipe/JEI

safe eagle
hybrid tokenBOT
#

Paste version of server.log from @safe eagle

lyric gust
#
Unknown item 'geode_plus:prismarine_cluster'
sleek osprey
#

well, there's your error

lyric gust
#

:P

sleek osprey
#

ctrl+f in the file and find that item

safe eagle
#

that is sice the beginning i copyed all of fabric 7 this error was already there i needed to remove the geode mod (I have the same error in singleplayer)

sleek osprey
#

okay, then remove the recipe. simple as that

#

if you removed the mod then yeah

#

or if it's the input of the recipe, change it to sometihng else

safe eagle
#

do i need to search in all the text files from the AOF Team or is there a easyer way to find it

sleek osprey
#

isn't there a way in visual studio code to search for text in multiple files...?

lyric gust
#

there is ofc

lethal moss
#

yes

lyric gust
safe eagle
#

ok that nice to know...sorry first time

sleek osprey
#

nah it's fine

#

that's what we're here for

safe eagle
#

removed all lines that where not needed and replaced my script with that from Lexxie

#

Yey it works

#

then it was the lines from geode :(

lyric gust
safe eagle
#

i definitly need to learn more. There are a LOT more overlapping recipie but thank you guys ^^