Skip to content

Instantly share code, notes, and snippets.

View chfoo's full-sized avatar

Christopher Foo chfoo

View GitHub Profile
@chfoo
chfoo / heartgold.md
Created May 19, 2020 16:48
HeartGold VOD instructions

Get the list FLV files from here using the boardcast URL http://www.twitch.tv/twitchplayspokemon/b/531310020 and http://www.twitch.tv/twitchplayspokemon/b/531783169

For each of the FLV URL, check the Wayback Machine CDX API and get the timestamp and Base32- SHA1 digest. I.E.: Get https://web.archive.org/cdx/search/cdx?url=[FLV_URL_HERE] and get the 2nd and 6th column.

Download the FLV file using the associated timestamp using this URL pattern: https://web.archive.org/web/[TIMESTAMP]id_/[URL] where [TIMESTAMP] is the timestamp from the CDX and [URL] is the URL of the FLV file.

Verify that the FLV file is not corrupt or truncated by computing the SHA1 digest with the one from the CDX API. Do not skip this step because the download may be incomplete.

Each FLV file is usually 30 minutes long. 2 FLV files can make 1 hour long YouTube video, 20 FL

@chfoo
chfoo / randomized y alias.md
Last active August 11, 2018 20:21
Twitch Plays Pokemon Randomized Y Touchscreen Coordinate Alias

Unofficial, subject to changes, some aliases may not be enabled.

Alias Coordinate
move1 0,90
move2 319,90
move3 0,159
move4 160,140
reuse 0,239
@chfoo
chfoo / storm silver aliases.md
Last active April 16, 2018 05:51
Twitch Plays Pokemon Storm Silver Touchscreen Coordinate Aliases

Unofficial, subject to changes, some aliases may not be enabled.

Alias Coordinate Description
run 111,190 Presses the Run button during battle
switch 210,155 Presses the Pokemon button during battle
bag 4,190 Presses the Bag button during battle
move1 5,23 Presses Fight and Move 1 during battle
move2 252,78 ditto 2
move3 126,94 ditto 3
@chfoo
chfoo / haxe_lib_symlink.py
Last active August 28, 2017 02:06
Haxe Lib Symlink Script
@chfoo
chfoo / reddit_live_download.py
Last active February 8, 2016 06:12
Download Reddit Live Thread Post JSON
'''Download Reddit Live Thread Post JSON'''
# reddit_live_download.py
#
# This is free and unencumbered software released into the public domain.
#
# Anyone is free to copy, modify, publish, use, compile, sell, or
# distribute this software, either in source code form or as a compiled
# binary, for any purpose, commercial or non-commercial, and by any
# means.
#
@chfoo
chfoo / beam_chat.py
Created January 31, 2016 19:51
Simple Beam.pro chat script
import json
import datetime
import tornado.gen
import tornado.websocket
import tornado.ioloop
@tornado.gen.coroutine
def main():
@chfoo
chfoo / twitch_quick_reskin_userscript.js
Last active November 14, 2017 22:21
Twitch Quick Reskin Userscript
// ==UserScript==
// @name Twitch Quick Reskin
// @namespace https://gist.github.com/chfoo/28b26f8e760889408dea
// @version 1.1.4
// @description Make text and colors readable on dark theme on twitch.tv. You may need to tweak to your liking.
// @match http://www.twitch.tv/*
// @match http://go.twitch.tv/*
// @match http://twitch.tv/*
// @match https://www.twitch.tv/*
// @match https://twitch.tv/*
@chfoo
chfoo / fasnippet.js
Created April 15, 2015 03:35
Select the checkboxes on the session management page of a particular website
var nl = document.querySelectorAll('input[type="checkbox"]');
for (var i=100; i<nl.length; i++) {
nl.item(i).click();
}
http://www.cubcentral.org/pics/AlexReynard/
http://www.cubcentral.org/pics/AllesterE.Darkflame/
http://www.cubcentral.org/pics/AnanabMasterSemaj/
http://www.cubcentral.org/pics/AnthrotechCorp/
http://www.cubcentral.org/pics/Anubis/
http://www.cubcentral.org/pics/Azadeth/
http://www.cubcentral.org/pics/BARK/
http://www.cubcentral.org/pics/BenRaccoon/
http://www.cubcentral.org/pics/BlackdragonSama/
http://www.cubcentral.org/pics/Blackraven2/
http://8ch.net/ban1/
http://8ch.net/dprk/
http://8ch.net/artifacts/
http://8ch.net/beautiful/
http://8ch.net/racesim/
http://8ch.net/dsgfhgurtf/
http://8ch.net/tnr/
http://8ch.net/pique/
http://8ch.net/woooo/
http://8ch.net/cheesepizza/