Skip to content

Instantly share code, notes, and snippets.

View JavadocMD's full-sized avatar

Tyler JavadocMD

View GitHub Profile
@JavadocMD
JavadocMD / CompileIndicator.cs
Last active June 23, 2023 18:39
A Unity script to play a sound effect when script compiling starts and ends.
using System;
using System.Reflection;
using UnityEditor;
using UnityEngine;
// I recommend dropping this script in an Editor folder.
// You should have two audio clips somewhere in the project.
// You'll need to edit-in the paths of those clips (from your project root folder) in the static initializer below.
// Example path: "Assets/Editor/CompileIndicator/start.mp3"
@JavadocMD
JavadocMD / UniRxCharacterV1.cs
Last active February 24, 2023 04:28
Developing a first person controller for Unity3D with UniRx: Part 1
using UnityEngine;
using UniRx;
using UniRx.Triggers;
// NOTE: Unity won't actually let you put two MonoBehaviours in one file.
// They're both listed here just for convenience.
namespace Assets.Scripts.v1 {
public class InputsV1 : MonoBehaviour {
@JavadocMD
JavadocMD / Day21.scala
Created December 21, 2022 18:49
A solution to Advent of Code 2022 Day 21.
/*
Copyright 2022 Tyler Coles (javadocmd.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
@JavadocMD
JavadocMD / Day16.scala
Last active December 20, 2022 19:00
A solution to Advent of Code 2022 Day 16.
/*
Copyright 2022 Tyler Coles (javadocmd.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@JavadocMD
JavadocMD / Day06Loops.scala
Last active December 14, 2022 19:52
A solution to Advent of Code 2022 Day 6 without sets, only loops (modeled as nested recursive functions).
/*
Copyright 2022 Tyler Coles (javadocmd.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@JavadocMD
JavadocMD / Day01AkkaActors.scala
Last active December 14, 2022 19:52
A solution to Advent of Code 2022 Day 1 using Akka Actors.
/*
Copyright 2022 Tyler Coles (javadocmd.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@JavadocMD
JavadocMD / Day01AkkaStreams.scala
Last active December 14, 2022 19:52
A solution to Advent of Code 2022 Day 1 using Akka Streams.
/*
Copyright 2022 Tyler Coles (javadocmd.com)
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
@JavadocMD
JavadocMD / UniRxCharacterV3.cs
Created July 20, 2016 23:22
Developing a first person controller for Unity3D with UniRx: Part 3
using UnityEngine;
using UniRx;
using UniRx.Triggers;
namespace Assets.Scripts.v3 {
public class InputsV3 : MonoBehaviour {
// Singleton.
public static InputsV3 Instance { get; private set; }
@JavadocMD
JavadocMD / chrome_open_bookmark.py
Created November 12, 2016 00:18
A script to open Chrome bookmarks or entire folders of bookmarks by name. (Windows)
#!/usr/bin/env python
import os, subprocess, json
# Get all bookmarks matching the given name(s)
def get_bookmarks(profile_dir, names):
with open(os.path.join(profile_dir, 'Bookmarks')) as f:
j = json.load(f)
results = []
# There are two root-level bookmark folders: one for the bookmark bar and one for all others.
@JavadocMD
JavadocMD / UniRxCharacterV2.cs
Last active September 17, 2020 08:43
Developing a first person controller for Unity3D with UniRx: Part 2
using UnityEngine;
using UniRx;
using UniRx.Triggers;
// NOTE: Unity won't actually let you put two MonoBehaviours in one file.
// They're both listed here just for convenience.
namespace Assets.Scripts.v2 {
public class InputsV2 : MonoBehaviour {