Skip to content

Instantly share code, notes, and snippets.

@auycro
Created June 14, 2016 10:42
Show Gist options
  • Save auycro/54bdeafa4451249c316c387c7fa36077 to your computer and use it in GitHub Desktop.
Save auycro/54bdeafa4451249c316c387c7fa36077 to your computer and use it in GitHub Desktop.
Upper for checking file
using UnityEngine;
using UnityEditor;
using System.Collections;
[InitializeOnLoad]
public class UpperHelper {
static UpperHelper() {
Debug.Log ("UpperHelper");
Test ();
}
using UnityEngine;
using UnityEditor;
using System.Collections;
using System.IO;
public class UpperSettings : Editor {
static string package_path = "";
[MenuItem("Upper/Import Package",false)]
public static void LoadPackageButton()
{
package_path = EditorUtility.OpenFilePanel ("Import Unity Package", "/", "unitypackage");
Debug.Log (package_path);
if (!string.IsNullOrEmpty(package_path))
EditorUtility.OpenWithDefaultApp (package_path);
}
[MenuItem("Upper/Test Button",true)]
public static void Yeaj()
{
CheckFile ();
}
public static void CheckFile(){
Debug.Log ("CheckFile");
//MenuItem ("Upper/Import Package", true);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment