This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.MixedReality.Toolkit; | |
using Microsoft.MixedReality.Toolkit.Input; | |
using UnityEngine; | |
/// <summary> | |
/// Creates a clone of this game object when the item is grabbed using near interaction | |
/// </summary> | |
public class CloneOnGrab : MonoBehaviour | |
{ | |
private void Start() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Refer to lines 22, 131, 168 and the Update() Method. | |
// Many thanks to @newske who posted a partial solution on stackoverflow: | |
// https://stackoverflow.com/questions/56846672/how-can-i-configure-mrtk-to-work-with-touch-input-in-editor-and-on-mobile-device?noredirect=1#comment100693647_56846672 | |
// Copyright (c) Microsoft Corporation. All rights reserved. | |
// Licensed under the MIT License. See LICENSE in the project root for license information. | |
using Microsoft.MixedReality.Toolkit.Utilities; | |
using UnityEngine; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
/// <summary> | |
/// Ensures that the position of this object relative to ObjectToFollow | |
/// remains the same, in the frame of reference of their first common ancestor | |
/// </summary> | |
public class MatchPosition : MonoBehaviour |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Examples: | |
# Get-ElapsedPrevious | |
# Get-ElapsedPrevious 5 | |
function Get-ElapsedPrevious($n=1) | |
{ | |
Get-History -Count $n | % { | |
$output = "{0} ({1} seconds)" -f $_.CommandLine, ($_.EndExecutionTime - $_.StartExecutionTime).TotalSeconds | |
Write-Host $output } | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#ifndef LOG_LEVEL | |
#define LOG_LEVEL 4 // 0 = nothing, 5 = verbose | |
#endif | |
#include <stdio.h> | |
#define _NOP do{}while(0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void Awake () { | |
StartCoroutine(Generate()); | |
} | |
private IEnumerator Generate () { | |
WaitForSeconds wait = new WaitForSeconds(0.05f); | |
yield return wait; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if Wscript.Arguments.Count = 0 then | |
Wscript.Echo "Usage: make-shortcut.vbs shortcutName shortcutWorkingDir shortcutPath shortcutArgs..." | |
Wscript.Quit | |
end if | |
Dim shortcutName | |
Dim shortcutPath | |
Dim shortcutWorkingDir | |
Dim shortcutArgs | |
shortcutName = Wscript.Arguments(0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,5.90659462491,5.11010646917,15.1383964388,46.4439719166,65.6996352717,92.0826135994,129.238576706,132.754602471,116.059569164,130.819523085,148.794375928,139.826428456,103.280910681,78.8457360134,58.3896637186,39.6551277396,22.3439999208,16.7573143782,1.76483130219,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Use ctrl + shift + 5 to select outlook | |
^+5:: | |
SetTitleMatchMode 2 | |
WinActivate Outlook | |
Return | |
; Use ctrl + shift + 5 to select sublime | |
^+6:: | |
SetTitleMatchMode 2 | |
WinActivate Sublime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (!DesignMode.DesignModeEnabled) | |
{ | |
... | |
} |