Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- string rotorNameTag = "Debug";
- string textPanelName = "Debug";
- void Main()
- {
- var textPanels = new List<IMyTextPanel>();
- var rotors = new List<IMyMotorStator>();
- GridTerminalSystem.GetBlocksOfType(rotors, x => x.CustomName.Contains(rotorNameTag));
- GridTerminalSystem.GetBlocksOfType(textPanels, x => x.CustomName.Contains(textPanelName));
- string output = "";
- foreach (var block in rotors)
- {
- output += $"'{block.CustomName}' - Angle: {MathHelper.ToDegrees(block.Angle):N1}\n";
- }
- foreach (var block in textPanels)
- {
- block.WritePublicText(output);
- block.ShowPublicTextOnScreen();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement