Skip to content

Instantly share code, notes, and snippets.

@Omochin
Omochin / split_names.py
Last active December 13, 2017 04:08
ファイルを読み込み複数のファイルの分割して保存する
LIST_LENGTH = 3
EXPORT_FILE_NAME = 'export.txt'
with open(EXPORT_FILE_NAME) as fout:
names = fout.readlines()
name_list = []
for i in range(0, LIST_LENGTH):
name_list.append([])
#include <string>
#include <unordered_map>
#include <memory>
#include <iostream>
#include <conio.h>
class BaseScene;
class ApplicationSingleton
{
@Omochin
Omochin / Group photo at Oijanen.txt
Created April 24, 2017 18:07
This is a group photo of the battle where Vendetta was destroyed at Oijanen on April 17, 2017.
https://gyazo.com/b7569e40e2efd947328da03051ea05cc
This is a group photo of the battle where Vendetta was destroyed at Oijanen on April 17, 2017.
https://zkillboard.com/related/30000186/201704172000/
- Members on the photo -
[-000-] xkamox
[-10.0] LEROYBARRELROLL
[-10.0] Perry Swift
[-10.0] Riffsajet
[-ASA-] Freyjia Aryana
@Omochin
Omochin / Group photo at Lantorn.txt
Created April 24, 2017 18:06
This group photo arranged "Shadow Cartel" and "Did he say Jump" from "related" of zKillboard.
https://gyazo.com/c9800dce21734aadfff893c821922161
This group photo arranged "Shadow Cartel" and "Did he say Jump" from "related" of zKillboard.
https://zkillboard.com/related/30002540/201704220000/
- Members on the photo -
[SHDWC] thearrowofapollo
[JMP-N] Predator Elite
[SHDWC] Adam Fynch Orlenard
[SHDWC] Admrial Ferret
[SHDWC] AshenShugar01
@Omochin
Omochin / zkillboard_related_image_generator.py
Last active April 24, 2017 17:40
This script creates a group photo of players listed in "related" of zKillboard.
@Omochin
Omochin / eveonline_portraits_crawler.py
Last active April 17, 2017 05:35
EVE OnlineのCharacter IDを列挙したカプセラの画像を取得する。pipでrequestsを入れる。
import requests
import json
import os
IMAGES_PATH = './images'
character_ids = [
'',
]
@Omochin
Omochin / hyphen2space.py
Created April 17, 2017 05:23
'-'を' 'に変換
import os
import shutil
for filename in os.listdir('import'):
output_name = ' '.join(filename.split('-'))
print(output_name)
shutil.copy('import/' + filename, 'export')
@Omochin
Omochin / config.py
Last active April 12, 2017 09:39
今のMod構成から遅延が発生しなくなるまでModを減らすスクリプト
MINECRAFT_PATH = 'C:\\works\\data\\Minecraft Server'
ANALYZER_MODS_DIRECTORY = 'analyzer_mods'
OVERLOADED_MODS_DIRECTORY = 'overloaded_mods'
LAUNCH_COMMAND = \
'java -client -Xmx3G -Xms3G -XX:+UseParallelGC -XX:+UseParallelOldGC ' \
'-jar forge-1.7.10-10.13.4.1614-1.7.10-universal.jar nogui'
@Omochin
Omochin / config.py
Created March 24, 2017 06:05
IntelliSenseが効きそうなConfigクラス
import random
import yaml
class Config:
@classmethod
def register(cls, key):
return property(
lambda self: self.yaml[key],
lambda self, value: self.save(key, value),
)
Base = sqlalchemy.ext.declarative.declarative_base()
class Information(Base):
__tablename__ = 'information'
id = sqlalchemy.Column(sqlalchemy.Integer, primary_key=True)
lcid = sqlalchemy.Column(sqlalchemy.String)
name = sqlalchemy.Column(sqlalchemy.String)
class CategoryID(Base):
__tablename__ = 'categoryIDs'