Tuesday, 8 October 2013

The most important Minecraft Classes

The Minecraft code is based around a handful of Classes with different responsibilities.  Most of them are split into two parts - the Client side and the Server side; communication between the two is by Packets.  When writing mods it is usually vitally important to know which "side" your code is running on.  If you try to run client code on the server side (or vica versa) it will cause crashes or loss of client-server synchronisation (eg items which disappear).

The diagram below shows the most significant Classes responsible for storing, maintaining and synchronising the game state.

Other significant Classes are
  • Block and its derived classes
  • Item and its derived classes
  • Entity and its derived classes
  • Container and its derived classes
  • TileEntity and its derived classes
For more information, see here.  The game loops are in Minecraft and MinecraftServer, described in more detail here.




1 comment:

  1. So good to raed this.This is so informative.Thank for sharing The Minecraft hack is required for those who love playing the game to get the maximum amount of achievements and unlocking the premium level. This level is a special membership which allows the maximum amount of added benefits to the user.

    ReplyDelete