Skip to content

Instantly share code, notes, and snippets.

@Lyrositor
Lyrositor / wiki_data.py
Created October 24, 2014 17:39
ATBP Wiki Data Script
#!/usr/bin/env python3
# Wiki Data
# Parses definition files for DB wiki data.
import json
import time
import traceback
import urllib.request
CHAMPION_ENTRY = """|{id} = {{{{#switch: {{{{lc:{{{{{{2}}}}}}}}}}
@Lyrositor
Lyrositor / ABTP_sfx_downloader.py
Last active August 29, 2015 14:07
Adventure Time Battle Party Sound Files Downloader
#!/usr/bin/env python3
import os
import urllib.request
import xml.etree.ElementTree as ET
ROOT_URL = "http://ht.cdn.turner.com/toon/big/champions/20140915/"
DEFINITIONS_URL = ROOT_URL + "definitions/{}.xml"
SOUNDS_URL = ROOT_URL + "assets/sounds/{}.ogg"
@Lyrositor
Lyrositor / gist:4296865
Created December 15, 2012 16:27
Earthbound Hacking 101 - Chapters
Introduction
I. CoilSnake
Chapter 1. Getting Started
Chapter 2. Your First Hack
Chapter 3. NPCs
Chapter 4. Playable Characters
Chapter 5. Doors, Ropes and Stairs
Chapter 6. PSI Abilities
Chapter 7. Teleportation
Chapter 8. Battle – Actions
@Lyrositor
Lyrositor / Traceback.py
Created December 13, 2012 17:37
CoilSnake Traceback
CoilSnake 1.1 (8/21/12)
From ROM : ../ROM.smc ( Earthbound )
To Project : ../Data ( Earthbound )
- Patches ... 100.00% (0.08s)
- CCScript ... 100.00% (0.00s)
- Skip Names ... 100.00% (0.00s)
- Map Sprites ... 100.00% (0.45s)
- Doors ... 100.00% (0.79s)
- Sprite Groups ... 100.00% (7.71s)
- Misc Tables ... 100.00% (1.12s)
@Lyrositor
Lyrositor / OmnibotVault.cpp
Created November 28, 2012 22:37
Omnibot Vault
/*
* Omnibot
*/
#ifndef VAULT_H
#define VAULT_H
#include <mutex>
#include <vector>
@Lyrositor
Lyrositor / CMakeLists.txt for plPageOptimizer
Created November 15, 2012 01:58
CMakeLists.txt for plPageOptimizer
include_directories("../../CoreLib")
include_directories("../../NucleusLib")
include_directories("../../NucleusLib/inc")
include_directories("../../PubUtilLib")
include_directories("../../PubUtilLib/inc")
include_directories("../../FeatureLib")
include_directories("../../FeatureLib/inc")
include_directories(${PYTHON_INCLUDE_DIR})
@Lyrositor
Lyrositor / Clone
Created November 3, 2012 01:11
Clone
def List(player="me"):
avatar = GetOneAvatar(player).avatar
returnList = list()
clothingList = avatar.getAvatarClothingList()
for item in clothingList:
theItem = dict()
theItem["name"] = item[0]
theItem["color"] = list()
theItem["morph"] = list()
@Lyrositor
Lyrositor / gist:3791705
Created September 27, 2012 01:44
Filter
def IFilterAgeName(self, ageName):
# Replace file names with display names - only once, from the right.
# This fixes a bug in which avatars' names containing words like Garden
# incorrectly get replaced.
for Age in kAges.Replace:
ageNameList = ageName.rsplit(Age, 1)
ageName = kAges.Replace.join(ageNameList)
# Find the appropriate display name.
@Lyrositor
Lyrositor / gist:3375338
Created August 17, 2012 02:11
KI Classes
KI:
content: the content displayed in the right section.
folders: the three major folders (and all their sub-folders).
level: the level of the KI.
list: the list displayed in the left section.
state: the current state of the KI (micro KI, big KI...).
variables: time, username, KI number...
KIFolder:
children: the folders or items in this folder (not a mix).