コード例 #1
0
        public override void Run()
        {
            base.Run();
            GameObject currentVehicle = VTOLAPI.instance.GetPlayersVehicleGameObject();

            manager = currentVehicle.GetComponentInChildren <MFDManager>();
            List <MFD> mfds = manager.mfds;

            System.Random rand = new System.Random();
            Debug.Log($"Found {mfds.Count.ToString()} MFDs");
            int index = rand.Next(mfds.Count);

            mfds[index].TogglePower();
            StartWarning();
        }
コード例 #2
0
 public void Awake()
 {
     a = this;
 }