Skip to content

Instantly share code, notes, and snippets.

View meew0's full-sized avatar

meew0 meew0

View GitHub Profile
@meew0
meew0 / Lamp OBJ
Last active August 29, 2015 13:58
A simple ceiling lamp.
v 0.050000 0.500000 0.950000
v 0.050000 0.500000 0.050000
v 0.950000 0.500000 0.050000
v 0.950000 0.500000 0.950000
v 0.283214 0.628968 0.716787
v 0.283214 0.628968 0.283214
v 0.716787 0.628968 0.283214
v 0.716787 0.628968 0.716787
v 0.479089 0.636569 0.520911
v 0.479089 0.636569 0.479089
@meew0
meew0 / ee3-gems.obj
Created July 15, 2014 13:10
Armor Gem Editor for Equivalent Exchange 3
# Armor Gem Editor Block Model
# For Pahimar for EE3
# Made by meew0
# The armor could be put onto the grid, the magnifying-glass-arm could be used to look at the armor
# The compartment with the tools could also store gems
# Maybe the magnifying thing could also focus laser beams coming from the face on the top part
# Really, do whatever the hell you want with this
# It's not the most awesome model in the world, but it's decent I guess
@meew0
meew0 / chime.obj
Created July 18, 2014 16:19
Wind Chime for Fenn
# Wind Chime Model for Fenn
# Made by meew0
v -1.000000 -0.690173 1.000000
v -1.000000 -0.690173 -1.000000
v 1.000000 -0.690173 -1.000000
v 1.000000 -0.690173 1.000000
v -1.000000 -0.565173 1.000000
v -1.000000 -0.565173 -1.000000
v 1.000000 -0.565173 -1.000000
@meew0
meew0 / NEMCheck.rb
Last active August 29, 2015 14:05
NEM Update Checker
# NotEnoughMods Update Checker
# Made by meew0
#
# Requires Ruby
# http://ruby-lang.org/
#
# Download as NEMCheck.rb, go into a command prompt,
# navigate to the folder you downloaded it to and run
# ruby NEMCheck.rb
# Easy, right?
@meew0
meew0 / Main.java
Created November 14, 2014 22:12
Whittaker Words Lookup
package meew0.words;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
import org.jsoup.select.Elements;
public class Main {
public static void main(String[] args) {
if (args.length < 1) {
@meew0
meew0 / gist:5c3c6fc371d7cce03b46
Created November 16, 2015 19:29
Bot that links you to a youtube video when you first join a server
var Discord = require('discord.js');
var client = new Discord.Client();
// Handle discord.js warnings
client.on('warn', (m) => console.log('[warn]', m));
client.on('serverNewMember', (server, user) => {
var defChannel = server.defaultChannel;
defChannel.sendMessage(`${user.mention()}, https://www.youtube.com/watch?v=Za2PJnCAkUA`);
});
@meew0
meew0 / djs-voice-example.js
Created November 28, 2015 12:50
@hydrabolt's discord.js voice example which was used for testing during development. I slightly changed some things and added lots of comments. The original is since gone from the repo but it can still be found in the history: http://git.io/vBi9P
var Discord = require("discord.js");
// Make a client to add events to
var client = new Discord.Client();
var request = require("superagent");
// Debug and warning handlers, these log debug messages and warnings to console
client.on("debug", (m) => console.log("[debug]", m));
client.on("warn", (m) => console.log("[warn]", m));
@meew0
meew0 / pingpong.js
Created February 23, 2016 16:42
The ping pong example from discord.js, fixed up slightly
/*
this bot is a ping pong bot, and every time a message
beginning with "ping" is sent, it will reply with
"pong!".
*/
// Load discord.js
var Discord = require("discord.js");
// Create a client
@meew0
meew0 / 2.0.0.md
Created March 11, 2016 14:09
discordrb 2.0.0 planned changes

Definite changes

  • Users will be divided into User and Member classes, where User represents a global user and Member represents a user on a server. This is both cleaner and easier to do because Discord already separates these two things in the API.
  • WebSocket connections will be using a wrapper class instead of Faye/WSCS directly. This lets me switch both WSes to WSCS which doesn't rely on EventMachine (and if I'm dissatisfied with WSCS I can switch to something else entirely).
  • Caching code will be separated into a module and redone somewhat
  • Some stuff will be made more consistent, like server vs guild
  • The bot initializers will be restructured to only have an arguments hash that specifies everything
  • Removal of all the deprecated stuff

I will also support any changes to the API when they come out, like sharding.

module Elgyem::Agarify
extend ElgyemCommand
AGAR_ALPHABETS = [
# Exclude the boxed letters because they can look weird in Discord
# [9398, 9399, 9400, 9401, 9402, 9403, 9404, 9405, 9406, 9407, 9408, 9409, 9410, 9411, 9412, 9413, 9414, 9415, 9416, 9417, 9418, 9419, 9420, 9421, 9422, 9423],
# [9424, 9425, 9426, 9427, 9428, 9429, 9430, 9431, 9432, 9433, 9434, 9435, 9436, 9437, 9438, 9439, 9440, 9441, 9442, 9443, 9444, 9445, 9446, 9447, 9448, 9449],
[945, 1074, 162, 8706, 1108, 402, 103, 1085, 953, 1504, 1082, 8467, 1084, 951, 963, 961, 113, 1103, 1109, 1090, 965, 957, 969, 967, 1091, 122],
[65313, 65314, 65315, 65316, 65317, 65318, 65319, 65320, 65321, 65322, 65323, 65324, 65325, 65326, 65327, 65328, 65329, 65330, 65331, 65332, 65333, 65334, 65335, 65336, 65337, 65338],
[65345, 65346, 65347, 65348, 65349, 65350, 65351, 65352, 65353, 65354, 65355, 65356, 65357, 65358, 65359, 65360, 65361, 65362, 65363, 65364, 65365, 65366, 65367, 65368, 65369, 65370],