Skip to content

Instantly share code, notes, and snippets.

View justisr's full-sized avatar
💭
Processing

Justis R justisr

💭
Processing
  • BuiltByBit
  • United States
View GitHub Profile
@justisr
justisr / ActionBar.java
Last active August 7, 2016 13:49
Send messages to the player's action bar.
package com.justisroot.actionutil;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
public abstract class ActionBar {
public static Class<?> getNmsClass(String nmsClassName) throws ClassNotFoundException {
return Class.forName("net.minecraft.server." + Bukkit.getServer().getClass().getPackage().getName().replace(".", ",").split(",")[3] + "." + nmsClassName);
}
@justisr
justisr / JsonMessage.java
Last active July 27, 2021 13:32
Send json messages to a player.
//Created by Justis Root. Released into the public domain.
//https://gist.github.com/justisr/7a7449adac931a066c51/
//
//Source is licensed for any use, provided that this copyright notice is retained.
//Modifications not expressly accepted by the author should be noted in the license of any forks.
//No warranty for any purpose whatsoever is implied or expressed,
//and the author shall not be held liable for any losses, direct or indirect as a result of using this software.
import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
@justisr
justisr / Maze.java
Last active December 4, 2015 19:19
I don't even know what this is. :/ But I've got it.
public class Maze {
public static void main(String[] args){
int width = 100;
int height = 40;
Room[][] maze = new Maze().generateMaze(width, height);
for(int i = 0; i < width; i++){
System.out.print(" _");