Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- public class Wichtelbot : MonoBehaviour
- {
- class Wichtel
- {
- public string name;
- public Wichtel(string name)
- {
- this.name = name;
- }
- }
- private void Start()
- {
- var alleWichtel = new Wichtel[6]
- {
- new Wichtel("Sven"),
- new Wichtel("Karl"),
- new Wichtel("Manu"),
- new Wichtel("Lena"),
- new Wichtel("Patrick"),
- new Wichtel("Nina")
- };
- }
- for (var i = 0; i < alleWichtel.Length; i++)
- {
- Debug.Log("Wichtel Nummer " + i + " heißt " + alleWichtel[i].name);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement