MashKJo
如题,scripts路径下的其他zs文件都正常,就Vanilla.zs不能加载
  1. //Crafting Tables
  2. recipes.addShapeless(<minecraft:coal:1>, [<minecraft:fire_charge>,<ore:logWood>]);

  3. recipes.remove(<minecraft:stone_sword>);
  4. recipes.addShaped(<minecraft:stone_sword>, [[null, <minecraft:stone>, null],
  5. [null, <minecraft:stone>, null],
  6. [null, <minecraft:stick>, null]]);

  7. recipes.remove(<minecraft:stone_pickaxe>);
  8. recipes.addShaped(<minecraft:stone_pickaxe>, [[<minecraft:stone>, <minecraft:stone>, <minecraft:stone>],
  9. [null, <minecraft:stick>, null],
  10. [null, <minecraft:stick>, null]]);

  11. recipes.remove(<minecraft:stone_axe>);
  12. recipes.addShaped(<minecraft:stone_axe>, [[<minecraft:stone>, <minecraft:stone>, null],
  13. [<minecraft:stone>, <minecraft:stick>, null],
  14. [null, <minecraft:stick>, null]]);
  15. recipes.addShaped(<minecraft:stone_axe>, [[null, <minecraft:stone>, <minecraft:stone>],
  16. [null, <minecraft:stick>, <minecraft:stone>],
  17. [null, <minecraft:stick>, null]]);

  18. recipes.remove(<minecraft:stone_hoe>);
  19. recipes.addShaped(<minecraft:stone_hoe>, [[<minecraft:stone>, <minecraft:stone>, null],
  20. [null, <minecraft:stick>, null],
  21. [null, <minecraft:stick>, null]]);
  22. recipes.addShaped(<minecraft:stone_hoe>, [[null, <minecraft:stone>, <minecraft:stone>],
  23. [null, <minecraft:stick>, null],
  24. [null, <minecraft:stick>, null]]);

  25. recipes.remove(<minecraft:stone_shovel>);
  26. recipes.addShaped(<minecraft:stone_shovel>, [[null, <minecraft:stone>, null],
  27. [null, <minecraft:stick>, null],
  28. [null, <minecraft:stick>, null]]);

  29. recipes.remove(<minecraft:furnace>);
  30. recipes.addShaped(<minecraft:furnace>, [[<minecraft:cobblestone>, <minecraft:cobblestone>, <minecraft:cobblestone>],
  31. [<minecraft:cobblestone>, <minecraft:coal:1>, <minecraft:cobblestone>],
  32. [<minecraft:cobblestone>, <minecraft:cobblestone>, <minecraft:cobblestone>]]);

  33. recipes.remove(<minecraft:glowstone>);
  34. recipes.addShapeless(<minecraft:glowstone>,
  35. [<minecraft:glowstone_dust>,<minecraft:glowstone_dust>,<minecraft:glowstone_dust>,
  36. <minecraft:glowstone_dust>,<minecraft:glowstone_dust>,<minecraft:glowstone_dust>,
  37. <minecraft:glowstone_dust>,<minecraft:glowstone_dust>,<minecraft:glowstone_dust>]);

  38. recipes.remove(<minecraft:blaze_powder>, [<minecraft:blaze_rod>]);
  39. recipes.addShapeless(<minecraft:blaze_powder>, [<minecraft:blaze_rod>]);

  40. recipes.remove(<minecraft:brewing_stand>);
  41. recipes.addShaped(<minecraft:brewing_stand>, [[<minecraft:obsidian>, <minecraft:blaze_rod>, <minecraft:obsidian>],
  42. [null, <minecraft:blaze_rod>, null],
  43. [<ore:stone>, <ore:stone>, <ore:stone>]]);

  44. recipes.remove(<minecraft:beacon>);
  45. recipes.addShaped(<minecraft:beacon>, [[<ore:blockGlassColorless>, <minecraft:diamond>, <ore:blockGlassColorless>],
  46. [<minecraft:diamond>, <minecraft:nether_star>, <minecraft:diamond>],
  47. [<minecraft:obsidian>, <minecraft:obsidian>, <minecraft:obsidian>]]);

  48. recipes.remove(<minecraft:ender_eye>);
  49. recipes.addShapeless(<minecraft:ender_eye>*3, [<minecraft:ender_pearl>,<minecraft:blaze_powder>,<abyssalcraft:transmutationgem>]);


  50. //Furnaces
  51. furnace.remove(<minecraft:coal:1>);
  52. furnace.setFuel(<minecraft:fire_charge>, 3200);
复制代码
另外,log里面也有报错:
  1. [00:36:03] [Client thread/INFO] [net.minecraft.client.gui.GuiNewChat]: [CHAT] §cERROR: Vanilla.zs:46 > Cannot cast ZenTypeNative: crafttweaker.item.IItemStack to ZenTypeNative: crafttweaker.data.IData
  2. [00:36:03] [Client thread/INFO] [net.minecraft.client.gui.GuiNewChat]: [CHAT] §cERROR: [crafttweaker]: Error executing {[0:crafttweaker]: Vanilla.zs}: Bad type on operand stack\nException Details:\n  Location:\n    Vanilla.__script__()V @1283: invokestatic\n  Reason:\n    Type integer (current frame, stack[2]) is not assignable to '[Lcrafttweaker/api/data/IData;'\n  Current Frame:\n    bci: @1283\n    flags: { }\n
复制代码



Dark2932
提示你46行类搞错了
看看文件是不是发错了
我看你这文件里面没有IData类
发pastebin
https://paste.ubuntu.com/

MashKJo
暗夜awa 发表于 2021-8-10 08:04
提示你46行类搞错了
看看文件是不是发错了
我看你这文件里面没有IData类

没发错,。

Dark2932

那我也不知道了
这确实看不出来什么问题
46行删除配方的地方你是想删指定配方的物品吧
笨方法:可以先删除所有,再用你的合成表加回来

longinuski
本帖最后由 qq857945782 于 2021-8-10 09:31 编辑

你46行就是有问题吧recipes.remove(<minecraft:blaze_powder>, [<minecraft:blaze_rod>]);
应该是recipes.removeShapeless(<minecraft:blaze_powder>, <minecraft:blaze_rod>);

MashKJo
qq857945782 发表于 2021-8-10 09:27
你46行就是有问题吧recipes.remove(, []);
不知道你想写的是什么

所以有什么问题吗

longinuski
MashKJo 发表于 2021-8-10 09:28
所以有什么问题吗

https://docs.blamejared.com/1.12 ... pes_Crafting_Table/
只有 recipes.remove(output, NBTMatch);
       recipes.removeShaped(output, inputs);
       recipes.removeShapeless(output, inputs, wildcard);    三种