Space Engineers

Space Engineers

Not enough ratings
AllOresScan - Ore Detector Reforged
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
376.790 KB
2 Oct, 2023 @ 2:31pm
1 Change Note ( view )

Subscribe to download
AllOresScan - Ore Detector Reforged

Description
This script will scan all ores in a provided radius and return the first result it finds in the list from top to bottom.

How to adjust priority?
Simple put the more important ores at the top, or remove ores from the list.

string[] oreTypes = new string[]
{
"Nickel",
"Platinum",
"Iron",
"Silver",
"Gold",
"Tritanium",
"Aluminum",
"Uranium",
"Duranium",
"Magnesium",
"Silicon",
"Cobalt",
};

For example this would be used on the Star Trek server. If you want Duranium to be more important, just move it to the top of the list, or higher up in the list. Right now Nickel is the most important one to the script.

How do I run this?
Simply hit run, or have another programmable block hit run. You must however wait until it's completed it's scan and output a result. Trying to run this repeatedly before it's finished will just restart the script over and over again and isn't really useful.

Where do the results go?
Results go to the CustomData of the programming block the script is located on. in X:123 Y:123 Z:123 format.

Can be used with another script I wrote!
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=3041881089

8 Comments
hugums247 28 Jun, 2024 @ 10:47am 
wont work laundry list or errors
Oblivion2012 22 Jun, 2024 @ 7:01pm 
How would i add better stone ores or any other modded ores?
FC3827 16 May, 2024 @ 5:14pm 
Aaaand that's exactly what I was about to try to learn a new language for. I have been saved
AnonaMoose  [author] 27 Apr, 2024 @ 2:22pm 
@RustySoldier if you can tell me what server you are playing on i can sorta narrow it down. its possible it might be a server side issue with it missing a mod.
AnonaMoose  [author] 3 Apr, 2024 @ 1:51pm 
ill look into bugg fixing once i get around to playing again sorta got burnt out on it
RustySoldier 6 Nov, 2023 @ 4:23am 
it's basically a bug happening since the anniversary update
RustySoldier 6 Nov, 2023 @ 4:16am 
Pulse: 1
Caught exception during execution of script:Invalid property
at Sandbox.ModAPI.Interfaces.TerminalPropertyExtensions.Cast[TValue](ITerminalProperty property)
at Program.ReforgedDetectN(BoundingSphereD area, String minedOre, Int32 count, Action`1 callBack)
at Program.Main(String argument, UpdateType updateSource)
at Sandbox.Game.Entities.Blocks.MyProgrammableBlock.<>c__DisplayClass42_0.<ExecuteCode>b__0(IMyGridProgram program)
at Sandbox.Game.Entities.Blocks.MyProgrammableBlock.RunSandboxedProgramActionCore(Action`1 action, String& response)
MrFox 12 Oct, 2023 @ 1:54pm 
does this need a mod or something?