Questions tagged [minecraft]

Use this tag for programming-related questions about the computer game Minecraft. Note: Minecraft questions are generally OFF-TOPIC on Stack Overflow unless they relate to creating mods/plugins or otherwise developing for the game. Questions related to gameplay are best asked on gaming.stackexchange.com.

Minecraft is a voxel-based sandbox game coded in Java with LWJGL (which includes OpenGL) by Markus "Notch" Persson and his company Mojang.

In September 2014 Mojang was bought by Microsoft and the founders including Notch no longer work for the company. Source.

In the game players interact with the world formed of blocks to gain resources that can be used to create tools, structures, shelter, and eventually, complicated machinery. The game comes with enough features of wiring to allow the complexity to build a full 16-bit CPU out of its wiring.

Multiplayer functionality can be used by downloading a server that runs in Java and takes commands from the command line or from users typing commands starting with a slash / in-game on the server chat.

Questions are also sometimes used with to denote coding Bukkit plugins written in Java, which modify serverside behavior of the game (but cannot add new blocks or items, only new behaviours). Such plugins normally support the CraftBukkit and Spigot implementations of the API, although there are some with specific implementation dependencies. A Bukkit plugin's base plugin class must extend org.bukkit.plugin.java.JavaPlugin for the Bukkit Server class loader to recognize them. Note that as of August 21, 2014 at 8:42 AM, Bukkit has been discontinued, and both CraftBukkit and Spigot (implementations of Bukkit) has been taken down due to DMCA requests.

Clientside mods are usually written using [MinecraftForge] and are capable of adding new blocks and items. For more information about MinecraftForge, see .

Minecraft is available on:

  • PC May 17, 2009 (first public release as Developmental Alpha Version)
  • Xperia Play - August 16, 2011 (Pocket Edition)
  • Android - October 7, 2011 (Pocket Edition)
  • iOS - November 17, 2011 (Pocket Edition)
  • PC - November 18, 2011 (Official Release)
  • Raspberry Pi - February 11, 2013 (Pi Edition based on the Pocket Edition)
  • Playstation 3 - May 14, 2014
  • Playstation 4 - October 3, 2014
  • Xbox 360 - May 9, 2012
  • Xbox One - September 5, 2014
  • Nintendo Switch - May 12, 2017

The game has reached huge levels of popularity and has made a large sensation (Minecraft has now sold over 15 million copies for PC/Mac).

Official website of the game: Minecraft.net

NOTICE: Questions about playing Minecraft are generally OFF-TOPIC on Stack Overflow. Please post on our sister site, Arqade, using one of the following tags depending on which edition of Minecraft you have:

Questions regarding developing mods are, however, on-topic.

3762 questions
11
votes
5 answers

Gradle sync failed: Unable to make field private static final java.util.Map java.lang.ProcessEnvironment.theCaseInsensitiveEnvironment accessible

I try to build my gradle project and I get the following error: 1:36 PM Gradle sync failed: Unable to make field private static final java.util.Map java.lang.ProcessEnvironment.theCaseInsensitiveEnvironment accessible: module java.base does not…
Quapi
  • 111
  • 1
  • 2
  • 5
11
votes
1 answer

How to decode Data (ie block state) bytes in Minecraft schematic (nbt) file?

I am parsing a schematic file with the following structure The .schematic file format was created by the community to store sections of a Minecraft world for use with third-party programs. Schematics are in NBT format The Named Binary Tag (NBT)…
lancew
  • 780
  • 4
  • 22
11
votes
7 answers

How to control the mouse in Minecraft using Python?

All in all, I'm trying to programmatically -and externally- control the Minecraft player's orientation. No APIs, no Java mods to the game environment Typically this requires the movement of the mouse, but every single mouse movement simulating…
pizzafoot
  • 125
  • 1
  • 1
  • 8
11
votes
2 answers

Intellij IDEA Maven Import problems

I wanted to switch to IntelliJ for forge modding (minecraft). When I do what they are saying to do on internet, I get a maven error... Unindexed remote maven repositories found. Disable... The following repositories used in…
Etienne Poulin
  • 178
  • 1
  • 4
  • 15
10
votes
1 answer

God won't register a running custom service

I've got a rails website and a small minecraft server running on a linode vps. I'm running minecraft as a custom service off of a ram server based on an init.d file. Since I'm using God to monitor my rails website I thought I'd use it for minecraft…
chrisk
  • 235
  • 3
  • 6
10
votes
5 answers

How to create native binaries for your Java app?

I'm wondering how to package a Java application into a native binary for Windows, Linux and Mac OS X. I know Minecraft does this, but I can't figure out how. This is what'd I'd like to do: From NetBeans (preferably) or Eclipse, build the three…
Ariejan
  • 10,910
  • 6
  • 43
  • 40
10
votes
4 answers

Nginx proxy_pass to Minecraft server

I'm trying to run two Minecraft servers on the same machine on two different ports. I want to reference them based on subdomains: one.example.com -> :25500 two.example.com -> :25501 I have used nginx for things like this…
leeway
  • 485
  • 1
  • 3
  • 9
9
votes
3 answers

Large mutable byte array in Erlang

As I am writing a simple Minecraft server application in Erlang, I am now concerned with the question of how to efficiently store and modify chunk data. For those who don't know about Minecraft's internals: I need to store a lot of binaries…
clonejo
  • 821
  • 7
  • 15
9
votes
2 answers

AbstractMethodError on resultset.getObject

So I'm building a minecraft plugin, one part of the plugin grabs a bunch of block data from mysql and loads it into a cache when the server starts. I have a bit of code that runs fine in eclipse test cases. However when I load the plugin in a local…
zenril
  • 300
  • 2
  • 8
9
votes
1 answer

Sellable Menu Kit field changes when two or more references of the class are created (with GitHub)

I have been experiencing an odd bug in my Spigot/Bukkit plugin lately which totally does not make any sense. Please note that this question may be long due to the fact that the project I am working on is fairly big and since the source code…
Thanos Paravantis
  • 7,393
  • 3
  • 17
  • 24
8
votes
1 answer

How to change/assign process name of java .jar

I'm running Minecraft under Linux, which involves running an executable .jar file. This means it shows up as "java" under ps, rather than "minecraft". I would like to assign it the process name "minecraft". Looking around, I found the following tip…
emacsomancer
  • 597
  • 1
  • 5
  • 14
8
votes
1 answer

Camel case file name from artifactId for Maven archetype?

For a Maven archetype, how to camel case a generated file name using ${artifactId} in archetype-metadata.xml? For example, sample-my should give SampleMy.java. I supposed this is needed to be a velocity template but this require a macro to be…
Arun Gupta
  • 3,965
  • 5
  • 31
  • 39
8
votes
1 answer

C# ping minecraft

So found this little code snippet that would allow you to ping a Minecraft server in PHP, but now i want to do this in C#. I tried doing this on my own but for some reason its just not working UdpClient client = new UdpClient(); …
user2073973
  • 564
  • 6
  • 21
7
votes
3 answers

How do I edit .mca files from Minecraft?

Introduction I want to combine my separate Minecraft worlds into a single world and it seemed like a relatively easy feat, but as I did research it evolved into the need to make a custom program. The Struggle I started by shifting the region files…
Cakemate
  • 81
  • 1
  • 1
  • 6
7
votes
1 answer

How to use Minecraft's WorldEdit undo stack in a Bukkit mod

I am trying to update blocks in Minecraft within a Bukkit mod and be able to //undo those changes within Minecraft. I can change the block but I cannot //undo the change. I must be missing something simple since Google hasn't helped me find a…
Ian
  • 841
  • 5
  • 10