Skip to content

Instantly share code, notes, and snippets.

@ase34
ase34 / enable-1_7_R4-only.patch
Last active October 26, 2016 16:18
flyingblocksapi building instructions
diff --git a/plugin/pom.xml b/plugin/pom.xml
index fd10ce9..05146db 100644
--- a/plugin/pom.xml
+++ b/plugin/pom.xml
@@ -27,7 +27,7 @@
<optional>true</optional>
<scope>compile</scope>
</dependency>
- <dependency>
+ <!-- <dependency>
@ase34
ase34 / gist:36ca784eb9945ce59f08
Created April 30, 2014 15:54
whitepaper latex code
\documentclass[a4paper]{article}
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{hyperref}
\usepackage{color}
\usepackage{listings}
@ase34
ase34 / gist:9b05bcdac9f183968838
Last active August 29, 2015 14:00
drawable map code
/*
* See the whitepaper at https://docs.google.com/file/d/0B9Sf4F-ig8lPUlhOdHZ2ZGtzdnM
*/
package intersection;
import java.awt.Color;
import java.awt.Graphics2D;
import java.awt.image.BufferedImage;
import java.util.HashMap;
@ase34
ase34 / gist:11375298
Last active February 6, 2017 20:11
bukkit plane/line intersection
/*
* See the whitepaper at https://docs.google.com/file/d/0B9Sf4F-ig8lPUlhOdHZ2ZGtzdnM
*/
public static double determinant(double[][] matrix) {
return matrix[0][0] * matrix[1][1] * matrix[2][2] + matrix[0][1] * matrix[1][2] * matrix[2][0] + matrix[0][2] * matrix[1][0] * matrix[2][1] - matrix[0][2] * matrix[1][1] * matrix[2][0] - matrix[0][1] * matrix[1][0] * matrix[2][2] - matrix[0][0] * matrix[1][2] * matrix[2][1];
}
public static Vector getIntersection(Vector linePoint, Vector lineDirection, Vector planeOrigin, Vector planeXDirection, Vector planeYDirection) {
double[][] coefficients = {
{lineDirection.getX(), -planeXDirection.getX(), -planeYDirection.getX()},