Skip to content

Instantly share code, notes, and snippets.

TerrorBite

Block or report user

Report or block TerrorBite

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@TerrorBite
TerrorBite / asciicast.json
Created Jun 16, 2017
Test asciicast, recording TerrorBite/textgame in action.
View asciicast.json
{
"command": "ssh -p 8822 admin@localhost",
"stdout": [
[
0.055014,
"admin@localhost's password: "
],
[
2.633539,
"\r\n"
@TerrorBite
TerrorBite / asciiplayer.py
Last active Jun 16, 2017
Asciinema record-to-disk and playback-from-disk Python programs. Useful with asciinema v0.9.8 that doesn't have these functions natively.
View asciiplayer.py
#!/usr/bin/env python3
from sys import stdout, argv
import pickle
from time import sleep
with open(argv[1], 'rb') as f:
asciicast = pickle.load(f)
pos = 0
timing = asciicast.stdout.timing.split(b'\n')
View start.sh
java_opts="$java_opts -XX:MaxGCPauseMillis=50"
# Disable explicit GC. Some plugins may think it's a good idea to manually run the garbage collector.
# This is never a good idea with our setup, as it introduces a pause that is usually completely avoidable.
java_opts="$java_opts -XX:+DisableExplicitGC"
### OPTIMIZATION SETTINGS ###
# Bukkit and Spigot synchronize things for thread safety. Some of these synchronizations are never contested under ideal conditions.
View place_save_button_reddit.tamper.js
// ==UserScript==
// @name Place Save Button
// @namespace http://tampermonkey.net/
// @version 1.0
// @description Adds a save button to /r/place.
// @supportURL https://www.reddit.com/message/compose/?to=TerrorBite
// @author /u/TerrorBite
// @match https://*.reddit.com/place
// @match https://*.reddit.com/place?*
// @match https://*.reddit.com/r/place/
@TerrorBite
TerrorBite / gw2.py
Created Dec 15, 2016
This file was a work in progress
View gw2.py
import struct
import crc32c
import errno
import gw2util
# Headers
gw2_header1 = struct.Struct("<B3sIII")
gw2_header2 = struct.Struct("<IIQII")
# GW1 header
View chat_pb2.py
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: chat.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _reflection
from google.protobuf import symbol_database as _symbol_database
from google.protobuf import descriptor_pb2
View gw2bosses.csv
Start End Event Name Waypoint Link
07:00 07:15 Tequatl the Sunless [&BNABAAA=]
11:30 11:45 Tequatl the Sunless [&BNABAAA=]
16:00 16:15 Tequatl the Sunless [&BNABAAA=]
19:00 19:15 Tequatl the Sunless [&BNABAAA=]
00:00 00:15 Tequatl the Sunless [&BNABAAA=]
03:00 03:15 Tequatl the Sunless [&BNABAAA=]
08:00 08:15 Evolv. Jungle Wurm [&BKoBAAA=]
12:30 12:45 Evolv. Jungle Wurm [&BKoBAAA=]
17:00 17:15 Evolv. Jungle Wurm [&BKoBAAA=]
@TerrorBite
TerrorBite / build.sh
Created Feb 26, 2016
Framebuffer rendering thing
View build.sh
#!/bin/sh
gcc -std=gnu99 -o fbtoy main.c framebuffer.c draw.c -lm -g
View pistoncontroller_v2.cs
/* Piston Controller script for Space Engineers - by TerrorBite */
const float TOLERANCE = 0.08F;
string status = "";
Dictionary<string, string> Properties;
void LoadProperties() {
Properties = new Dictionary<string, string>();
if(string.IsNullOrEmpty(Storage)) return;
string[] records = Storage.Split('\x1E');
View pistoncontroller.cs
/*
Piston Elevator Controller
A Space Engineers script by TerrorBite
(Not just for elevators! Can be used any time that you want a piston to move to a
certain preset length and then turn off.)
WARNING: You may experience some lag while the piston is moving (especially after running
the game for a long time). This is unavoidable and is a result of the Program Block being
run repeatedly and rapidly by a Timer Block in order to monitor the piston. I have taken
You can’t perform that action at this time.