Exemple #1
0
 private void Start()
 {
     BulletSpeed      = projectilePrefab.projectileSpeed;
     turretAmmunition = GetComponent <ITurretAmmunitionSystem>();
     if (turretAmmunition == null)
     {
         Debug.LogError("Ammunition System is requiare for this component");
     }
 }
Exemple #2
0
    private void Start()
    {
        turretAnimationController = GetComponent <Animator>();
        turretShootSystem         = GetComponent <ITurretShootSystem>();
        turretRotationSystem      = GetComponent <ITurretRotationSystem>();
        targetSelector            = GetComponent <ITargetSelector>();
        turretAmmunitionSystem    = GetComponent <ITurretAmmunitionSystem>();

        shootAnimation  = Animator.StringToHash("Shoot");
        reloadAnimation = Animator.StringToHash("Reload");
    }