Ejemplo n.º 1
0
 //private Transform agentPool;
 // Initialize shaders
 void Awake()
 {
     highlightShader = Shader.Find("Outlined/Diffuse");
     dissolveShader = Shader.Find("Dissolve/Dissolve_WorldCoords");
     mat0 = GetComponentInChildren<Renderer>().material;
     mat1 = new Material(Shader.Find("Legacy Shaders/Transparent/Diffuse"));
     mat1.color = new Color(0, 1, 0, 0.35F);
     mat2 = new Material(Shader.Find("Legacy Shaders/Transparent/Diffuse"));
     mat2.color = new Color(1, 0, 0, 0.35F);
     buildingPlacement = Camera.main.GetComponent<BuildingPlacement>();
     structurePool = GameObject.Find("_StructurePool").transform;
     //agentPool = GameObject.Find("_AgentPool").transform;
     newSpawn = Resources.LoadAll<GameObject>("Prefabs/Spawns");
     playerResources = GameObject.Find("GameManager").GetComponent<Player_Resources>();
 }
Ejemplo n.º 2
0
 void Start()
 {
     playerResources = GameObject.Find("GameManager").GetComponent<Player_Resources>();
 }
Ejemplo n.º 3
0
 // Use this for initialization
 void Start()
 {
     shaderObject = GetComponentInChildren<Renderer>();
     originalShader = shaderObject.material.shader;
     highlightShader = Shader.Find("Outlined/Diffuse");
     nodePool = GameObject.Find("_NodePool").transform;
     structureName = name;
     harvestTime = harvestTimer;
     transform.parent = nodePool;
     playerResources = GameObject.Find("GameManager").GetComponent<Player_Resources>();
     buildingPlacement = Camera.main.GetComponent<BuildingPlacement>();
 }
Ejemplo n.º 4
0
 // Use this for initialization
 void Start()
 {
     playerResources = GameObject.Find("GameManager").GetComponent<Player_Resources>();
     buildingPlacement = Camera.main.GetComponent<BuildingPlacement>();
 }