// Start is called before the first frame update void Start() { fire = NormalFire; lives = 3; level = 1; Debug.Log(MyFuncs.AplusB(1, 2)); if (s == null) { s = this.gameObject; } else { Debug.LogError("tried to reinitialize rocket singleton!"); return; } // simple comment GameObject.Find("gameOver").transform.localScale = new Vector3(0, 0, 0); GameObject.Find("RestartButton").transform.localScale = new Vector3(0, 0, 0); markers = GameObject.FindGameObjectsWithTag("playerMarker"); // create the array Behaviour halo = (Behaviour)gameObject.GetComponent("Halo"); halo.enabled = true; shielded = true; Invoke("ShieldsOff", 2f); Invoke("SpawnEnemy", 3f); Invoke("SpawnExtralife", Random.Range(10f, 15f)); for (int i = 0; i < roidCount; i++) { SpawnRoid(); } roidCount *= 2; StartCoroutine("LevelScale"); }
public Foo FuncF(Foo f) { return(MyFuncs.F <Foo>(f)); // <Foo> is optional - compiler can infer }