using System.Collections; using System.Collections.Generic; using UnityEngine; //============================================================ //支持中文,文件使用UTF-8编码 //@author #AUTHOR# //@create #CREATEDATE# //@company #COMPANY# // //@description: //============================================================ public class UPosItem : MonoBehaviour { /// /// 是否被占用 /// public bool isOccupied = false; public int ID; public SpriteRenderer instruct; [ContextMenu("Set")] public void SetValue() { //instruct = Instantiate(Resources.Load("Adam/Instruct"), transform); //DestroyImmediate(transform.GetChild(0).gameObject); } private void Start() { ID = int.Parse(gameObject.name); } /// /// 设置颜色 /// /// public void SetInstructColor(Color color) { instruct.color = color; } }