Class ScreenshotEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.client.event.ScreenshotEvent

public class ScreenshotEvent extends net.minecraftforge.eventbus.api.Event
This event is fired before and after a screenshot is taken This event is fired on the MinecraftForge.EVENT_BUS This event is Cancelable screenshotFile contains the file the screenshot will be/was saved to image contains the NativeImage that will be saved resultMessage contains the Component to be returned. If null, the default vanilla message will be used instead
  • Field Details

    • DEFAULT_CANCEL_REASON

      public static final Component DEFAULT_CANCEL_REASON
    • image

      private NativeImage image
    • screenshotFile

      private File screenshotFile
    • resultMessage

      private Component resultMessage
  • Constructor Details

    • ScreenshotEvent

      public ScreenshotEvent(NativeImage image, File screenshotFile)
  • Method Details

    • getImage

      public NativeImage getImage()
    • getScreenshotFile

      public File getScreenshotFile()
    • setScreenshotFile

      public void setScreenshotFile(File screenshotFile)
    • getResultMessage

      public Component getResultMessage()
    • setResultMessage

      public void setResultMessage(Component resultMessage)
    • getCancelMessage

      public Component getCancelMessage()