Space Engineers

Space Engineers

186 vurderinger
[SCAM] Simple Concurrent Adaptive Min3r
5
5
3
2
   
Pris
Føj til foretrukne
Gjort til foretrukken
Fjern som foretrukken
Filstørrelse:
Offentliggjort:
Opdateret:
477.404 KB
11. aug. 2021 kl. 7:37
20. maj 2022 kl. 5:18
10 ændringsbemærkninger ( vis )

Abonner for at downloade
[SCAM] Simple Concurrent Adaptive Min3r

Beskrivelse
The idea
I designed this autominig solution to suit my approach to mining automation in vanilla game. The main goal was to make a system that would allow extremely early mining automation in survival with great scalability later on. At this moment it's tuned to mine spherical/saucer vanilla ore deposits in space and on planets.
Check out the sample to see if it's your thing before diving further.
Distinctive features:
  • Send to new mining spot with exactly one command (by positioning drone or doing camera raycast)
  • Scale number of drones easily with no added set up actions
  • All drones mine the single spot (called mining task) together with exclusive blocking shared path segments to avoid collisions (HOPEFULLY), hence the Concurrent word
  • Drones are recalled with a single command and dock to moving carrier automatically
  • Drones try to ignore stone layer, adjust max mining depth based on ore gain analysis, so it's kinda Adaptive
Current limitations:
  • Current mining pattern and concurrency approach requires all acting drones to have the same size
  • Drones have to be vertical miners (drills facing down, going downwards)
  • Base docking area has to be top open, docking drones descend vertically
  • Probably have quite an amount of bugs and hikkups - while I used them A LOT during my survival playthrough, I might've missed lots of test cases because of my playstyle, also recently the code undergone a huge rework
Usage
  1. Watch the quickstart video guide or read this guide
  2. Get the min3r of choice or build your own
  3. Copy the code to drones' blueprint, make sure Dispatcher and all Agents run the same version

Advanced features
Adaptive mining is a feature that allows dynamic change of mining plan based on ore income. If enabled on agent, it would constantly check what content gets into drills and do several adjustments:
- change skip-depth (distance from the mining area surface where drills block incoming ore, to eliminate stone input)
- change depth-limit
- send direction-banning messages to Dispatcher.

direction-banning would cancel out planned shafts in a small cone (going from the mining plans' center). This represents areas that are considered not worth expanding to.

Adaptive mining should be toggled on Agents (toggle:adaptive-mining in CustomData or run arg). If it is enabled on Dispatcher, it would enforce this setting on all drones in active group during task creation.

It is disabled by default to avoid confusion

Any ore input except Stone is considered valuable.

Tested workhorses
Small space: https://steamcommunity.com/sharedfiles/filedetails/?id=2572154521. Not recommended for G environments. Risk of peer damage: almost zero.

Small atmo: https://steamcommunity.com/sharedfiles/filedetails/?id=2572218085. Tested up to 1.2G. Risk of peer damage: small.

Large gravdrive: https://steamcommunity.com/sharedfiles/filedetails/?id=2576438985. Not recommended for G environments. Risk of peer damage: none.

Small H2 (test prototype): https://steamcommunity.com/sharedfiles/filedetails/?id=2583145703. Tested up to 1.2G. Risk of peer damage: medium.

Custom Data boot commands for base and drones
Those commands are executed immediately on start/recompile. During runtime they can be fed to PB via run argument.
Base or Carrier (Dispatcher role)
command:set-role:Dispatcher command:add-logger:scam-log-panel command:add-panel:scam-gui-panel // for GUI mode on the 'scam-gui-panel' tagged screen command:add-gui-controller:scam-controller toggle:log-message command:set-value:max-generations:8 command:set-value:getAbove-altitude:5 command:set-value:skip-depth:0 command:set-value:depth-limit:50
Small drone - all Min3r 69R line (Agent role)
command:set-role:Agent command:set-value:circular-pattern-shaft-radius:3.6 command:set-value:preferred-container:Large Cargo Container x command:add-panel:feed-panel // uncomment below to enable adaptive mode //toggle:adaptive-mining
Large drone - gravity driven variants (Agent role)
command:set-role:Agent command:set-value:circular-pattern-shaft-radius:7.9 command:set-value:preferred-container:Large Cargo Container x command:add-panel:feed-panel // uncomment below to enable adaptive mode //toggle:adaptive-mining

Script argument reference

Too big to be included here, see script arguments reference discussion.

Troubleshooting and advice on how to avoid shooting yourself in a leg
  • Do not copy-paste drones in creative during their activity. If you have to, use clear-storage-state command and then copy
  • The orientation of connectors matters, both on base and on drone. While autopillock should handle any cases, drone pathing currently optimized for stock drones - vertical mining, vertical landing.
  • If you add/remove any blocks during operation, you need to recompile everything
  • When drone docks, it switches all batteries in recharge mode. After recent update, this might block a drone forever until you switch batteries manually. If you experience this, toggle base connectors' Power Transfer Override ON.
  • Use command:clear-storage-state on every PB to reset all internal state, if you see some weird behavior. You can use command:global:command:clear-storage-state on Dispatcher to broadcast it to every linked drone
  • Getting exception "Not enough thrust to compensate for gravity" - you drone struggled to overcome gravity. Can happen to weak ion min3r when in G environment and fully loaded.
  • If you have issues with drones not docking, make sure nothing is messing up with connector Custom Data. The script uses it to claim connectors for drones.
  • In case of deadlocks when drones seem to wait for each other and do nothing, try Purge Locks command as a last resort.
  • Don't use on asteroids in planetary gravity field. This would be considered planetary mining and won't go as you expected.

If you have issues
Please tell about them in the bug reports discussion .
Before that, make sure dispatcher and drones run the same script version (shown in the PB run printout).
Check script logs from dispatcher and drone - if you did not add specific LCD for logging, log can be found inside PB screen. Often you can get what went wrong right from the log.

If you have issues with drone docking process
Please prepare to answer these questions before asking or posting bug report:

1. Does the dispatcher PB show those drones as "ID awaits docking" in PB info printout (where runtime info, version, etc shows up)?

2. Do those free connectors you expect drones to dock to have something in their Custom Data (should be empty or having THAT drone ID)?

3. What lock ownership does the GUI show for those stuck drones ("general", "force-finish", etc)

4. Does the "Purge Locks" GUI button solve the issue?
Populære diskussioner Vis alle (5)
332
26. apr. kl. 15:37
FASTGJORT: Bug reports, feature suggestions
cheerkin
19
11. maj 2023 kl. 17:53
FASTGJORT: Script argument reference
cheerkin
8
2
18. feb. kl. 13:28
FASTGJORT: Set-up guide
cheerkin
410 kommentarer
phreekbird 27. maj kl. 12:19 
@cheerkin, ok, guess imma stick to PAM for now then as it has channels... ill keep an eye on SCAM as i really want to use it, but , cant on a server. Keep up the great work.
HATE|DeathKnight/ALLKEYSHOP 27. maj kl. 10:53 
@cheerkin is theare a way to tell in witch direction the drone will take for what because at the moment my first drone works but my second one just flyes off some where
cheerkin  [ophavsmand] 27. maj kl. 10:39 
@phreekbird not yet, that's why it is "unsupported". I think the only way is to make sure that their antenna networks do not overlap (staying out of antenna ranges).
HATE|DeathKnight/ALLKEYSHOP 27. maj kl. 10:17 
ok now i managed to get it to work but it flyés in the wrong direction is theare a way how to tell witch way it takes as forward by the gyro
HATE|DeathKnight/ALLKEYSHOP 27. maj kl. 6:33 
Hi, i have pritey much rebuild the xu 3 miner but mine just wouldent work i even have kopied every scrip and enery group and every custom date but i cant seam to find out why the xu 3 is instantly werking but my miner wont
phreekbird 26. maj kl. 10:56 
so is there a way to take the "network" and make it player assigned/Faction assigned? or even set a network "channel"?
cheerkin  [ophavsmand] 25. maj kl. 16:01 
I have no experience so I can't really give troubleshooting tips for MP environment. I think they should be fine being under faction share (every block, so programmable block is authorized to work with them), but maybe its safer to pass all of them to a single owner. Also, there is a limitation of current version, it supports only one dispatcher per antenna "network", or things can get messy (drones would be randomly assigned to competing dispatchers and similar side-effects). Its not like its base SE mechanic, I just designed the system this way for simplicity.
phreekbird 25. maj kl. 6:45 
in a private server, were all one faction and just starting out in SE (loving it btw)... I print a drone, manually dock it to a docka-min3r connector, i recompile the PBs on the drone, and ... nothing. nothing shows up on the blue screen. i have gone through like 20 drones now, and only every once and awhile will one show up. i dunno whats going on, maybe its because various people "own" vairous drones/hardware? for example if i use X method to print a drone over Y method, whomever built that printer or nanite farm, etc, is now the owner... .would that have any issue on this?

also, as im super new here, wouldn't say, a command center (dispatcher) on a base and the dispatcher on a ship collide? how do they play nice? im obv not understanding some base SE mechanics here.

TIA, loving this thing (when its working in creative at least)
DecadoMeridius 24. maj kl. 7:53 
My miners always get stuck on waiting to dock. Anyone else have this issue? Using the xu-3 at the moment
cheerkin  [ophavsmand] 17. maj kl. 10:52 
For general flight, no, but you can try changing MAX_SP field at the top of the code.