コード例 #1
0
ファイル: AAGunAiming.cs プロジェクト: ShaunPrince/BombsAway
    private void CalculateTOF()
    {
        EnemyFireWeapon efw = this.GetComponentInChildren <EnemyFireWeapon>();

        timeOfFlight = Vector3.Distance(this.transform.position, targetRB.transform.position) / efw.projectileSpeed;
    }
コード例 #2
0
 // Start is called before the first frame update
 void Start()
 {
     shootGun = this.GetComponent <EnemyFireWeapon>();
 }