// Use this for initialization void Start() { rb = GetComponent <Rigidbody>(); p1rb = opponent.GetComponent <Rigidbody>(); p1script = opponent.GetComponent <P1Control>(); p2text.text = "Player 2\nScore: " + score + "\n\nActive buffs: "; }
// Use this for initialization void Start() { p1script = p1.GetComponent <P1Control>(); p2script = p2.GetComponent <P2Control>(); p1rb = p1.GetComponent <Rigidbody>(); p2rb = p2.GetComponent <Rigidbody>(); toptext = gameObject.GetComponent <UnityEngine.UI.Text>(); toptext.text = "" + 60; }