List<YourType> newList = new List<YourType>(oldList);
List<YourType> oldList = new List<YourType>();
List<YourType> newList = new List<YourType>(oldList.Count);
oldList.ForEach((item)=>
{
newList.Add(new YourType(item));
});
Loop through the starters array, and print the starter and its number like this:
#001 Bulbasaur
Now, edit the strings with a loop to include this number as well.
Create two-dimensional data structure with x,y coordinates.
Create a function populateLevel()
that creates new enemy GameObjects in the scene based on these coordinates.
Also, create a function newCoordinate(x, y)
that can be used to add new coordinates into the data structure.
Extra: What if you want to populate the level with enemies and collectibles, both of which saved in the same data structure?
Continue exercise 1 from Scripting gameobjects.
Instead of three lights, have nine lights, each with a tag "Light" (preferably as a prefab).
Control the lights from the light switch with a program that runs through a list of all the lights instead of switching them on and off individually.