// Use this for initialization void Start() { last_band = 30; Vector3 tempVec = vec_oldPos;//this.GetComponent<Transform>().position; orig_ypos = tempVec.y; y_pos = tempVec.y; click_ypos = 0; x_pos = tempVec.x; def_mat = this.GetComponent <MeshRenderer>().materials[0]; otherScript = cube_manager.GetComponent <ChangeColor>(); myManager = empty_man.GetComponent <ScriptManager>(); //otherScript.bandMat_high = high_mat; graphScript = gui_canvas.GetComponent <WMGTest>(); }
private Vector3 vec_oldPos = new Vector3(3.7f, 119.6f, -147.5f); //position Vector at x=30; // Use this for initialization void Start() { //get scripts from GameObjects graph_script = gui_canvas.GetComponent <WMGTest>(); rec_script = rec_electrode.GetComponent <ElectrodeBehavior>(); color_script = color_cube.GetComponent <ChangeColor>(); audio_script = audio_obj.GetComponent <FrequencyChange>(); color_script.bandMat_high = bandMat_high; //calculate voltage color_script.time_scale = time_scale; //init graph graph_script.num_points = num_points; graph_script.band_width = band_width; graph_script.pointBuffer = pointBuffer; //graph_script.SetGraph(graph_enabled); //graph_script.set_recEnabled(rec_enabled); }