Skip to content

Instantly share code, notes, and snippets.

View Ratstail91's full-sized avatar

Kayne Ruse Ratstail91

View GitHub Profile
const fetch = require('node-fetch');
const fs = require('fs');
const nameExceptions = ['ho-oh', 'porygon-z', 'jangmo-o', 'hakamo-o', 'kommo-o', 'mr-mime', 'mime-jr', 'type-null', 'tapu-lele', 'tapu-fini', 'tapu-koko', 'tapu-bulu'];
const collection = {};
(async () => {
const result = fetch('https://pokeapi.co/api/v2/pokemon?limit=100000')
.then(res => res.text())
.then(blob => JSON.parse(blob).results)
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class AudioManager : MonoBehaviour {
//singleton
static AudioManager instance = null;
//internals
@Ratstail91
Ratstail91 / GDD.md
Last active August 27, 2020 19:08
The GDD for Chemistry

Chemistry

Preamble

When creating our first game, Candy Raid: The Factory, we kept it deliberately simple since it was out first game. It was linear, straight forward and mechanically simple.

Chemistry (working title) instead takes the opposite approach - it is complex and multilayered, with many secrets and hidden game elements; that's the goal at least. This game design document is intended to outline a plan for ourselves, so that we're not blindly groping in the darkness.

The game is heavily inspired by the games The Legend of Zelda (1986), The Legend of Zelda: Breath of the Wild (2017), and the anime Made in Abyss (2017).

@Ratstail91
Ratstail91 / toy_reference.md
Last active August 12, 2020 15:08
Toy Language Version 0.4.0

Toy Language

Version 0.4.0

Welcome to the reference for the Toy programming language!

I'm still developing this language and discovering all of it's incedental nooks and crannys, but hopefully the core of the language is solid enough that I can begin to teach people to use it. This guide on how to use the language will also double as the official documentation for the time being.

If you're familiar with JavaScript, you will see a lot of similarities. However, there are also differences that I hope will make my language stand out in time. I don't expect it to reach JavaScript's popularity, but I would like it to be useful.

@Ratstail91
Ratstail91 / InputLayer.cs
Created June 24, 2020 20:26
I hope the boss doesn't mind me sharing this file... wait, I am the boss!
using System;
using UnityEngine;
//DOCS: INPUT_KEYBOARD falls back to the legacy unity input system
//TODO: nintendo switch controls
public static class InputLayer {
//virtual inputs for Candy Raid
public enum Button {
ATTACK, SWITCH, PAUSE
//10x programmers (this shitpost took a fucking hour, wtf):
const rl = require('readline').createInterface({
input: process.stdin, output: process.stdout
});
let table = {};
const q = (prompt, key) => () => new Promise(res => rl.question(prompt, answer => res(Object.assign(table, { [key]: answer })) ));
Promise.resolve()
.then(q('what is your name?', 'name'))
@Ratstail91
Ratstail91 / Untitled Card Game.md
Last active May 27, 2020 22:32
Rules for a legacy card game in progress.
@Ratstail91
Ratstail91 / example.jsx
Created May 6, 2020 09:09
I didn't run this, but it should be mostly correct.
import React from 'react';
import ReactDOM from 'react-dom';
class ExampleClass extends React.Component {
constructor(props) {
super(props);
this.state = {
isClicked: false;
};
}
using System;
public static class Calendar {
public enum Month {
JANUARY = 1, FEBRUARY, MARCH, APRIL, MAY, JUNE, JULY, AUGUST, SEPTEMBER, OCTOBER, NOVEMBER, DECEMBER
}
public enum EventType {
NONE,
CHRISTMAS,
using System;
//using UnityEngine;
public static class TimeManager {
//constants for reuse below
public const int FULL_DAY_LENGTH = 1440;
public const int HORDE_NIGHT_FREQUENCY = 7;
//these can be controlled by an external calendar script
public static int sunrise = 240;