Skip to content

Instantly share code, notes, and snippets.

View TortleWortle's full-sized avatar
💭
Making compilers cry.

Tortle TortleWortle

💭
Making compilers cry.
  • Netherlands
View GitHub Profile
using UnityEngine;
using System.Collections;
public class PlayerMovements : MonoBehaviour{
// Normal Movements Variables
public float walkSpeed = 5f;
private float currentSpeed;
private Rigidbody2D rb2d;
@TortleWortle
TortleWortle / useSyncedState.js
Last active November 17, 2018 23:03
ReactJS Custom hook for syncing state between tabs and persist to localStorage.
import { useEffect, useState } from "react";
export const useStorageArea = storageArea => (key, initialValue) => {
const [item, setValue] = useState(
() => JSON.parse(storageArea.getItem(key)) || initialValue
);
const updateFromEvent = e => {
if (e.key === key && e.storageArea === storageArea) {
setValue(JSON.parse(e.newValue));
@TortleWortle
TortleWortle / Example Sudokus
Created September 22, 2019 15:02
Spaghetti Regretti
Exercise example = `9...7.... 2...9..53 .6..124.. 84...1.9. 5.....8.. .31..4... ..37..68. .9..5.741 47.......`
Web example = `8.5.92.6. 916..5... 74.16..35 2...461.. 18952.... 5..9.382. 6.8.....3 3.......4 .2..51698`
Breaker example (WILL TAKE 10 MINUTES) = `......... .....3.85 ..1.2.... ...5.7... ..4...1.. .9....... 5......73 ..2.1.... ....4...9`

Keybase proof

I hereby claim:

  • I am tortlewortle on github.
  • I am tortlewortle (https://keybase.io/tortlewortle) on keybase.
  • I have a public key ASDO557wqxACOzwaqtMirCxJwh78NOuM9Rc0y1Yr2ZozTgo

To claim this, I am signing this object: