void createResultGb(List <int> result) { var gb = new GameObject("StepResult"); gb.transform.parent = transform; ShowMineResult sm = gb.AddComponent(typeof(ShowMineResult)) as ShowMineResult; sm.happyCheckStep = this; sm.result = result; }
public void OnSceneGUI() { ShowMineResult data = target as ShowMineResult; Handles.color = Color.green; if (data.happyCheckStep != null && data.result != null) { foreach (var index in data.result) { var ufa = data.happyCheckStep.GetUfa(index); Handles.Button(Singleton.MainData.AreaPosWorld(ufa.pos.x, ufa.pos.y), Quaternion.identity, 0.5f, 0.5f, Handles.CylinderHandleCap); } } }