Skip to content

Instantly share code, notes, and snippets.

View chyyran's full-sized avatar
💮
大変よくできました!

Ronny Chan chyyran

💮
大変よくできました!
View GitHub Profile
@chyyran
chyyran / get_icon.py
Created November 5, 2013 06:14
Gets the 16x16 icon from an EXE and returns a PIL.Image object
def get_icon(exe):
ico_x = win32api.GetSystemMetrics(win32con.SM_CXICON)
ico_y = win32api.GetSystemMetrics(win32con.SM_CYICON)
large, small = win32gui.ExtractIconEx(exe, 0)
if len(small) == 0:
return False
win32gui.DestroyIcon(large[0])
hdc = win32ui.CreateDCFromHandle(win32gui.GetDC(0))
icon_bmp = win32ui.CreateBitmap()
icon_bmp.CreateCompatibleBitmap(hdc, ico_x, ico_y)
#header{
display: none;
}
#headnavcontainer{
display: none;
}
#sidebar {
display: none !important;
}
#footer {
using UnityEngine;
using System.Collections;
public class NewBehaviourScript : MonoBehaviour {
private Texture2D myGUITexture; //This Texture2D is a member of NewBehavviourScript
//private means that myGUITexture can only be accessed from the NewBehaviourScript class
void Start(){
this.myGUITexture = (Texture2D)Pong.Textures.Load("map1.jpg");
<link rel="import" href="../paper-tabs/paper-tabs.html">
<link rel="import" href="../paper-tabs/paper-tab.html">
<polymer-element name="materia-mainmenu">
<template>
<style>
:host {
position: absolute;
width: 100%;
@chyyran
chyyran / display.html
Created October 26, 2014 02:18
Parse japanese class vocab from list to html table
<html>
<head>
<meta charset="UTF-8">
<script src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<script>
var vocab = [["さよおなら", "sayoonara", "goodbye"], ["ボオルペン", "boorupen", "ballpoint pen"], ["にほんご", "nihongo", "japanese"], ["カナダ", "kanada", "Canada"], ["カナダ", "chuugaku", "junior high school"], ["ちち", "chichi", "my father"]];
$( document ).ready(function() {
$.each(vocab, function(index, value) {
var row = $("<tr>");
row.appendTo($("#table"));
@chyyran
chyyran / gist:27644bcefdadff26d141
Created November 14, 2014 04:13
Dolphin Mappings
SIDevice Number Device Name
0 Nothing
5 Game Boy Advanced
6 Standard Controller
8 Steering Wheel
9 Dance Mat
10 TaruKonga (Bongos)

|Gamecube Slot Number|Device Name|

main: "retroarch.exe"
id: "retroarch"
name: "RetroArch"
type: "EMULATOR_EXECUTABLE"
restify = require "restify"
githubApi = require "github"
http = require "http"
fs = require "fs"
request = require "request"
AdmZip = require "adm-zip"
{LocalStorage} = require "node-localstorage"
whitelistStorage = new LocalStorage "./whitelist"
packageDetailsStorage = new LocalStorage "./details"
packageReleaseStorage = new LocalStorage "./releases"
A chat representative will be with you in about 0 minute(s). Thank you for waiting.
Bell Representative has joined the session and is ready to help. To start, please provide your name and home phone number.
Bell Representative: Hello, thanks for visiting bell.ca. How can I help you today?
Customer: I was wondering about the cost of some TV packages
Bell Representative: Sure, I can help you with that.
Bell Representative: Do you have any Bell services at present?
Customer: No, I don't
Bell Representative: I welcome you to Bell!
Bell Representative: May I have your address to verify the availability of Bell services in your area?
Bell Representative: (Street number, Street name, Apt/suite, City, Province and Postal code)
@chyyran
chyyran / Dreamcast IP.bin finder.cs
Created September 30, 2015 00:58
Finds an IP.bin from a dreamcast ISO or CDI file.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.IO;