Questions tagged [minecraft]

Minecraft is a voxel-based sandbox game coded in Java by Mojang where players place and destroy blocks to gain armor, weapons and tools in a randomly generated world.

Filter by
Sorted by
Tagged with
0 votes
1 answer
46 views

Using a RegEx to create a UUID string

I'm writing a Discord bot that sometimes requires a Minecraft account UUID to be looked up so this is the function (and MWE) I have written to do this. ...
user avatar
  • 131
2 votes
0 answers
163 views

Minecraft Code That Gives Player God Like Abilities

Here's Some Context So I was messing around in Minecraft and decided to make some code that basically makes you god. While making the code and testing it I noticed there were some problems that I didn'...
user avatar
6 votes
1 answer
257 views

Base Class System for splitting a spigot command in subcommands

Related to this question: Spigot Plugin: Generic form of the plugin's main clas I've created a Clan-Plugin, in which I have one "main" command, which is simply ...
user avatar
  • 403
4 votes
2 answers
846 views

Find minecraft colour codes in string

I've written a simple util-method in my spigot plugin to check if a message contains a valid minecraft colour code. A valid minecraft colour code consists of a &...
user avatar
  • 403
4 votes
1 answer
127 views

Spigot Plugin: Generic form of the plugin's main class

I have created a lot of spigot plugins in my "career" as a developer for a bunch of Minecraft servers, but every time I start writing a new plugin, I basically "reinvent" the ...
user avatar
  • 403
2 votes
1 answer
199 views

SafeBlockPopulator to ensure neighboring chunks are generated before population

Bukkit/CraftBukkit/Spigot are Minecraft server extenders that allow for creating and using plugins. A particular type of plugin is a generator, which creates the game world. Generators operate chunk-...
user avatar
2 votes
1 answer
79 views

Refactoring coordinates for Minecraft Pi buildings written in Python

I'm fairly new to coding and I wrote this script in Python for a house with a roof in Minecraft Pi. I've found different ways to write the coordinates to make the code base shorter, but I'm wondering ...
user avatar
16 votes
2 answers
2k views

Minecraft block generator

This script is a tool to help minecraft mod development. When you want to add a new block to the game you have to create three json files. This script generates three JSON files in specific locations. ...
user avatar
  • 263
-2 votes
1 answer
217 views

Using Reflection to call multiple methods and cast various classes [closed]

I have written the following Reflection code: ...
user avatar
  • 107
1 vote
1 answer
101 views

Building a 64 × 64 particle accelerator frame in Minecraft with a computercraft turtle

I dont think this will work anywhere besides in minecraft with computercraft but it's all correct syntax. I just feel like it has some lines of code I could eliminated somehow and made it a cleaner ...
user avatar
  • 13
1 vote
2 answers
702 views

Minecraft resource calculator

I'm writing a basic program that calculates the total base resources needed to craft items in Minecraft. It's intended to be modular for support for modded versions of Minecraft (new items or ...
user avatar
6 votes
1 answer
459 views

Library for RCON clients

I wrote a library implementing the RCON protocol to automate interaction with Minecraft servers. I know that there are already a couple of implementations out there, but neither I found was convincing ...
user avatar
2 votes
0 answers
99 views

Purely functional minecraft-like mesh compiler

I'm creating a minecraft clone (for practice), in scala, using largely functional programming. When a chunk doesn't have a mesh loaded into VRAM, it create a Future for the vertex and index arrays, ...
user avatar
  • 267
1 vote
0 answers
160 views

Spigot plugin protecting servers against bots

I wrote two plugins with the Spigot-API. It would be very nice if you could give me any advice so I can improve my code. https://github.com/ReflexArtZ/NoBots LOC: ~ 800-1000 Main: ...
user avatar
  • 11
4 votes
2 answers
138 views

Registering various kinds of blocks in Minecraft

After looking at a few tutorials on making minecraft mods i got as far as making my own blocks and the ModBlocks class to me looks awful and unruly especially when ...
user avatar
3 votes
2 answers
148 views

Minecraft server querier that generates an image of online players

This little chunk of code is run every 10 seconds on my desktop. It generates a PNG with up to 6 player faces based on the list of online players. Is there any way for this code to execute faster? ...
user avatar
2 votes
1 answer
538 views

Using HikariCP and JDBC to store data for a Minecraft plugin

I'm creating a plugin for the game Minecraft, and with it I'm using HikariCP and MySQL to store data between server restarts. I've created working code but I'm wanting to improve it. While the code ...
user avatar
4 votes
1 answer
300 views

Vanisher plugin for Minecraft (Written with the Bukkit API)

Would this code for my Vanisher plugin for the game Minecraft, written with the Bukkit API, be optimised and conventionally right? VanishAPI: ...
user avatar
2 votes
1 answer
144 views

Java MySQL handler for a Minecraft mod

I am studying computer science and recently I developed an application in Java (it is a minecraft mod) that connects a MySQL database and queries to fetch, update or insert data. My DatabaseHandler ...
user avatar
  • 39
3 votes
1 answer
272 views

Bukkit API Town plugin for Minecraft

I'm creating a town plugin for the game Minecraft using the Bukkit API. It works fine and all, however I'm not satisfied with the quality of the code and I'd like to know how I can improve. I've been ...
user avatar
1 vote
1 answer
177 views

Documentation for a Minecraft server plugin

I'm working on a minecraft plugin for my Spigot Minecraft server. I have a class which works as expected. I've done my best to hammer every single bug out (famous last words, I know) and am now ...
user avatar
  • 175
3 votes
0 answers
603 views

Event-driven UDP listener wrapper

I wrote this wrapper around the UdpClient,using events for new datagrams: ...
user avatar
  • 191
6 votes
1 answer
254 views

Bukkit/Spigot plugin for Minecraft servers

I have created a Bukkit/Spigot plugin for Minecraft servers because I wanted to change the dynamic of mining to prevent people with really bright monitors or the Fullbright mod from being able to skip ...
user avatar
6 votes
2 answers
232 views

Efficiently return a ChatColor

I am working on a plugin for a Minecraft server. In it, I have a function that returns a ChatColor depending on what permission level you are. Whenever I need ...
user avatar
  • 175
4 votes
1 answer
75 views

Video frame to Minecraft map colors

I'm still somewhat new to C, so pardon me for any silly mistakes I've made. I'm trying to convert video frames into Minecraft map colors using JNI and ...
user avatar
  • 43
7 votes
1 answer
2k views

Builder - A 2D Minecraft clone

I was poking around on my Raspberry Pi that I hadn't turned on or used in a while, and I stumbled upon this Python script that I wrote ~1.5 years ago, and I was intrigued. Essentially, it's a 2D ...
user avatar
2 votes
3 answers
164 views

Personal Minecraft Android app

This won't be released publicly, but that doesn't mean I want to have bad coding habits. I was not too far into this before realizing I could make it better. One of my main concerns is finding an ...
user avatar
  • 191
6 votes
2 answers
166 views

Game object structure for Minecraft server

I'm trying to write a Minecraft server in Ruby as an educational project and I've hit the point now where I need to decide on how I am going to structure the in-game objects (entities). In my mind, an ...
user avatar
7 votes
1 answer
3k views

Minecraft query tools

This is my first major PHP project and I haven't gotten much feedback. I wanted to learn how to use PHP and I wanted to learn about Minecraft's status protocol, so I did what was obvious at the time. ...
user avatar
  • 283
3 votes
1 answer
239 views

Database schema for a Minecraft logging plugin

This is my attempt at creating a database schema for a Minecraft logging plugin. I'm by no means a SQL expert, so suggestions would be greatly appreciated. ...
user avatar
3 votes
2 answers
224 views

Meshing algorithm for generating faces in Minecraft

To generate faces of a Minecraft-like world from a three dimensional array, I developed the following meshing algorithm. The faces are given vertices and indices. A vertex consists of a position in ...
user avatar
  • 205
3 votes
1 answer
321 views

Minecraft auto-backup utility

I live in a country where an electricity blackout happens after every hour, which corrupts the Minecraft save files, so I came up with this auto backup utility which backs up the %appData%.minecraft\...
user avatar
2 votes
1 answer
946 views

Plugin for finding placed blocks and if they are in a certain sequence

This is for a plugin I am making for the game called Minecraft. The code is responsible for finding out the blocks placed by the player and if they are in the following sequence as shown in the ...
user avatar
  • 123
4 votes
3 answers
905 views

Optimizing lighting algorithm for a voxel engine

I am creating a Minecraft-like terrain engine in XNA to learn HLSL and more XNA. The problem is my lighting algorithm. Whenever a block which emits light is placed, it takes about half a second to ...
user avatar
  • 151