Space Engineers BattleMech Script Tutorial and All Workshops List Guide

Space Engineers BattleMech Script Tutorial and All Workshops List Guide 1 -
Space Engineers BattleMech Script Tutorial and All Workshops List Guide 1 -
This Guide will run you through setting up a Bipedal Mech for my Script and its optional features



making Mechs has always been a dream of mine, the clunkiness of timer blocks and the constant tipping over of mechs have been frustrating for years, so i tried to learn some basic scripting to streamline setting up bipedal mechs in minutes that will walk, turn, crouch, stretch, strafe and more.

I will use the term Actuators for Rotors and Hinges.

The Mechs controls are like a tanks or a ships controls, WASD, C, Spacebar and Mouse or similar input.

Link to my Script:
Though the latest and best working versions of the scripts are on my mechs:
Here are some Example Mechs of mine
My Mod that aims to improve the experience

Required Blocks

– Power
– 1 Cockpit
– 1 Programmable Block
– 2 Hip Actuators
– 2 Knee Actuators
– 2 Foot Pitch Actuators
– 1 Remote Control
– some Gyroscopes (about 1-2)

First Setup

I recommend holding your mech upright in the air in a planets gravity by using landing gears or scaffolding.

– Load the Script on a Programmable Block.

– either change ‘cockpitname’ or change your Seats name to ‘Mech Cockpit’
-> Debug Screen in the Terminal should be filled with info

– make sure the Remote Control is on the same grid as the Hip Actuators and faces forward
– The Terminal should read ‘Balancing active’
if not then check the Blocks name (either that or in the script)

Leg Types

The Script distinguishes between two types,
– knees looking forward
– knees looking backward

in the script, change the value ‘kneesforward’ to the one that fits your design. true/false

Setting up Actuator Limits

only care about the Hip and Knee Actuators for now

– Set the Limits to what you would expect as the physical limits, cannot be set to unlimited!

– add Tags to the Actuators names.

Right Leg:
Hip: HR+
Knee: KR+

Left Leg:
Hip: HL+
Knee: KL+

Multiple Actuators can/should be a*signed the same Tag if they have the same task and are placed in parallel

– the Actuators will now a*sume a default stance which is in the middle between the upper and the lower limit.

– tweak the Limits until you have a satisfying symmetrical idle stance

First Testing (Crouch / Stretch)

Get in the Cockpit and move up and down (Spacebar and C on PC)

The Mech should now crouch / stretch accordingly.

If an Actuator turns the wrong way, change the + in the Tag to a –
(for example HR+ to HR-)

Test again until its right

Foot Pitch Actuators

now add the Tag FRP+ or FRP- and FLP+ or FLP- to the Foot Actuators

the feet should now align to be parallel to the grid the legs are mounted on.

if not, change ‘leftfootpitchanglecorrection’ and ‘rightfootpitchanglecorrection’ by +/- 90 degrees

Test Stretching / Crouching again, change + to – and vice versa if rotation is inversed.

The Mech should now be able to stand by its own, crouch and stretch, also walk forward and backward, balance out when standing on an incline and aim up and down with its torso.

Optional Features

Below are all features that could be solved otherwise or are not required to use script

Turning and Stability

If your mech has Torso Twist, name the according Actuator TT+ or TT- , recompile the script
Test and rename if inversed.

To turn the Mechs legs we will be using a Rotor that is mounted on the Lower Torso and facing up or down
– tag it with -GA
– enable inertia tensor
– mount a gyroscope with override enabled
(can be multiple rotors)

if inverted, negate the value ‘gyrorotorspeed’

If there is no Torso Twist in your Mechs design, simply just dont use TT+ and TT- and -GA, for stability you can leave the rotor with low to no torque

Turn Stepping / Strafing

Depending on whether you have Torso Twist or not your Mech will use certain Actuators for Turning or for Side Strafing.

For the next Section we will use the tags -FRJ and -FLJ for this purpose.

If you have Torso Twist
and you have Actuators that can turn the Legs/Feet, tag them with the above mentioned terms.

If they turn the wrong way when turning the Mech (A and D), you can either switch them out or negate the value ‘footturnspeed’ in the script.

This can aid in the Mechs Turn Speed or make it look cooler while doing so.

If you dont have Torso Twist
and you have Actuators that can move the Legs inward / outward, tag those.
Instead of Turning, the Mech should now Strafe when holding A or D.

While doing so, use the gyroscopes on your torso to turn and aim your Mech (Mouse).

Trottle Decay

Simply add a non-functional Thruster anywhere on/in the torso, it will enable you to use inertia dampeners, if they are turned on, letting go of W or S will slow the Mech down and bring it to a halt.

Jump Jets

Adding a few thrusters will give the mech the ability to jump
– add thrusters facing down (some should be placed on legs)
– add -JJ to their name

all other thrusters will be disabled, the Jump Jets will decrease in thrust while being used and increase while inactive, this is just so Mechs shouldnt be hovering constantly

Arms Swing

use the Tags SR+ / SR- and SL+ / SL- for your Shoulder Actuators, they will imitate Hip Movement.

use the Tags ER+ / ER- and EL+ / EL- for your Elbow Actuators, they will counter the Shoulder Movement to stay parallel to the torso.

use HSR/HSL +/- if you have your shoulders on your hip subgrid and want to counteract that

Weapon Convergence

When mounted parallel, Weapons wont ever hit the same spot, for this reason I added a simple way to make the shots cross at a certain distance that you can adjust on the fly.

This requires 1 Actuator per Arm with a vertical rotation axis.

– change ‘armswidth’ to how far your arm mounted guns are away of each other.

– adjust the default ‘defaultdistance’ to whatever distance you think fits for your Loadout.

– Tag those Actuators with AJ+ and AJ- (dont need both to work)

In your Toolbar, set up a Button to Run the Programmable Block, for the argument use:
– ‘range+’ to increase the distance
– ‘range-‘ to decrease the distance
– ‘range=’ to reset the distance

Additional Arguments

Run the programmable block with:

– ‘centerlegs’ to quickly return your legs to be facing forward
– ‘transport’ to toggle a mode where the mech is crouching and holding its legs still, also reenables thrusters to be used for flight

Magnetic Feet

tag Landing Gears on the soles of your mechs feet with -LGR / -LGL to make the script use them

toggle handbrake in your cockpit to toggle using them

while enabled, balancing will be inactive

you can use this and the transport argument to clamp down mechs to transport them safely via ship

Triggering Timer Blocks

Timer Blocks can be tagged with

-FT for Forward Input
-BT for Backward Input
-LT for Left Input
-RT for Right Input
-UT for Upward Input
-DT for downward Input
-ST for when the Mech has halted
These are triggered constantly

-SWT for when the mech has started walking
this one triggers just once

Advanced Features

– set ‘usefootpitch’ to false to disable automatic foot movement.
– set ‘scriptanimations’ to false if you want to use timer or other scriptbased animations

Happy Mech’in

it is the 31st century, and mankind is once again, at war…

Written by Beesoldier

Here we come to an end for Space Engineers BattleMech Script Tutorial and All Workshops List Guide hope you enjoy it. If you think we forget something to include or we should make an update to the post let us know via comment, and we will fix it asap! Thanks and have a great day!

Be the first to comment

Leave a Reply

Your email address will not be published.