ProFlareAtlas.cs 837 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. //This asset was uploaded by https://unityassetcollection.com
  2. /// ProFlares - v1.08- Copyright 2014-2015 All rights reserved - ProFlares.com
  3. using UnityEngine;
  4. using System.Collections.Generic;
  5. using System;
  6. public class ProFlareAtlas : MonoBehaviour {
  7. [System.Serializable]
  8. public class Element
  9. {
  10. public string name = "Flare Element";
  11. public Rect UV = new Rect(0f, 0f, 1f, 1f);
  12. public bool Imported;
  13. }
  14. public Texture2D texture;
  15. public int elementNumber = 0;
  16. public bool editElements = false;
  17. [SerializeField] public List<Element> elementsList = new List<Element>();
  18. public string[] elementNameList;
  19. public void UpdateElementNameList(){
  20. elementNameList = new string[elementsList.Count];
  21. for(int i = 0; i < elementNameList.Length; i++)
  22. elementNameList[i] = elementsList[i].name;
  23. }
  24. }