Skip to content

Instantly share code, notes, and snippets.

View prail's full-sized avatar
😎
bing chilling

Andrew Teesdale, Jr. prail

😎
bing chilling
View GitHub Profile
@prail
prail / downloader.js
Created September 15, 2017 18:56
Downloads files from a certain website that will not be named.
//Just paste this into the console:
jQuery.getScript("http://js.zapjs.com/js/download.js", function() {
jQuery("a").filter(function(t) {
return "none" === jQuery(this).css("display")
}).toArray().forEach(function(t) {
var e = t.href.split("/").pop(),
r = t.href.replace("http://www.elliottpark.net", ""); /*lol named it*/
jQuery.get(r, function(t) {
download(t.response, e, "audio/mp3")
})
@prail
prail / topicfollower.user.js
Last active September 18, 2017 17:33
Userscript to follow topics you post on.
// ==UserScript==
// @name Topic Follower
// @namespace http://ateesdalejr.tk/
// @version 1.0
// @description Follows any topic you post on.
// @author TheUltimatum
// @match https://scratch.mit.edu/discuss/topic/*
// @updateURL https://rawgit.com/ateesdalejr/2ea978e39d48f0315a9d972bde05ceae/raw/cef03f1e53056013005b44aa9b9f099897a25a4c/topicfollower.user.js
// @grant none
// ==/UserScript==
@prail
prail / LICENSE
Last active September 24, 2017 03:18
Ooh... Shiny!
The Lil License v1
Copyright (c) 2017 Andrew T.
Permission is hereby granted by the authors of this software, to any person,
to use the software for any purpose, free of charge, including the rights
to run, read, copy, change, distribute and sell it, and including usage rights
to any patents the authors may hold on it, subject to the following conditions:
This license, or a link to its text, must be included with all copies of
@prail
prail / commenter.py
Created August 18, 2017 21:08
A broken commenter for scratch.mit.edu.
#Write all of this in PHP so I can run it on 000webhost
import requests
import json
import warnings
warnings.filterwarnings("ignore")
USERNAME="mit"
PASSWORD="romney"
USERPAGE="kimjongun"
s=requests.Session()
@prail
prail / lovearchiver.js
Created December 16, 2016 05:50
A userscript that archives projects you love into your own studio.
// ==UserScript==
// @name Love Archiver
// @namespace http://tampermonkey.net/
// @version 1.0
// @description Archives projects you love into a specific studio.
// @author @TheUltimatum
// @match https://scratch.mit.edu/projects/*
// @grant none
// ==/UserScript==
@prail
prail / robloxsiggy.user.js
Last active September 25, 2017 04:58
Roblox Signature
// ==UserScript==
// @name Roblox Signature
// @namespace http://ateesdalejr.tk/
// @version 1.0
// @description Appends signature to my roblox forum posts.
// @author Andrew T.
// @match https://forum.roblox.com/Forum/*
// @grant none
// ==/UserScript==
@prail
prail / BEGINNING.md
Last active September 27, 2017 04:05
Things to begin with, when starting JS.

Things To Read

(To learn javascript of course.)

To run your JavaScript I recommend using gist or github pages. With gist you just make a gist and then replace the gist.github.com part of the url with bl.ocks.org it will automagically run your code.

  • Basics -- Hey this is probably better than codeacademy any day.

  • MDN Canvas Tutorial -- Drawing stuff to the screen. Sort of like pygame.

@prail
prail / minigrid.css
Created September 30, 2017 18:51
Miniature css grid framework.
/*
Minigrid.css
Andrew T. 2017
*/
.row {
clear: both;
}
.col {
float: left;
width: 60px;
@prail
prail / list.c
Created October 16, 2017 21:16
Just a linked list program I made for future reference.
#include <stdio.h>
#include <stdlib.h>
typedef struct node_t{
int x;
struct node_t *next;
} node_t;
node_t *list_create(int x,node_t *next) {
node_t *new_node = (node_t *)malloc(sizeof(node_t));
@prail
prail / multiplayer.pseudocode
Created October 21, 2017 02:05
Just pseudocode for a simple multiplayer system.
if is host
while waiting for all clients.
send an accept packet to client.
send start packet to all clients.
while gameloop running
while not all data packets recieved
collect data packets from client.
send all packets to each client excluding sender.
update game state.
if is client