Answers for "how to instantiate more enemies in unity"

C#
0

how to instantiate more enemies in unity

void Update()
    {
        if (name1 == 0)
        {
            name2 ++;
            int i = name2;

            while (i > 0)
            {
                x = Random.Range(-8.03f, 8.07f);
                y = Random.Range(4.21f, 1.66f);

                Instantiate(name1, new Vector2(x, y), name1.transform.rotation);

                i--;

            }
            enemynumbers = lvl;


        }
        

    }
Posted by: Guest on June-28-2021

Code answers related to "how to instantiate more enemies in unity"

C# Answers by Framework

Browse Popular Code Answers by Language