New to Unity.... My problem seems a bit different from other posts on acccessing script variables.
I have code below in a script.
The line 'badGuy.Enemy1_AI.EnemyLevel = badEnemyLevel;' fails with 'Enemy1_AI is not member of unity.transform'.
I am missing something, how can I correct this?
// GameMaster.js
var enemy1 : Transform; var badGuy : Transform;
var badEnemyLevel : int =1;
badGuy = Instantiate ( enemy1, Vector3 ( (Random.value * 400) - 200, 0, -2460), Quaternion.identity);
badGuy.Enemy1_AI.EnemyLevel = badEnemyLevel;
// Enemy1_AI.js
static var EnemyLevel : int;