Space Engineers

Space Engineers

179 ratings
Whip's Script Replacer Block
Type: Mod
Mod category: Block, Script
File Size
5.101 MB
Oct 3, 2022 @ 9:15pm
1 Change Note ( view )

Subscribe to download
Whip's Script Replacer Block

In 1 collection by Whiplash141
Whip's Mods
15 items
Whip's Script Replacer Block


Do you tire of having to manually update the scripts in your ship blueprints every time a silly script writer makes an update? Do you wish that I would stop pushing updates to WHAM every freaking day? Well this mod helps with the first one!

The Script Replacer Block cures depression allows you to easily replace the script content and the custom data of multiple programmable blocks on your ship all at once! It even allows you to replace the script/custom data of blocks that are stored in projections!

This means that if you are a mad(wo)man who has a missile ship with 32 missiles + reload projections, you can update the scripts on the grid and the ones stored in your reload blueprints all at once!

  How do I Use This?!
  1. Place a Script Replacer Block on your ship
  2. Click the edit button and load in the script that you want into the Script Replacer Block
  3. Configure the custom data how you want in the Script Replacer Block
  4. Select the programmable blocks with scripts/custom data that you want to replace using the "Programmable Block List"
    • You can select multiple at a time!
  5. Click the "Replace Script" button to replace the scripts with the one in the Script Replacer Block. Click the "Replace Custom Data" button to replace the custom data with what is in the Script Replacer Block's custom data.
  6. You can remove the Script Replacer Block when done.

  Author's Notes
I hate modding, so I hope y'all like this. Getting the dang blocks to show up in the G-menu was harder than writing the code, and that is tragic. BlockVariantGroups suck.

Also, I stole Keen's old models from Gwindalmir's Retro Blocks mod because I can't be bothered to learn blender.

< >
Flepricon May 27, 2023 @ 7:12pm 
You should make a script that detects players and logs them for trade zones or wtv, a sensor block that adds to a LCD maybe
BIV Jan 27, 2023 @ 10:45pm 
@ Whiplash141 , mate I think your work is great and hope that one day I will figure out how to use it (my issue not your work). Cheers mate.
@ funhans , congrats on becoming a professional software developer.
Whiplash141  [author] Dec 3, 2022 @ 2:22pm 
The below discussion is not at all relevant to the function of this mod.
Wickedcube Dec 3, 2022 @ 4:41am 
if anyone understands what the physics proffesors are talking about below pleas simplify for everyone else...
Whiplash141  [author] Nov 25, 2022 @ 12:06pm 
there are any number of arbitrary oriented bounding boxes that can fit into an axis aligned bounding box. There is not enough info provided in an AABB to construct an oriented one from it.
funhans Nov 25, 2022 @ 8:58am 
I don´t know whether that works or not, but I have some assumptions on that:

So, we do know the size of the bounding box facing a specific world-orientation.
We also know our very own world-orientation.

In theory, if we would utilize our own coordinate system, enter the corner-points from the bounding box in that and calculate the deviation from the direction the bounding box has in the SE-world (aka it's world-orientation) to a comparision-vector (let's say (1,0,0)) then rotate the whole cuboid by this deviation => we made it uniform.
Now we can calculate our own deviation from the comparision-vector and rotate the bounding box within our own coordinate system by that deviation => We cannot get the size and we cannot draw in let's say front or back BUT it could work out as a B-Scope, couldn´t it?

I may mix things up here but - at least in my head - that sounds like it could work
funhans Nov 23, 2022 @ 1:47am 
Thanks anyway 🍻
Whiplash141  [author] Nov 22, 2022 @ 9:02am 
There is no way to get the true size of a thing from an axis aligned bounding box
funhans Nov 22, 2022 @ 1:49am 
I'm sorry to contact you in that way, however I'm not a fan of pushing friends requests just to text with the person one time and get the answers.
One could say I'm more of a fan if such things are developing and friends are friends ...

Oh, and btw, sorry for spamming the comment section of a completely off-topic script 👀
funhans Nov 22, 2022 @ 1:45am 
Fun fact: Your scripts and of course, SE brought me to learn my current profession :D

Problem with this:
I'm now a professional software developer, however I still have my issues with getting the math of SE together 🤪

Specifically I try to get the size of a MyDetectedEntityInfo object - that apparently seems to change depending on my angle to it (guess, it's simply world aligned).
I know the vector-transformations from MDK-SE's wiki - but I'm not able to get it to work 🤦‍♂️