Skip to content

Instantly share code, notes, and snippets.

A. Matías Quezada amatiasq

View GitHub Profile
View test.ps1
choco install spotify slack steam greenshot nodejs docker-desktop vscode sublimetext3 notepadplusplus gitkraken visualstudio2017community octave blender magicavoxelviewer -y
View CSVReader.js
const fs = require('fs');
const { promisify } = require('util');
const fs_open = promisify(fs.open);
const fs_read = promisify(fs.read);
const fs_close = promisify(fs.close);
let debug;
try {
debug = require('debug');
} catch(error) {
View Generes.md

Tower Defense

  • Building
    • Currency
    • Attacks
    • Waves

Shooter

  • Weapons
  • Bullets
  • Enemies
@amatiasq
amatiasq / pose.html
Last active Jun 16, 2018
Pose detection with Tensorflow
View pose.html
<!DOCTYPE html>
<html>
<head>
<title>Pose detection</title>
<script src="https://unpkg.com/@tensorflow/tfjs"></script>
<script src="https://unpkg.com/@tensorflow-models/posenet"></script>
<style>
#preview {
@amatiasq
amatiasq / quadtree.js
Created Apr 23, 2018
Work in progress...
View quadtree.js
const ArrayExtensions = {
remove(array, needle) {
const index = array.indexOf(needle);
if (index !== -1) {
array.splice(index, 1);
return index;
}
return false;
View output.txt
Vector created
Initialized Vector(0, 0)
Vector created
Initialized Vector(10, 10)
Rectangle created
Vector created
Initialized Vector(10, 10)
Initialized Rectangle(0, 0, 10, 10)
Disposed Rectangle(0, 0, 10, 10)
Disposed Vector(0, 0)
View copyright.js
@amatiasq
amatiasq / rif.sh
Created Jul 28, 2017
Run in folders
View rif.sh
#!/usr/bin/env bash
cmd=$@;
for i in $(ls)
do
if [ -d "$i" ]
then
echo "Entering ./$i"
cd "$i"
@amatiasq
amatiasq / stringify.js
Created Jul 18, 2017
A custom JSON stringifier
View stringify.js
function stringify(value, indent = '') {
const nextIndent = `${indent} `;
if (isNative(value))
return JSON.stringify(value);
if (Array.isArray(value)) {
if (value.length === 1 && isNative(value[0]))
return JSON.stringify(value);
View alias.ts
type myMethodSignature<T> = (value: T) => void;
class Test {
alias: myMethodSignature<T>;
constructor() {
this.alias = this.myMethod.bind(this);
}
myMethod<T>(value: T): void {}
You can’t perform that action at this time.