Created
July 1, 2018 16:46
-
-
Save TheStoneBook/a1a1a52b57ab3d3118394dbefbde7ff4 to your computer and use it in GitHub Desktop.
【Unity】指定アセットファイルのGUIDを取得する。
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using System; | |
using UnityEditor; | |
public class GuidSample : MonoBehaviour { | |
void Start () { | |
string t = AssetDatabase.AssetPathToGUID ("Assets/FileName"); | |
Debug.Log(t); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment