Skip to content

Instantly share code, notes, and snippets.

@dshadowwolf
Created January 17, 2020 14:37
Show Gist options
  • Save dshadowwolf/5948d773788a3dd0df86b2a8d786ff40 to your computer and use it in GitHub Desktop.
Save dshadowwolf/5948d773788a3dd0df86b2a8d786ff40 to your computer and use it in GitHub Desktop.
val planks as IIngredient[] = [ <minecraft:planks>, <minecraft:planks:1>, <minecraft:planks:2>, <minecraft:planks:3>, <minecraft:planks:4>, <minecraft:planks:5> ];
val logs as IIngredient[] = [ <minecraft:log>, <minecraft:log:1>, <minecraft:log:2>, <minecraft:log:3>, <minecraft:log2>, <minecraft:log2:1> ];
val axes as IIngredient[] = [ <minecraft:wooden_axe>, <minecraft:stone_axe>, <minecraft:golden_axe>, <minecraft:iron_axe>, <minecraft:diamond_axe> ];
val amount as int[] = [ 1, 1, 1, 2, 3 ];
val wood_names as string[] = [ "oak", "spruce", "birch", "jungle", "acacia", "dark_oak" ];
val axe_names as string[] = [ "primitive", "primitive", "primitive", "ordinary", "advanced" ];
for i, item in planks {
recipes.remove(item*4);
for x, axe in axes {
recipes.addShapeless( wood_names[i]+"_planks_with_"+axe_names[x]+"_axe", item*amount[x], [ logs[i], axe.anyDamage().transformDamage ]);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment