At the moment I'm using two arrays; one for the cubes I'm managing and one for a script inside of them. Is it possible to get this down to one array only?
private var cubes : GameObject[];
private var cubeScripts : boxmover[]; // The script in question
private var i : int;
private var j : int;
function Awake () {
cubes = GameObject.FindGameObjectsWithTag ("cube");
for (i = 0 ; i<cubes.length; i++)
{
cubeScripts _= cubes*.GetComponent(boxmover);*_
_*}*_
_*}*_
_*function Update()*_
_*{*_
_*for (i = 0 ; i<cubes.length; i++)*_
_*{*_
<em>_cubeScripts*.DoUpdate();*_</em>
<em>_*}*_</em>
<em>_*}*_</em>
<em>_*```*_</em>