Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- IMyTextSurface m; List<IMyGasGenerator> gg = new List<IMyGasGenerator>();
- public Program() { m = Me.GetSurface(0); m.ContentType = ContentType.TEXT_AND_IMAGE; m.FontSize = 26.4f/20;
- m.TextPadding = 0; m.Font = "Monospace"; m.FontColor = Color.DarkSlateGray; m.BackgroundColor = Color.Black;
- Runtime.UpdateFrequency = UpdateFrequency.Update1;
- }
- public void Main(){
- GridTerminalSystem.GetBlocksOfType(gg, b => b.CustomName.Contains("quant"));
- m.WriteText($"QUALYSer v0.2 by SWG\n{"".PadRight(20,'≡')}\nblk:{gg.Count,3} synchronized \nquantum electrolyser");
- foreach (var g in gg) {
- var n = g.GetInventory(0).GetItemAmount(MyItemType.MakeOre("Ice")).ToString();
- g.Enabled = !g.Enabled; if (g.CustomData!=n) {g.Enabled = !g.Enabled; g.CustomData = n;}
- }
- var і=Runtime; Echo($"{System.DateTime.Now}\nCode runtime:{і.LastRunTimeMs:F2} ms");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement