Exemplo n.º 1
0
        // Camera Scan script
        //Add all cammeras, lcds, cockpit, turrets (300 and 900) you wont to use to group with name "ScanSystem"

        public void Main(string argument, UpdateType updateSource)

        {
            // The main entry point of the script, invoked every time
            // one of the programmable block's Run actions are invoked,
            // or the script updates itself. The updateSource argument
            // describes where the update came from.
            //
            // The method itself is required, but the arguments above
            // can be removed if not needed.

            try
            {
                _rotator.DoTask();

                if (string.IsNullOrEmpty(argument))
                {
                    //Echo("Do scan");
                    system.DoScan();
                }
                system.SetRange(argument);
            }
            catch (Exception ex)
            {
                Echo(ex.Message);
            }

            //Echo($"Noumber of cameras: { system.cameras.Count }");
        }