This file contains hidden or 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
| Sub InsertPicture() | |
| Dim iRange As Range | |
| Dim strMessage As String | |
| Dim x As Variant | |
| Dim filename As String | |
| Set iRange = ActiveCell | |
| Application.ScreenUpdating = False | |
| strMessage = Application.GetOpenFilename(filefilter:="picture(*.JPG;*.GIF;*.BMP;*.PNG),*.JPG;*.GIF;*.BMP;*.PNG", _ | |
| Title:="Select an image to insert into the selected cell.") | |
| If strMessage = "False" Then |
This file contains hidden or 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 UnityEngine; | |
| using System.Collections; | |
| using System.Collections.Generic; | |
| /// | |
| /// Add any IEnumerator function to the queue which to be executed in the Update() | |
| /// | |
| public class IEnumeratorSample : MonoBehaviour | |
| { | |
| Queue<IEnumerator> queue = new Queue<IEnumerator>(); |
This file contains hidden or 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
| /// <summary> | |
| /// Used to get assets of a certain type and file extension from entire project | |
| /// Usage: | |
| /// UnityEngine.Object[] pagePrefabs = GetAssetsOfType("Resources/Prefabs/PAGE", typeof(GameObject), ".prefab"); | |
| /// </summary> | |
| /// <param name="type">The type to retrieve. eg typeof(GameObject).</param> | |
| /// <param name="fileExtension">The file extention the type uses eg ".prefab".</param> | |
| /// <returns>An Object array of assets.</returns> | |
| public static UnityEngine.Object[] GetAssetsOfType(string path, System.Type type, string fileExtension) | |
| { |
This file contains hidden or 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
| >$files = Get-ChildItem -rec -Include *.MESH | ForEach-Object -Process ($_.FullName) | |
| >for( $i=0; $i -lt $files.Count; $i++) { | |
| > [command] $files[$i] | |
| >} | |
| > | |
| > | |
This file contains hidden or 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
| /// <summary> | |
| /// 주어진 배열에서 p와 가장 근사한 배열값의 인덱스를 리턴. | |
| /// </summary> | |
| public static int Near(float[] array, float p) | |
| { | |
| float tmp = 0f; | |
| float min = 100f; | |
| float near = 0f; | |
| int found = 0; | |
This file contains hidden or 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
| animTime = Mathf.Round(Animation[myBody.attack1].normalizedTime * 10)/10; | |
| if (animTime >= 0.5f) { | |
| //do something | |
| } |
This file contains hidden or 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
| public static class TransformHelper | |
| { | |
| public static Transform GetChild(this Transform self, string name) | |
| { | |
| Transform t = null; | |
| if(name != "") | |
| t = self.Find(name); | |
| if(t == null) | |
| t = self; | |
| return t; |
This file contains hidden or 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
| Shader "Custom/Hemisphere_Lighting" | |
| { | |
| Properties | |
| { | |
| _MainTex ("Texture", 2D) = "white" {} | |
| _SkyColor("Sky Color",Color)=(1,1,1,1) | |
| _GroundColor("Ground Color",Color)=(0,0,0,1) | |
| } | |
| SubShader |
This file contains hidden or 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.Generic; | |
| public class GameEvent | |
| { | |
| } | |
| public class EventMessenger | |
| { |