Skip to content

Instantly share code, notes, and snippets.

View tayl0r's full-sized avatar

Taylor Steil tayl0r

View GitHub Profile
@tayl0r
tayl0r / redshiftexplainplan
Created June 26, 2014 20:22
redshift wtf explain plan
10 second query:
XN Merge (cost=1000000000000.07..1000000000000.07 rows=1 width=76)
-> XN Network (cost=1000000000000.07..1000000000000.07 rows=1 width=76)
-> XN Sort (cost=1000000000000.07..1000000000000.07 rows=1 width=76)
-> XN HashAggregate (cost=0.05..0.06 rows=1 width=76)
-> XN Subquery Scan volt_dt_0 (cost=0.04..0.05 rows=1 width=76)
-> XN HashAggregate (cost=0.04..0.04 rows=1 width=76)
-> XN Subquery Scan derived_table1 (cost=0.02..0.03 rows=1 width=76)
-> XN HashAggregate (cost=0.02..0.02 rows=1 width=44)
public GUIText[] m_numbers = new GUIText[100];
void Start() {
if (m_timer) {
for (int i = 0; i < 11; ++i) {
GUIText number = Instantiate(m_timer) as GUIText;
number.text = i.ToString();
number.enabled = false;
Debug.Log(i);
@tayl0r
tayl0r / gist:bd943708358abf64732f
Created December 31, 2014 14:46
Java 2048m Command Line Interceptor
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Diagnostics;
using System.IO;
namespace CommandlineInterceptor {
@tayl0r
tayl0r / gist:64d63e90b758036f9771
Last active August 29, 2015 14:11
notif tracking
#include "PluginBase/AppDelegateListener.h"
+ (void)load
{
// startup notification (local and remote)
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(FoxCubIosOnLoad:) name:UIApplicationDidFinishLaunchingNotification object:nil];
// resume notification (local)
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(FoxCubIosOnLocalNotif:) name:kUnityDidReceiveLocalNotification object:nil];
@tayl0r
tayl0r / gist:aef79937a11e10bf663e
Created December 11, 2014 19:09
get launch options
+ (void)load
{
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(applicationDidReceiveMemoryWarning:) name:UIApplicationDidReceiveMemoryWarningNotification object:nil];
// this one contains userInfo about our notification
//[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(FoxCubIosOnLoad:) name:UIApplicationDidFinishLaunchingNotification object:nil];
// these two do not contain any useful userInfo about notifications
//[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(FoxCubIosOnLoad:) name:UIApplicationDidBecomeActiveNotification object:nil];
//[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(FoxCubIosOnLoad:) name:UIApplicationWillEnterForegroundNotification object:nil];
@tayl0r
tayl0r / gist:959b1aebb871080fa6ae
Created December 8, 2014 15:02
FCSponsorPay.cs
#if !UNITY_EDITOR || FCLOG
using Debug = FC.Debug;
#else
using Debug = UnityEngine.Debug;
#endif
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
@tayl0r
tayl0r / gist:6e92540e6f28655ac639
Last active August 29, 2015 14:06
jsonfx reader for emoji
case 'u':
{
// Unicode escape sequence
// e.g. Copyright: "\u00A9"
// unicode ordinal
int utf16;
if (this.index+4 < this.SourceLength &&
Int32.TryParse(
this.Source.Substring(this.index+1, 4),
@tayl0r
tayl0r / gist:48d3ed2f916a91d1cc2c
Created September 11, 2014 22:02
jsonfx reader for emoji
case 'u':
{
// Unicode escape sequence
// e.g. Copyright: "\u00A9"
// unicode ordinal
int utf16;
if (this.index+4 < this.SourceLength &&
Int32.TryParse(
this.Source.Substring(this.index+1, 4),
@tayl0r
tayl0r / startUnity.bat
Created July 31, 2014 15:32
command line Unity startup of specific project
perl startUnity.pl