#e is not defined P a i n

131 messages · Page 1 of 1 (latest)

atomic crag
#
//frick you
    e.remove({output: 'minecraft:crafting_table'});    
    e.shaped(Item.of('minecraft:crafting_table'), [
        '   ',
        'FF ',
        'LL ',
        ], {
        F: 'minecraft:flint',
        L: 'minecraft:log',
        });
//frick you more
    e.remove({output: '#forge:chests/wooden'});    
    e.shaped(Item.of('minecraft:chest'), [
        'PLP',
        'LCL',
        'PLP',
        ], {
        P: '#minecraft:planks',
        L: '#minecraft:logs',
        C: '#forge:nuggets/copper'
        });
//frick you the most
    e.remove({output: 'minecraft:furnace'});    
    e.remove({output: 'quark:blackstone_furnace'});    
    e.remove({output: 'quark:deepslate_furnace'});    
    e.shaped(Item.of('minecraft:furnace'), [
        'CCC',
        'CFC',
        'LGL'
        ], {
        C: '#forge:cobblestone',
        L: '#forge:raw_materials/copper',
        F: 'minecraft:campfire',
        G: '#minecraft:coals'
        });
    e.shaped(Item.of('quark:blackstone_furnace'), [
        'CCC',
        'CFC',
        'LGL'
        ], {
        C: 'minecraft:blackstone',
        L: '#forge:raw_materials/copper',
        F: 'minecraft:campfire',
        G: '#minecraft:coals'
        });
    e.shaped(Item.of('quark:deepslate_furnace'), [
        'CCC',
        'CFC',
        'LGL'
        ], {
        C: 'minecraft:cobbled_deepslate',
        L: '#forge:raw_materials/copper',
        F: 'minecraft:campfire',
        G: '#minecraft:coals'
        });
//nerf plank recipe (hehe expert pack)
    e.forEachRecipe({type: 'minecraft:crafting_shapeless', input: '#minecraft:logs', output: '#minecraft:planks'}, r => {
    e.remove({type: 'minecraft:crafting_shapeless', input: '#minecraft:logs', output: '#minecraft:planks'})
    e.shapeless(r.outputItems[0].withCount(2), r.inputItems[0].withCount(1))})
//slabs nerf
    e.forEachRecipe({ type: 'minecraft:crafting_shaped', output: '#minecraft:slabs' }, r => {
    e.shaped(r.inputItems[0], ["A", "A"], { A: r.outputItems[0].withCount(1) })})
//sticks nerf
    e.remove({input: '#minecraft:planks', output:'minecraft:stick'})    
    e.shaped('2x minecraft:stick', [
    'P  ',
    'P  ',
    '   ',
    ], {
    P: '#minecraft:planks',
    })
    //bed recipe
    e.remove({output: '#minecraft:beds'})
    const colors = [
        'white', 
        'orange', 
        'magenta', 
        'light_blue',
        'yellow', 
        'lime', 
        'pink', 
        'gray', 
        'light_gray', 
        'cyan', 
        'purple', 
        'blue', 
        'brown', 
        'green', 
        'red', 
        'black',
    ];
    //how
    for (let i = 0; i < colors.length; i++) {
    e.shaped('minecraft:' + colors[i] + '_bed', [
    'CCH',
    'OOO',
    'PFP',
    ], {    
        P: '#minecraft:planks',
        F: '#forge:fences/wooden',
        O: 'minecraft:' + colors[i] + '_wool',
        H: 'immersiveengineering:hammer',
        C: 'minecraft:feather'
    }).damageIngredient(Item.of('immersiveengineering:hammer').ignoreNBT());
    }
})  ```


aaaaaaaaaaaaaaaaaaaaaaaa whyyy the other script file works its just the same 😭
gentle thistleBOT
#

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

remote dome
#
  1. I think that e is not defined
  2. the item's id is invalid
  3. same as 2
  4. r.outputItems is undefined
atomic crag
#

wdym by not defined? ServerEvents.recipes(e => { is not the way?

remote dome
#

it is

atomic crag
#

i did it just the same and it works here Cat_Cry

atomic crag
#

already

remote dome
#

what's line 57?

atomic crag
remote dome
atomic crag
#

IKR

remote dome
#

it's not in the script that you sent...

#

send your whole script and not a part heh

atomic crag
#

oh wAit

#

nono

#

i screenshotted the different file

#

by accident

#

lmao

#

this is line 57

remote dome
#

what hmmm

atomic crag
#

i screenshotted a different js file by accident because i opened it to check cuz its the working one 😭

trim cargo
#

||Tip: Emotional words don't make the problem any better.||

atomic crag
#

im legit so stuck

#

lmao

remote dome
#

just to be sure, what file did you send?

atomic crag
atomic crag
atomic crag
# atomic crag

this is line 57 of recipes.js which i screenshotted by accident

#

oH

#

ERROR IS RECIPES.JS

#

WHAT?

#

how did it

#

how was an error made after i made a new file..

trim cargo
#

show the error to here

atomic crag
#

okay its an error for both files

remote dome
atomic crag
#

a

remote dome
#

and you only sent one+

#

...

atomic crag
#
    e.remove({output: 'create:gearbox'});
    e.remove({output: 'create_dd:integrated_circuit'});
    e.remove({output: 'create_dd:integrated_mechanism'});
    e.remove({output: 'biomancy:stone_powder'});

    e.shaped(Item.of('create:gearbox', 1), [
        'BGB',
        'GCG',
        'BGB'
      ], {
        B: 'kubejs:andesite_bearing',
        C: 'create:andesite_casing',
        G: 'create:cogwheel'
      });

    e.shaped(Item.of('kubejs:andesite_bearing', 1), [
        'BIB',
        'BRB',
        'BIB'
      ], {
        B: 'kubejs:stone_ball_bearing',
        R: 'gtceu:iron_ring',
        I: 'minecraft:iron_ingot'
      });

    e.recipes.create.sandpaper_polishing('kubejs:stone_ball_bearing', 'botania:pebble');

    e.recipes.create.splashing([
    Item.of('botania:pebble').withChance(0.05), 
    Item.of('minecraft:iron_nugget').withChance(0.225), 
    Item.of('biomancy:stone_powder').withChance(0.65)], 
    'kubejs:refined_gravel');

  let inter = 'create_dd:incomplete_integrated_mechanism';
  e.recipes.create.sequenced_assembly([
      Item.of('create_dd:integrated_mechanism').withChance(1), 
  ], 'create:precision_mechanism', [ 
      e.recipes.createDeploying(inter, [inter, 'create:cogwheel']),
      e.recipes.createDeploying(inter, [inter, '#forge:plates/brass']),
      e.recipes.createDeploying(inter, [inter, 'create_dd:integrated_circuit']),
      e.recipes.createDeploying(inter, [inter, 'create:electron_tube']),
      e.recipes.createPressing(inter, inter),
  ]).transitionalItem(inter).loops(4) 

    inter = 'create_dd:incomplete_integrated_circuit';
    e.recipes.create.sequenced_assembly([
        Item.of('create_dd:integrated_circuit').withChance(1), 
    ], 'gtceu:basic_electronic_circuit', [ 
        e.recipes.createFilling(inter, [inter, Fluid.of('gtceu:red_alloy',420)]),
        e.recipes.createDeploying(inter, [inter, 'gtceu:nether_quartz_plate']),
        e.recipes.createDeploying(inter, [inter, 'createaddition:electrum_wire']),
        e.recipes.createPressing(inter, inter),
    ]).transitionalItem(inter).loops(4);
})
    //engineer's hammer
    e.remove({output: 'immersiveengineering:hammer'})    
    e.shaped('immersiveengineering:hammer', [
    ' PS',
    ' RP',
    'RW ',
    ], {
    R: '#forge:rods/wooden',
    S: '#forge:string',
    P: '#forge:plates/iron',
    W: '#forge:tools/wrenches'
    }).damageIngredient(Item.of('#forge:tools/wrenches').ignoreNBT());```
#

i didnt see lmao

#

this is recipes.js

remote dome
#

})

atomic crag
#

WAIT

#

ong

remote dome
#

you close the recipes event

#

before the recipe

#

🗿

atomic crag
#

usually studio code highlights it 4HEad

#

w hat even

#

ohhhhhhhhhhhhhh

remote dome
atomic crag
#

this pack is gonna take me forever Clueless

#

ok down to

#

3 errors!

trim cargo
remote dome
#

amazing heh

atomic crag
#

eeeeee

remote dome
atomic crag
trim cargo
#

heh vscode is a good tool

remote dome
atomic crag
#

goldfish memory

remote dome
#

well, at least gave the reason why it's erroring heh

remote dome
#

fair

atomic crag
#

okay uh

trim cargo
#

||I have another question, why would someone abbreviate event as e; recipe as r. Doesn't this make it less readable?||

remote dome
#

it's better

trim cargo
remote dome
#

lexxie would say the same thing heh

atomic crag
#

ok so this is the main pain and i have no idea where

remote dome
#

it tells you where tho

atomic crag
#

wait

#

result cant be empty..?

remote dome
#

yes

#

result can't be empty

atomic crag
#

but its.. not empty..?????

#

am i dum

#

o h

remote dome
#

??kjserrors

atomic crag
#

we down to 1 error boys

wet sundialBOT
# remote dome ??kjserrors

The ItemStack '...' can't be empty errors means that the id you gave the script is invalid. For example:

e.shapeless('kubejs:some_item_that_doesnt_exist', 'diamond')

The above script would error given that the item with the id of kubejs:some_item_that_doesnt_exist doesn't exist.

remote dome
#

just for you hih

atomic crag
#

thanks lmao

#

uh

remote dome
#

r.outputItems is undefined

atomic crag
#

line 40

#

uhhhhhhhhhhhhhhh

remote dome
#

yes

atomic crag
#

o H

remote dome
#

as I said

#

btw

#

do you use probejs?

#

if not, than start heh

atomic crag
#

no i ball it on school javascript knowledge

remote dome
#

it's very neat hih

#

??kjsaddons

atomic crag
#

okay

wet sundialBOT
# remote dome ??kjsaddons

ProbeJS is an addon mod for KubeJS that generates typings files for VSCode, allowing VSCode to offer autocompletions for a ton of things!

Mod by @karmic robin

atomic crag
#

lmao

remote dome
atomic crag
#

thank

#

okay yea

#

it works now

#

me dum

#

thank you lmao

remote dome
#

happens to all of us

atomic crag
#

ty

remote dome
#

:D

atomic crag
#

uhhhh

remote dome
#

?

atomic crag
#

lemme scroll up to see the command

#

for

#

ending

#

XDD