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
// change shader | |
var defaultShader = Shader.Find ("Sprites/Default"); | |
var renderers = ((GameObject)instance).GetComponentsInChildren<SpriteRenderer>(); | |
foreach (var r in renderers) { | |
r.material.shader = defaultShader; | |
} |
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 UnityEditor; | |
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.Text.RegularExpressions; | |
using System.IO; | |
public class SourceFileEcodingChecker : AssetPostprocessor { | |
static Regex m_SourceFilePattern; |
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
dirs = ["./trunk/unity/Assets/Source/**/*.cs", "./trunk/unity/Assets/Editor/**/*.cs"] | |
dirs.each do |dir| | |
Dir.glob(dir).each do |f| | |
next unless File.file?(f) | |
hoge = open(f) | |
hoge.binmode | |
begin | |
if hoge.read(3).unpack("h*")[0] != "febbfb" | |
puts f.to_s #+ " is *NOT* BOM file" |
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 UnityEditor; | |
using System.Collections; | |
public class EditPlayerPrefs : EditorWindow { | |
class PrefInfo { | |
public string Key; | |
public string Type; | |
} |
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
"================ | |
" NeoBundle | |
"================ | |
set nocompatible | |
filetype off | |
if has('vim_starting') | |
set runtimepath+=~/.vim/bundle/neobundle.vim | |
endif |
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; | |
/// <summary> | |
/// Editorでのスクリプト起動時に初期化処理を実行 | |
/// </summary> | |
[UnityEditor.InitializeOnLoad] | |
public class Autorun : MonoBehaviour { | |
static Autorun() { | |
Debug.Log ("*** Debug.Log hooked by Autorun.LogCallbackHandler()"); |
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.IO; | |
public class MyWebView : MonoBehaviour { | |
// Inspector で画面上に配置した GUI Text にアタッチする | |
public GUIText DebugText; | |
string m_filePath; |
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.IO; | |
using System.Text; | |
using Org.BouncyCastle.OpenSsl; | |
using Org.BouncyCastle.Crypto; | |
using Org.BouncyCastle.Crypto.Engines; | |
using Org.BouncyCastle.Crypto.Encodings; | |
public class APITestMain : MonoBehaviour { |
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
test |
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 UnityEditor; | |
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
public class TweenGroupManager : EditorWindow { | |
class TweenGroup { | |
public int GroupNo = 0; |