public abstract class Minecraft extends Object implements Runnable, IPlayerUsage
Modifier and Type | Field and Description |
---|---|
GuiScreen |
currentScreen
The GuiScreen that's being displayed at the moment.
|
String |
debug
String that shows the debug information
|
int |
displayHeight |
int |
displayWidth |
EffectRenderer |
effectRenderer |
EntityRenderer |
entityRenderer |
FontRenderer |
fontRenderer
The font renderer used for displaying and measuring text.
|
GameSettings |
gameSettings
The game settings that currently hold effect.
|
GuiAchievement |
guiAchievement
Gui achievement
|
boolean |
hideQuitButton
a boolean to hide a Quit button from the main menu
|
GuiIngame |
ingameGUI |
boolean |
inGameHasFocus
Does the actual gameplay have focus.
|
boolean |
isGamePaused |
LoadingScreenRenderer |
loadingScreen |
Canvas |
mcCanvas |
File |
mcDataDir |
Profiler |
mcProfiler
The profiler instance
|
static byte[] |
memoryReserve
A 10MiB preallocation to ensure the heap is reasonably sized.
|
String |
minecraftUri |
MouseHelper |
mouseHelper
Mouse helper instance.
|
MovingObjectPosition |
objectMouseOver
The ray trace hit that the mouse is over.
|
PlayerControllerMP |
playerController |
EntityLiving |
pointedEntityLiving |
RenderEngine |
renderEngine
The RenderEngine instance used by Minecraft
|
RenderGlobal |
renderGlobal |
EntityLiving |
renderViewEntity
The Entity from which the renderer determines the render viewpoint.
|
boolean |
running
Set to true to keep the game loop running.
|
Session |
session |
boolean |
skipRenderWorld
Skip render world
|
SoundManager |
sndManager |
FontRenderer |
standardGalacticFontRenderer |
StatFileWriter |
statFileWriter
Stat file writer
|
TexturePackList |
texturePackList
The TexturePackLister used by this instance of Minecraft...
|
EntityClientPlayerMP |
thePlayer |
WorldClient |
theWorld |
Constructor and Description |
---|
Minecraft(Canvas par1Canvas,
MinecraftApplet par2MinecraftApplet,
int par3,
int par4,
boolean par5) |
Modifier and Type | Method and Description |
---|---|
CrashReport |
addGraphicsAndWorldToCrashReport(CrashReport par1CrashReport)
adds core server Info (GL version , Texture pack, isModded, type), and the worldInfo to the crash report
|
void |
addServerStatsToSnooper(PlayerUsageSnooper par1PlayerUsageSnooper) |
void |
addServerTypeToSnooper(PlayerUsageSnooper par1PlayerUsageSnooper) |
void |
continueWorldLoading() |
void |
crashed(CrashReport par1CrashReport) |
String |
debugInfoEntities()
A String of how many entities are in the world
|
String |
debugInfoRenders()
A String of renderGlobal.getDebugInfoRenders
|
void |
displayCrashReport(CrashReport par1CrashReport)
Wrapper around displayCrashReportInternal
|
abstract void |
displayCrashReportInternal(CrashReport crashreport) |
void |
displayGuiScreen(GuiScreen par1GuiScreen)
Sets the argument GuiScreen as the main (topmost visible) screen.
|
void |
displayInGameMenu()
Displays the ingame menu
|
static void |
fmlReentry(ArgsWrapper wrapper) |
void |
freeMemory() |
static File |
getAppDir(String par0Str)
gets the working dir (OS specific) for the specific application (which is always minecraft)
|
String |
getEntityDebug()
Gets the information in the F3 menu about how many entities are infront/around you
|
static int |
getGLMaximumTextureSize()
Used in the usage snooper.
|
IntegratedServer |
getIntegratedServer()
Returns the currently running integrated server
|
ILogAgent |
getLogAgent() |
static Minecraft |
getMinecraft()
Return the singleton Minecraft instance for the game
|
static File |
getMinecraftDir()
gets the working dir (OS specific) for minecraft
|
NetClientHandler |
getNetHandler()
Returns the NetClientHandler.
|
static EnumOS |
getOs() |
PlayerUsageSnooper |
getPlayerUsageSnooper()
Returns the PlayerUsageSnooper instance.
|
ISaveFormat |
getSaveLoader()
Returns the save loader that is currently being used
|
ServerData |
getServerData()
Get the current ServerData instance.
|
static long |
getSystemTime()
Gets the system time in milliseconds.
|
String |
getWorldProviderName()
Gets the name of the world's current chunk provider
|
boolean |
handleClientCommand(String par1Str)
Returns true if the message is a client command and should not be sent to the server.
|
void |
installResource(String par1Str,
File par2File)
Installs a resource.
|
static boolean |
isAmbientOcclusionEnabled()
Returns if ambient occlusion is enabled
|
boolean |
isDemo()
Gets whether this is a demo or not.
|
static boolean |
isFancyGraphicsEnabled() |
boolean |
isFullScreen()
Returns whether we're in full screen or not.
|
static boolean |
isGuiEnabled() |
boolean |
isIntegratedServerRunning() |
boolean |
isSingleplayer()
Returns true if there is only one player playing, and the current server is the integrated one.
|
boolean |
isSnooperEnabled()
Returns whether snooping is enabled or not.
|
void |
launchIntegratedServer(String par1Str,
String par2Str,
WorldSettings par3WorldSettings)
Arguments: World foldername, World ingame name, WorldSettings
|
void |
loadWorld(WorldClient par1WorldClient)
unloads the current world first
|
void |
loadWorld(WorldClient par1WorldClient,
String par2Str)
par2Str is displayed on the loading screen to the user unloads the current world first
|
static void |
main(String[] par0ArrayOfStr) |
void |
run() |
void |
runTick()
Runs the current tick.
|
void |
scaledTessellator(int par1,
int par2,
int par3,
int par4,
int par5,
int par6)
Loads Tessellator with a scaled resolution
|
void |
scheduleTexturePackRefresh()
Sets refreshTexturePacksScheduled to true, triggering a texture pack refresh next time the while(running) loop is
run
|
void |
setDimensionAndSpawnPlayer(int par1) |
void |
setIngameFocus()
Will set the focus to ingame if the Minecraft window is the active with focus.
|
void |
setIngameNotInFocus()
Resets the player keystate, disables the ingame focus, and ungrabs the mouse cursor.
|
void |
setServer(String par1Str,
int par2) |
void |
setServerData(ServerData par1ServerData)
Set the current ServerData instance.
|
void |
shutdown()
Called when the window is closing.
|
void |
shutdownMinecraftApplet()
Shuts down the minecraft applet by stopping the resource downloads, and clearing up GL stuff; called when the
application (or web page) is exited.
|
void |
startGame()
Starts the game: initializes the canvas, the title, the settings, etcetera.
|
static void |
stopIntegratedServer() |
void |
toggleFullscreen()
Toggles fullscreen mode.
|
public static byte[] memoryReserve
public PlayerControllerMP playerController
public int displayWidth
public int displayHeight
public WorldClient theWorld
public RenderGlobal renderGlobal
public EntityClientPlayerMP thePlayer
public EntityLiving renderViewEntity
public EntityLiving pointedEntityLiving
public EffectRenderer effectRenderer
public Session session
public String minecraftUri
public Canvas mcCanvas
public boolean hideQuitButton
public volatile boolean isGamePaused
public RenderEngine renderEngine
public FontRenderer fontRenderer
public FontRenderer standardGalacticFontRenderer
public GuiScreen currentScreen
public LoadingScreenRenderer loadingScreen
public EntityRenderer entityRenderer
public GuiAchievement guiAchievement
public GuiIngame ingameGUI
public boolean skipRenderWorld
public MovingObjectPosition objectMouseOver
public GameSettings gameSettings
public SoundManager sndManager
public MouseHelper mouseHelper
public TexturePackList texturePackList
public File mcDataDir
public StatFileWriter statFileWriter
public boolean inGameHasFocus
public final Profiler mcProfiler
public volatile boolean running
public String debug
public Minecraft(Canvas par1Canvas, MinecraftApplet par2MinecraftApplet, int par3, int par4, boolean par5)
public void crashed(CrashReport par1CrashReport)
public void displayCrashReport(CrashReport par1CrashReport)
public abstract void displayCrashReportInternal(CrashReport crashreport)
public void setServer(String par1Str, int par2)
public void startGame() throws org.lwjgl.LWJGLException
org.lwjgl.LWJGLException
public void scaledTessellator(int par1, int par2, int par3, int par4, int par5, int par6)
public static File getMinecraftDir()
public static File getAppDir(String par0Str)
public static EnumOS getOs()
public ISaveFormat getSaveLoader()
public void displayGuiScreen(GuiScreen par1GuiScreen)
public void shutdownMinecraftApplet()
public void freeMemory()
public void shutdown()
public void setIngameFocus()
public void setIngameNotInFocus()
public void displayInGameMenu()
public void toggleFullscreen()
public void runTick()
public void launchIntegratedServer(String par1Str, String par2Str, WorldSettings par3WorldSettings)
public void continueWorldLoading()
public void loadWorld(WorldClient par1WorldClient)
public void loadWorld(WorldClient par1WorldClient, String par2Str)
public void installResource(String par1Str, File par2File)
public String debugInfoRenders()
public String getEntityDebug()
public String getWorldProviderName()
public String debugInfoEntities()
public void setDimensionAndSpawnPlayer(int par1)
public final boolean isDemo()
public NetClientHandler getNetHandler()
public static void main(String[] par0ArrayOfStr)
public static void fmlReentry(ArgsWrapper wrapper)
public static boolean isGuiEnabled()
public static boolean isFancyGraphicsEnabled()
public static boolean isAmbientOcclusionEnabled()
public boolean handleClientCommand(String par1Str)
public CrashReport addGraphicsAndWorldToCrashReport(CrashReport par1CrashReport)
public static Minecraft getMinecraft()
public void scheduleTexturePackRefresh()
public void addServerStatsToSnooper(PlayerUsageSnooper par1PlayerUsageSnooper)
addServerStatsToSnooper
in interface IPlayerUsage
public void addServerTypeToSnooper(PlayerUsageSnooper par1PlayerUsageSnooper)
addServerTypeToSnooper
in interface IPlayerUsage
public static int getGLMaximumTextureSize()
public boolean isSnooperEnabled()
isSnooperEnabled
in interface IPlayerUsage
public void setServerData(ServerData par1ServerData)
public ServerData getServerData()
public boolean isIntegratedServerRunning()
public boolean isSingleplayer()
public IntegratedServer getIntegratedServer()
public static void stopIntegratedServer()
public PlayerUsageSnooper getPlayerUsageSnooper()
public static long getSystemTime()
public boolean isFullScreen()
public ILogAgent getLogAgent()
getLogAgent
in interface IPlayerUsage