コード例 #1
0
 // private AudioSource aud;
 private void Start()
 {
     enemyHurt = GetComponentInParent <EnemyHurt>();
     enemyLife = GetComponentInParent <EnemyLife>();
     enemiIA   = GetComponentInParent <EnemiIA>();
     // aud = GetComponent<AudioSource>();
 }
コード例 #2
0
 private void Start()
 {
     enemyHurt    = GetComponentInParent <EnemyHurt>();
     enemyType    = GetComponentInParent <EnemieType>();
     uiController = FindObjectOfType <UIController>();
     groundCheck  = GetComponentInChildren <GroundCheck>();
     ballTrue     = true;
     // Carlos Mod
     enemiIA = GetComponentInParent <EnemiIA>();
     aud     = GetComponent <AudioSource>();
 }
コード例 #3
0
    void CreateEnemy()
    {
        Transform spawnPoint = spawnPoints[Random.Range(0, spawnPoints.Count)];
        //   Debug.Log("spawning enemy : " + enemyID);

        GameObject enemyObj = Instantiate(EnemyPrefab, spawnPoint);

        enemyObj.transform.localPosition = Vector3.zero;
        EnemyHurt enemyHurt = enemyObj.GetComponent <EnemyHurt>();

        enemyHurt.master = master;

        EnemyMotor motor = enemyObj.GetComponent <EnemyMotor>();

        motor.master              = master;
        motor.bulletSpeedMulti   += levelData.bulletSpeedIncrease.Evaluate(Time.time);
        motor.bulletIntervalMulti = levelData.bulletIntervalMulti.Evaluate(Time.time);

        enemyID++;
    }
コード例 #4
0
ファイル: StoreStuff.cs プロジェクト: kxk9106/DungeonCrawl
	// Use this for initialization
	void Start () {
		plScript = FindObjectOfType (typeof(Player)) as Player;
		enScript = FindObjectOfType (typeof(EnemyHurt)) as EnemyHurt;
		wpScript = FindObjectOfType (typeof(WeaponPower)) as WeaponPower;

	}
コード例 #5
0
ファイル: WeaponPower.cs プロジェクト: kxk9106/DungeonCrawl
	// Use this for initialization
	void Start () {
		enScript = FindObjectOfType (typeof(EnemyHurt)) as EnemyHurt;
		ps = FindObjectOfType (typeof(Player)) as Player;
		enmHealth = 6 - enScript.enemyHealth;
		weaponPow.text = "Weapon Power: " + enmHealth;
	}