Skip to content

Instantly share code, notes, and snippets.

Coding Magic

Kristen ikriz

Coding Magic
View GitHub Profile
ikriz / Display.RelativeMouseAt.cs
Last active Oct 8, 2020 — forked from karljj1/Display.RelativeMouseAt.cs
Emulate multiple display input using GameViews
View Display.RelativeMouseAt.cs
Vector3 RelativeMouseAt()
var mouseOverWindow = EditorWindow.mouseOverWindow;
System.Reflection.Assembly assembly = typeof(UnityEditor.EditorWindow).Assembly;
Type type = assembly.GetType("UnityEditor.PlayModeView");
int displayID = 0;
if (type.IsInstanceOfType(mouseOverWindow))
var displayField = type.GetField("m_TargetDisplay"BindingFlags.NonPublic | BindingFlags.Instance);
View gist:5e36e9acf5eab77202156c85af9d61f5
description: list the releases and installed editors
alias: e
example: Unity\\ Hub -- --headless editors -r
[default] list of available releases and installed editors on your machine combined
--releases|-r only list of available releases promoted by Unity
--installed|-i only list of installed editors on your machine
View Run RTSP Media Server with VLC
cvlc /home/ullaakut/Downloads/dummy.jpg -I dummy \
--sout-keep --no-drop-late-frames --no-skip-frames \
--image-duration 9999 \
--sout="#transcode{vcodec=h264,fps=15,venc=x264{preset=ultrafast,tune=zerolatency,keyint=30,bframes=0,ref=1,level=30,profile=baseline,hrd=cbr,crf=20,ratetol=1.0,vbv-maxrate=1200,vbv-bufsize=1200,lookahead=0}}:rtp{sdp=rtsp://:8554/live.sdp}" \
View gist:332f51acdffd99d3a4775b025eda0033
# NMEA to GPX converter
# Peter Pearson
# version 0.11
import csv
import sys
import time
from time import strftime
def convert_dms_to_dec(value, dir):
ikriz /
Created Jun 30, 2017
Keybase Verification

Keybase proof

I hereby claim:

  • I am ikriz on github.
  • I am ikriz ( on keybase.
  • I have a public key ASD-KA1MidhC1bkpW8qeINNLO8wPLsdW2gBfLcVAvOz80Qo

To claim this, I am signing this object:

ikriz / EnableMacros.cs
Last active Aug 29, 2015
Unity 4.x Editor Macro's
View EnableMacros.cs
using UnityEditor;
using UnityEditorInternal;
public class EnableMacros : Editor {
[MenuItem ("Window/Macros")]
static void Init () {
MacroWindow win = (MacroWindow)EditorWindow.CreateInstance<MacroWindow>();
ikriz / EnumFlagAttribute.cs
Last active Feb 24, 2017 — forked from ChemiKhazi/EnumFlagAttribute.cs
Unity3d property drawer for automatically making enums flags into mask fields in the inspector.
View EnumFlagAttribute.cs
using UnityEngine;
public class EnumFlagAttribute : PropertyAttribute
public string enumName;
public EnumFlagAttribute() {}
public EnumFlagAttribute(string name)
View UnityDiffuseLightmap.shader
Shader "Diffuse Lightmap" {
Properties {
_MainTex ("Texture 1", 2D) = "white" {}
SubShader {
Tags { "RenderType" = "Opaque" }
Pass {
View PostBuildTrigger.cs
using System.IO;
using UnityEngine;
using UnityEditor;
using UnityEditor.Callbacks;
public static class PostBuildTrigger
private static DirectoryInfo targetdir;
private static string buildname;
private static string buildDataDir;
ikriz / Webcam.cs
Last active Jan 24, 2019
Webcam Script to display Webcam Textures []
View Webcam.cs
using UnityEngine;
public class Webcam : MonoBehaviour
public MeshRenderer[] UseWebcamTexture;
private WebCamTexture webcamTexture;
void Start()