3
0
Mirror von https://github.com/GeyserMC/Geyser.git synchronisiert 2024-11-03 14:50:19 +01:00

[ci skip] Clarify strip NBT comment

Dieser Commit ist enthalten in:
Camotoy 2021-01-19 18:22:07 -05:00
Ursprung 75ae28f460
Commit 2304c1375e
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 7EEFB66FE798081F

Datei anzeigen

@ -68,7 +68,8 @@ public class JavaDeclareRecipesTranslator extends PacketTranslator<ServerDeclare
case CRAFTING_SHAPELESS: { case CRAFTING_SHAPELESS: {
ShapelessRecipeData shapelessRecipeData = (ShapelessRecipeData) recipe.getData(); ShapelessRecipeData shapelessRecipeData = (ShapelessRecipeData) recipe.getData();
ItemData output = ItemTranslator.translateToBedrock(session, shapelessRecipeData.getResult()); ItemData output = ItemTranslator.translateToBedrock(session, shapelessRecipeData.getResult());
output = ItemData.of(output.getId(), output.getDamage(), output.getCount()); //strip NBT // Strip NBT - tools won't appear in the recipe book otherwise
output = ItemData.of(output.getId(), output.getDamage(), output.getCount());
ItemData[][] inputCombinations = combinations(session, shapelessRecipeData.getIngredients()); ItemData[][] inputCombinations = combinations(session, shapelessRecipeData.getIngredients());
for (ItemData[] inputs : inputCombinations) { for (ItemData[] inputs : inputCombinations) {
UUID uuid = UUID.randomUUID(); UUID uuid = UUID.randomUUID();
@ -81,7 +82,8 @@ public class JavaDeclareRecipesTranslator extends PacketTranslator<ServerDeclare
case CRAFTING_SHAPED: { case CRAFTING_SHAPED: {
ShapedRecipeData shapedRecipeData = (ShapedRecipeData) recipe.getData(); ShapedRecipeData shapedRecipeData = (ShapedRecipeData) recipe.getData();
ItemData output = ItemTranslator.translateToBedrock(session, shapedRecipeData.getResult()); ItemData output = ItemTranslator.translateToBedrock(session, shapedRecipeData.getResult());
output = ItemData.of(output.getId(), output.getDamage(), output.getCount()); //strip NBT // See above
output = ItemData.of(output.getId(), output.getDamage(), output.getCount());
ItemData[][] inputCombinations = combinations(session, shapedRecipeData.getIngredients()); ItemData[][] inputCombinations = combinations(session, shapedRecipeData.getIngredients());
for (ItemData[] inputs : inputCombinations) { for (ItemData[] inputs : inputCombinations) {
UUID uuid = UUID.randomUUID(); UUID uuid = UUID.randomUUID();