Nicklas Bourelius b15f3b7391 Color now working.
Need to implement: Slider and logic for it and UI and the logic for that as well.
2024-05-23 18:36:51 +02:00

22 lines
587 B
C#

using UnityEngine;
using UnityEditor.AssetImporters;
using System.IO;
#if !UNITY_2022_1_OR_NEWER
using UnityEditor.Experimental.AssetImporters;
#endif
namespace Proxima.Editor
{
[ScriptedImporter(1, "pfx")]
internal class PfxImporter : ScriptedImporter
{
public override void OnImportAsset(AssetImportContext ctx)
{
var asset = ScriptableObject.CreateInstance<PfxAsset>();
asset.Bytes = File.ReadAllBytes(ctx.assetPath);
ctx.AddObjectToAsset("main obj", asset);
ctx.SetMainObject(asset);
}
}
}