Space Engineers

Space Engineers

Not enough ratings
BNETT_WorkInProgress_Scripted_Mining_Rig
   
Award
Favorite
Favorited
Unfavorite
Type: Blueprint
File Size
Posted
1.594 MB
15 Nov, 2022 @ 6:18pm
1 Change Note ( view )
You need DLC to use this item.

Subscribe to download
BNETT_WorkInProgress_Scripted_Mining_Rig

Description
Basic mining script to mine out deposits. Full base on wheels! Still a work in progress so i'm not going to spend to much time filling this out lol. I plan to upload the piston arm assembly BP in a manor that would allow it to be blue printed but as of right now you'll just have to paste in the entire rover via admin or use the Blue Print Subgrids mod.

The arm isn't to hard to build from scratch. Just make sure to name the pistons/drills right and you'll be fine.
_______________________________________________________________
Script fiddling. (not to bad)
Well... I figured out how to modify the script to get it to calculate drill velocity based off the vertical axis instead of the horizontal. I also modified the formula to remove the collapsed horizontal arm. Below is the change I made in case anybody else is wanting to do the same thing.

I only used share_inertia_tensor because it's true whereas I couldn't guarantee that with hp_extend. I'm sure adding a new variable near line 380 equal to true would have been the way to go but this is simpler for somebody to recreate.

My edit to lines 957 to 971:
if (vp_count > 0)
{
if (share_inertia_tensor)
{
rot_speed = (float)(rot_speed / ((v_stage * vp_step_length) + excess_meters));
}
else
{
rot_speed = (float)(rot_speed / (excess_meters + (vp_stage_count - v_stage) * vp_step_length));
}
}
else
{
rot_speed = (float)(rot_speed / excess_meters);
}

My edit to lines 1100 to 1115:

if (vp_count > 0)
{
if (share_inertia_tensor)
{
rot_speed = (float)(rot_speed / (excess_meters + v_stage * vp_step_length));
}
else
{
rot_speed = (float)(rot_speed / (excess_meters + (vp_stage_count - v_stage) * vp_step_length));
}
}
else
{
rot_speed = (float)(rot_speed / excess_meters);
}
rotor.Enabled = true;
_______________________________________________________________
Below is the custom data for the autominer programmable block if needed.

@Configuration
You can configure the script right below here,
by changing the values between then | characters.

The configuration will be loaded if you click Check Code
in the Code Editor inside the Programmable Block,
when the game Saves/Loads or if you use the
Set or the Refresh command.

There is a detailed explanation about what's what, inside the script.

Main Tag: |/Mine 01/|

///////////////////////////////////////////
2.) Basic Configuration

- You can change these at any point:

Use Auto Pause: |True|
High Cargo Threshold: |0.9|
Low Cargo Threshold: |0.5|
Show Advanced Data: |True|
Use LCD Color Coding: |True|
Use Share Inertia Tensor: |True|
Use Dynamic Rotor Inertia Tensor: |True|
Transmission Receiver Address: |0|

- Don't change these while a mining is in progress:

Max Rotor Angle: |35|
Min Rotor Angle: |0|
Non-Piston Blocks in Rotating Arm in Meters: |7.5|
Vertical Piston Step Length: |2|
Use Unique Horizontal Step Length: |False|
Horizontal Piston Step Length: |2|
Retract Horizontal Piston before Vertical Step: |False|
///////////////////////////////////////////
4.) Advanced Configuration

- Don't change these while a mining is in progress:

Use Unique Piston Limits: |False|
Max Vertical Piston Limit: |10|
Min Vertical Piston Limit: |0|
Max Vertical Inv Piston Limit: |10|
Min Vertical Inv Piston Limit: |0|
Max Horizontal Piston Limit: |10|
Min Horizontal Piston Limit: |0|
Vertical Piston Speed: |0.2|
Horizontal Piston Speed: |0.2|
Rotor Rotation Speed at 10m: |0.2|
Piston Body Length in Meters: |5|

Horizontal Piston Tag: |/Hor/|
Vertical Piston Tag: |/Ver/|
Inverted Piston Tag: |/Inv/|
Timer Advanced Tag: |/Adv/|