Space Engineers

Space Engineers

Automatic Ejector
23 Comments
MrXSmiles420 25 Jan @ 12:03pm 
on argument wont work
Unruly 15 Dec, 2023 @ 10:47am 
Hi again, thanks as always for your mods.

I've just found a new wrinkle: if the programmable block AE is in is a small grid, it presumes the connector it's using is also small grid, apparently. I put a small grid on my LG miner, to be able to fit stuff like extra pb's, survival kit, etc., and when it was ejecting, it's only ejecting 400 stone at a time. while it was doing so, I manually started filling the connector w/ stone and it goes back to expelling the max that a LG connector can do.
DMN Nitemare 31 Dec, 2022 @ 3:56pm 
Jet if possible I would love a connector modification that would modify how much ore can be dumped at a time during ejection. But overall this script will be a huge help.
TurboProp  [author] 31 Mar, 2022 @ 5:00am 
Xanolego, I'm glad you liked my script, thank you very much for the compliments! If you want some improvements, please report them to me and I will try to implement them!
TurboProp  [author] 31 Mar, 2022 @ 4:59am 
Hi Unruly! I can add a run-argument to toggle the ejection for a specific ore if that's what you need!
xenolego 19 Mar, 2022 @ 9:47pm 
Thanks for this one! The old stone ejection script I was using stopped working a bit ago and the replacement one I was using only looked at one cargo container to draw stone from (ignored stone in the drills and other cargo containers).


This one seems to do what I want and I'm glad you put it together!
Unruly 11 Mar, 2022 @ 10:54am 
I was just wondering if it was possible for us to pass the article to be ejected by run arguments? Rather than docking, I'm near my destination and auto-ejecting paydirt by altering the custom data.
TurboProp  [author] 26 Jan, 2022 @ 12:34pm 
Hey Calibrated! Yep, it does support LCDs, you can use the script tag [AE] for blocks with a single lcd or [AE:displayNumber] for cockpits or other blocks with multiple lcds. With a designated sorter you can use this script with other scripts like the PAM (Path Autominer), when one of the other scripts turns on the designated sorter this script will start to eject the ores and will stop if the designated sorter is turned off. You can configure the ores from the Custom Data of the programmable block which is running the script, only Stone and Ice are supported, tell me if you need other ores and I will add them to the supported ones
Calibrated 23 Jan, 2022 @ 11:58pm 
and what "support" does this do? "Support for a designated sorter with tag [AE_DES]"
Calibrated 23 Jan, 2022 @ 11:57pm 
Hey there! AWESOME script.. Hey is there LCD support? and how do I change the ores to be ejected?
TurboProp  [author] 16 Dec, 2021 @ 2:27am 
Hey @xceled, tell me which is the error you are getting and how to reproduce it, I'll fix it asap! If you want post a link to the blueprint of your ship, it may also be useful for others!
xceled 10 Dec, 2021 @ 5:27pm 
Hi JetDave, can you post the non-minified version on Github? Would like to tinker/try to resolve NRE I keep getting.
Unruly 12 Nov, 2021 @ 10:55pm 
Hey, thanks! Working a treat now.
TurboProp  [author] 11 Nov, 2021 @ 3:14pm 
I have updated the script but I could not replicate the error. I have changed some lines which could have caused the error. Tell me if the error reappears or if it seems to be fixed!
Unruly 3 Nov, 2021 @ 11:15am 
I'm getting an exception, the error was 'Object reference not set to an instance of an object. The call stack was program j(boolean k) at program x() at program main. I guess it's kacking at trying to enumerate the available connectors? I AM using modded connectors, but it worked fine until this version. The modded connector is a 1x1x1 usgc from 'ultimate small grid conversion', https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2230632087
TurboProp  [author] 19 Oct, 2021 @ 9:58am 
No worries! Just updated the script, tell me if the problem is solved!
Unruly 17 Oct, 2021 @ 9:57am 
Sorry for not replying. You're probably right, that the drill is just filling the connector as the last-choice, and the connector, being set to throw out, is obligingly doing so.
TurboProp  [author] 16 Oct, 2021 @ 3:55am 
I will add a check to every connector/ejector inventory so that it won't eject if there are other ores apart the ones configured
TurboProp  [author] 16 Oct, 2021 @ 3:44am 
Probably the drill pushed the ores into the connector while it was ejecting, I don't have other ideas.. Which ore were you collecting?
Unruly 7 Oct, 2021 @ 9:09pm 
So, my miner started ejecting the ore I was collecting today, but only until the drill was empty. Is this intended? For the super small miner in question, the drill is a big fraction of the storage available, so I was trying to fill it up.
Unruly 21 Sep, 2021 @ 6:55pm 
Hey, thanks so much. That's awesome.
TurboProp  [author] 21 Sep, 2021 @ 8:33am 
Hi! Yes, I just paused for a bit the developement of this script to work on my other script "battery manager plus". Now I will work to implement your request!
Unruly 16 Sep, 2021 @ 10:45am 
Hi, thanks for this mod! Is there a way to stop the ejecting without turning the ejecting connector off? When I simply turn off the programable block, it leaves the connector with 'throw out' set true, and that's awkward later.

I see that it switches 'throw out' off when it's run out of stone, could you add a run argument to have it end early?