コガネブログ

平日更新を目標に Unity や C#、Visual Studio、ReSharper などのゲーム開発アレコレを書いていきます

【Unity】Unity 2020.2a 新機能 - 配列やリストを Inspector で並べ替えられるようにする「Reorderable」属性

概要

using System.Collections.Generic;
using UnityEngine;

public class Example : MonoBehaviour
{
    [Reorderable] public string[]    m_names;
    [Reorderable] public Vector3[]   m_positions;
    [Reorderable] public List<Color> m_colors;
}

f:id:baba_s:20200626095235g:plain

参考サイト様