Skip to content

Instantly share code, notes, and snippets.

expantions = {
"CORE": "基本カード",
"EXPERT1": "クラシックカード",
"HOF": "栄誉の殿堂",
"NAXX": "ナクラーマスの呪い",
"GVG": "ゴブリンvsノーム",
"BRM": "ブラックロック・マウンテン",
"TGT": "グランド・トーナメント",
"LOE": "探検同盟",
"OG": "旧神のささやき",
#!/usr/bin/env python3
import os
import json
import requests
import base64
import click
from hearthstone.deckstrings import Deck
db_url = "https://api.hearthstonejson.com/v1/19506/jaJP/cards.collectible.json"
@trsqxyz
trsqxyz / hsd.py
Created June 3, 2017 05:06 — forked from Tenchi2xh/hsd.py
#!/usr/bin/env python2
import os
import json
import requests
import base64
import click
db_url = "https://api.hearthstonejson.com/v1/18336/enUS/cards.collectible.json"
db_path = "./db.json"
@trsqxyz
trsqxyz / HCIDJP.csv
Created June 3, 2017 04:15
Hearthstone Cards ID JP
7 ガロッシュ・ヘルスクリーム
8 精神支配
9 預言者ヴェレン
12 マナ中毒者
21 タル
22 内なる怒り
23 破滅に至る病
26 悪魔の火
28 コルクロンの精鋭
30 思念奪取
@trsqxyz
trsqxyz / hs.py
Last active August 9, 2017 04:08
from CARD.xml
# coding: utf-8
import os
import json
import requests
import csv
import re
import codecs
'''make a CSV file.
- set name
@trsqxyz
trsqxyz / colorize.diff
Last active June 22, 2016 13:55
colorize.diff
diff --git a/colorize.lua b/colorize.lua
index 060ef8b..dd65355 100644
--- a/colorize.lua
+++ b/colorize.lua
@@ -16,9 +16,11 @@
require 'nn'
require 'nngraph'
require 'image'
+require 'lfs'
REG QUERY HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall
import random
from mynumber import MyNumber
M = MyNumber()
mng = lambda x: int(''.join([str(random.randint(0,9)) for _ in range(x)]))
mns = set()
while len(mns) < 10:
mn = mng(12)
try:
if M.validate(mn):
# -*- coding: utf-8 -*-
from __future__ import absolute_import, unicode_literals, print_function
from collections import defaultdict
from contextlib import contextmanager
import random
_MIN_BASE = 10000000000
_MAX_BASE = 99999999999
@trsqxyz
trsqxyz / psw.py
Last active October 27, 2015 05:06
import random
import string
word = string.ascii_letters + string.digits
[random.choice([''.join([random.choice(words) for _ in range(8)]) for i in range(6)]) for i in range(3)]