29 lines
647 B
C#
29 lines
647 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
public class Test : MonoBehaviour
|
|
{
|
|
// Start is called before the first frame update
|
|
public GameObject cube;
|
|
SelectDetector detector;
|
|
DirectController controller;
|
|
void Start()
|
|
{
|
|
detector = new SelectDetector();
|
|
detector.Initialize();
|
|
detector.AddObject(cube);
|
|
|
|
controller = new DirectController();
|
|
controller.Initialize(detector);
|
|
controller.InitializeGizmo();
|
|
}
|
|
|
|
// Update is called once per frame
|
|
void Update()
|
|
{
|
|
detector.Update();
|
|
controller.Update();
|
|
}
|
|
}
|