Ejemplo n.º 1
0
    private SpriteRenderer sprite; // Поворот


    private void Awake()
    {
        livesBar  = FindObjectOfType <LivesBare>();
        rigidbody = GetComponent <Rigidbody2D>();
        animator  = GetComponent <Animator>();
        sprite    = GetComponentInChildren <SpriteRenderer>();
        bullet    = Resources.Load <Bullet>("Bullet");
    }
Ejemplo n.º 2
0
    private SpriteRenderer sprite; // Поворот


    private void Awake()
    {
        farCountText.text  = "FarBullet: " + farCount;
        nearCountText.text = "NearBullet: " + nearCount;
        livesBar           = FindObjectOfType <LivesBare>();
        livesBar1          = FindObjectOfType <LivesBare1>();
        rigidbody          = GetComponent <Rigidbody2D>();
        animator           = GetComponent <Animator>();
        sprite             = GetComponentInChildren <SpriteRenderer>();
        bullet             = Resources.Load <Bullet>("Bullet");
        bullet1            = Resources.Load <Bullet1>("Bullet1");
    }