Select Git revision
VAUDirectivity.cs
Maurice Tayeb Andreas authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
VAUDirectivity.cs 775 B
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class VAUDirectivity : MonoBehaviour {
protected int _ID = -1; // Stores the internal id that is assigned by VA
[Tooltip("Absolute or relative path (relative to Assets folder), also use AddSearchPath for special folders.")]
public string FilePath = "";
public string Name = ""; // Versatile name for this directivity
public int ID
{
get
{
return _ID;
}
}
void Start ()
{
if (FilePath.Length > 0)
_ID = VAUAdapter.VA.LoadDirectivity(FilePath, Name);
}
private void OnDestroy()
{
if (_ID != -1)
VAUAdapter.VA.FreeDirectivity(_ID);
_ID = -1;
}
}