in startup_scripts i add an item id list to the global object like this:
global["ITEMS_TO_REMOVE"] = [
"minecraft:diamond_ore",
"minecraft:deepslate_diamond_ore",
"vs_tournament:gift_bag",
"minecraft:acacia_boat",
"create_connected:copycat_beam",
"create_connected:copycat_block",
"create_connected:copycat_board",
"create_connected:copycat_box",
"create_connected:copycat_catwalk",
"create_connected:copycat_fence",
"create_connected:copycat_fence_gate",
"create_connected:copycat_slab",
"create_connected:copycat_stairs",
"create_connected:copycat_vertical_step",
"create_connected:copycat_wall",
"create_connected:bamboo_window",
];```
and then i use that list in `server_scripts` to remove the items recipes with `ServerEvents.recipes()`, and that works fine, all recipes of the items from the list are removed correctly
i also use this list in `client_scripts` to hide the items from JEI with `JEIEevents.hideItems()` like this:
```js
JEIEvents.hideItems((e) => {
console.log(
"create_connected LOADED: " + Platform.isLoaded("create_connected")
);
console.log("HIDING " + global.ITEMS_TO_REMOVE.toString());
e.hide(global.ITEMS_TO_REMOVE);
});```
first log logs true
second log correctly logs the item array
the issue is that after launcing up minecraft and entering a world, none of the items from `create_connected` mod are hidden from JEI, other items in that list are hidden correctly
running the `/reload` command fixes the issue
restarting minecraft, entering a world again results in the mod's items not being hidden, but `/reload` re-runs the client script so the items get hidden correctly, but i would like them to be hidden on the first script run like the other items
i suspect that the `hideItems()` function is being called before the mod items are loaded or something like that? but `Platform.isLoaded("create_connected")` returns true, so what could be the issue?