Package net.minecraftforge.client.event
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 theMinecraftForge.EVENT_BUS
This event isCancelable
screenshotFile
contains the file the screenshot will be/was saved toimage
contains theNativeImage
that will be savedresultMessage
contains theITextComponent
to be returned. Ifnull
, the default vanilla message will be used instead
-
-
Field Summary
Fields Modifier and Type Field Description static ITextComponent
DEFAULT_CANCEL_REASON
private NativeImage
image
private ITextComponent
resultMessage
private java.io.File
screenshotFile
-
Constructor Summary
Constructors Constructor Description ScreenshotEvent(NativeImage image, java.io.File screenshotFile)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ITextComponent
getCancelMessage()
NativeImage
getImage()
ITextComponent
getResultMessage()
java.io.File
getScreenshotFile()
void
setResultMessage(ITextComponent resultMessage)
void
setScreenshotFile(java.io.File screenshotFile)
-
-
-
Field Detail
-
DEFAULT_CANCEL_REASON
public static final ITextComponent DEFAULT_CANCEL_REASON
-
image
private NativeImage image
-
screenshotFile
private java.io.File screenshotFile
-
resultMessage
private ITextComponent resultMessage
-
-
Constructor Detail
-
ScreenshotEvent
public ScreenshotEvent(NativeImage image, java.io.File screenshotFile)
-
-
Method Detail
-
getImage
public NativeImage getImage()
-
getScreenshotFile
public java.io.File getScreenshotFile()
-
setScreenshotFile
public void setScreenshotFile(java.io.File screenshotFile)
-
getResultMessage
public ITextComponent getResultMessage()
-
setResultMessage
public void setResultMessage(ITextComponent resultMessage)
-
getCancelMessage
public ITextComponent getCancelMessage()
-
-