Skip to content

Instantly share code, notes, and snippets.

#include <Keyboard.h>
int KEY_0='a';
int KEY_1='w';
int KEY_2='s';
int KEY_3='d';
int wasPressed[4] = {0,0,0,0};
void setup() {
@Alex4386
Alex4386 / ang.js
Last active January 12, 2019 10:12
var danalbabo = new XMLHttpRequest();
danalbabo.open("POST", "http://otmsg.kr/send.php");
danalbabo.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
danalbabo.addEventListener("load", function() {
console.log(danalbabo.response.match(/http:\/\/otmsg.kr\/read.php\?no\=([A-Za-z0-9]+)/gm)[0]);
});
danalbabo.send("message="+encodeURIComponent("NOPE SHIT"));
@Alex4386
Alex4386 / babyshark-localize.js
Created February 8, 2019 17:39
Automatic Localization of babyshark song by SmartStudy Inc. via window.navigator.language
/* Written for MintNetwork Yukari Cluster - 500 page handling */
const bs = document.getElementById('babyshark');
/* Localize babyshark */
function localize(langCode) {
const country = window.navigator.userLanguage || window.navigator.language;
let ytCode = "";
const lang = langCode || country.split('-')[0];
switch (lang) {
#define speakerOut 12
#define BASEFREQ 440
int sharp = 1;
int nope = 0;
int flat = -1;
void setup() {
Serial.begin(9600);
// put your setup code here, to run once:
@Alex4386
Alex4386 / curse-filter.yml
Created March 15, 2019 10:04
MintNetwork CursePurgePlus용 욕설 필터 시스템
# MintNetwork CursePurge+
#
# WubbaLubba Dub Dub!
#
# wanna go gensokyo - Alex4386
# 환상향 가고 싶다 - Alex4386
message: '&r&l[&4&l!&r&l]&r &c&l욕설필터&r에서 금지된 단어가 감지되었습니다! 오작동이라면 디스코드로 신고해 주세요!'
# 이거 싹다 정규표현식이예요
# 2dis-zS0
# by <authorName>
# Generated with Charc0al's cowsay file converter http://charc0al.github.io/cowsay-files/converter
# Editted to look better in bash terminal :)
$x = "\e[m "; #reset color
$t = "$thoughts ";
$a = "\e[48;5;255m ";
$b = "\e[48;5;160m ";
#include <stdio.h>
int main() {
for (int num = 2; num < 100000000 ; num++) {
bool isPrime = true;
for (int i = 2; i <= (num / 2); i++) {
if (num % i == 0) {
isPrime = false;
break;
}
@Alex4386
Alex4386 / .bash_profile
Created April 15, 2019 08:16
제가 쓰는 bash profile 입니다. 불만입니까 휴먼?
PATH=$PATH:/opt/metasploit-framework/bin
export PATH=$PATH:/opt/metasploit-framework/bin
export CLICOLOR=1
export LSCOLORS=ExgxfxhaCxegedHbHdhcgc
alias ㅣㄴ=ls
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
@Alex4386
Alex4386 / th17_revengr.md
Last active May 6, 2019 07:20
Touhou Project 17: Wild Beast and Weakest Creature Trial - Reverse Engineering and Internal Asset Analysis

EntryPoints

Game Real Entrypoint: 0x004604B0
Game Load Section: 0x0046053D (IDK)
0x0047B810 - ???????
0x0046057D - Game Window Creations
0x00461A80

0x75DA3D17

0x004864A0 - WBaWC Asset Load Section

@Alex4386
Alex4386 / nengoCheck.js
Last active November 16, 2023 05:13
a javascript getter of Japanese nengo system (which i kinda hate, PLEASE USE ISO 8601!!!)
const nengos = [{ "name":"reiwa", "baseYear":2019 }, {"name":"heisei", "baseYear":1989}];
// Could you guys just use ISO-8601? PLEASE?
function getNengo(date) {
// First, Convert to JST
const jpDate = new Date(date.setMinutes(date.getMinutes() + (date.getTimezoneOffset() - -540)));
// get Year and Months
let year = jpDate.getFullYear();