update handling of Lua assets
This commit is contained in:
@@ -5,11 +5,11 @@ using UnityEngine;
|
||||
[CustomEditor(typeof(LuaFile))]
|
||||
public class LuaScriptAssetEditor : Editor
|
||||
{
|
||||
private TextAsset asset;
|
||||
|
||||
public override void OnInspectorGUI()
|
||||
{
|
||||
LuaFile luaScriptAsset = (LuaFile)target;
|
||||
|
||||
// Allow user to drag-and-drop the Lua file
|
||||
luaScriptAsset.luaScript = (TextAsset)EditorGUILayout.ObjectField("Lua Script", luaScriptAsset.luaScript, typeof(TextAsset), false);
|
||||
EditorGUILayout.TextArea(luaScriptAsset.LuaScript);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user