Add missing patch to ScreenShotHelper (#6809)

Adds the missed patch back
This commit is contained in:
Dominik Baumann 2020-06-26 03:42:17 +02:00 committed by GitHub
parent 6cfc88e707
commit 7bca3684bd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,6 +1,6 @@
--- a/net/minecraft/util/ScreenShotHelper.java
+++ b/net/minecraft/util/ScreenShotHelper.java
@@ -50,13 +50,21 @@
@@ -50,13 +50,23 @@
file2 = new File(file1, p_228051_1_);
}
@ -22,6 +22,8 @@
- p_228051_5_.accept(new TranslationTextComponent("screenshot.success", itextcomponent));
+ if (event.getResultMessage() != null)
+ p_228051_5_.accept(event.getResultMessage());
+ else
+ p_228051_5_.accept(new TranslationTextComponent("screenshot.success", itextcomponent));
} catch (Exception exception) {
field_148261_a.warn("Couldn't save screenshot", (Throwable)exception);
p_228051_5_.accept(new TranslationTextComponent("screenshot.failure", exception.getMessage()));