Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- using System.Collections;
- [System.Serializable]
- public class test
- {
- public string name;// поле для отображаемого в инспекторе названии
- public int value;// значение
- };
- public class MyScript : MonoBehaviour
- {
- public test[] array;
- void Start()
- {
- for (int i = 0; i < array.Length; i++)
- {
- Debug.Log(array[i].name + ": " + array[i].value.ToString());
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement