Neat little snippet! I was kind of tinkering with the idea of using Java to access Minecraft's class files for in-game custom commands.