import crafttweaker.item.IItemStack; // Define the recipe pattern var pattern as IItemStack[][] = [ [, , ], [, null, ], [, , ] ]; // Loop through all scroll types (1-251) for i in 1 to 252 { // Replace the center item with the appropriate scroll pattern[1][1] = .withDamage(i); // Add the shaped recipe recipes.addShaped(.withDamage(i)*16, pattern); }