// Use this for initialization void Start() { g1 = GameObject.FindGameObjectWithTag("numero1"); g2 = GameObject.FindGameObjectWithTag("numero2"); // t1 = g1.GetComponent<VariablesGlobales>(); // t2 = g2.GetComponent<VariablesGlobales>(); Tf1 = float.Parse(g1.name); Tf2 = float.Parse(g2.name); l = ecuacionLong(); Debug.Log(l); f = Tf2; k = ecuacionK(l); Bmax = ecuacionBmax(); txtBm.text = "Bmax = " + Bmax.ToString() + "V/m"; for (int i = 0; i < 33; i++) { xv[i] = ecuacionX(l, i + 1); ve[i] = ecuacionE(xv[i], Tf1, Tf2); vb[i] = ecuacionB(xv[i], Bmax, Tf2); Debug.Log(i + ". ." + ve[i]); } }
private void trackBarHmax_ValueChanged(object sender, EventArgs e) { Bmax = trackBarHmax.Value; tbHmax.Text = Bmax.ToString(); }