Space Engineers

Space Engineers

391 ratings
Cockpit Piston, Rotor & Hinge Controller
2
9
2
2
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
410.705 KB
3 Jun, 2019 @ 11:56am
11 Feb, 2023 @ 12:35pm
13 Change Notes ( view )

Subscribe to download
Cockpit Piston, Rotor & Hinge Controller

Description
Script for controlling Hinges, Rotors and Pistons from a cockpit or remote control, using the regular movement keys, allowing for control of up to 6 groups of rotors or pistons!

Supports: Cockpits, Seats, Remote Controls and Custom Turret Controllers as inputs.

If you have changed key bindings, use whatever you have assigned.
If you're using a controller, the pistons may move quite fast, you can change the multiplier to fix this :)

The valid controls (with default key bindings) are:
A & D
W & S
Q & E
Space & C
Mouse X-axis
Mouse Y-axis

Individual blocks in a group can have their input reversed by adding "rev" to their custom data.

Adjustable values in the script are:
- The names of blocks / groups - to be left blank to disable an input.
- Speed multipliers for each control input
- Acceleration for pistons and rotor/hinges respectively

Comments in the script should explain usage.
If you type a name wrong, the programmable block will throw an error telling your what is wrong.

Quick example build using the script:
https://gtm.steamproxy.vip/sharedfiles/filedetails/?id=2176469225

MP REMINDER:
When using the script in MP, the controller (cockpit, seat, remote) should be on a dynamic grid.
That means Small grid, Large grid ship/rover or a Sub-Grid of a base/station.

The reason for this, is that the game does not seem to transmit movement info from controllers placed directly on static (station) grids, presumably because Keen thought it would be a waste of data to send movement info for something that can't move, which makes sense, but does mess with my script!
254 Comments
RAD 21 Sep @ 5:14am 
Hi Tekk,

Need some help.

Upper and lower limits keep getting reset. I have the elevation rotors set to a group and use the group in the PB.

The rotors have opposing limits i.e. rotor a -32 & 60 vs rotor b -60 & 32. Thus, I need to set each limit via each block individually not via the group. But the same even happens with the rotation rotor. Any help working around this?
xXxD0z3r38xXx 13 Sep @ 10:44am 
It still works great for me since the Apex update.
Questionable Medic 9 Sep @ 11:39am 
might be a me thing but as of Apex update doesnt seem to work, rebuilt a whole system and still no fix
Caazego 10 May @ 10:55pm 
@bowan if you subscribe to the script then search your game installation drive for "1760157651" you will find a directory. Open the file Script.cs in that directory and you can do the copy/paste yourself.
Bowan 3 May @ 2:50pm 
can someone copy paste the entire script please its not allowing me to upload the script in my server even though I have them enabled.
Naix 16 Jan @ 9:28am 
//Block/group names (eg. "Piston 2"), leave empty (eg. "") to disable that output
string AD_Name = "Crane Hinge Wrist 3"; //Name of A & D Block / Block group
string WS_Name = "Crane Pistons Forward"; //Name of W & S Block / Block group
string QE_Name = "Crane Advanced Rotor Wrist"; //Name of Q & E Block / Block group
string SpaceC_Name = "Crane Hinge Wrist Middle"; //Name of Space & C Block / Block group
string MouseX_Name = "Crane Advanced Rotor Rotate"; //Name of MouseX/LeftRight Arrow Block / Block group
string MouseY_Name = "Crane Piston Support"; //Name of MouseY/UpDown Arrow Block / Block group
Naix 16 Jan @ 9:28am 
//Speed multipliers - negative values invert direction
double AD_Movespeed = 10.0; //A & D speed multiplier.
double WS_Movespeed = -2.0; //W & S speed multiplier.
double QE_Movespeed = 10.0; //Q & E speed multiplier.
double SpaceC_Movespeed = 2.0; //Space & C speed multiplier.
double MouseX_Movespeed = 0.1; //MouseX speed multiplier.
double MouseY_Movespeed = -0.1; //MouseY speed multiplier.
Naix 16 Jan @ 9:28am 
For me is Working very nice :D
"reverse mouse is fixed :D" you just need to reverse double Mouse X and Y and string mouse X and Y.
Upscale135 8 Jan @ 8:15pm 
To add below you can not individually rev the mouse axi and the up down left right keys. pretty sure the axi is base on those keys as well
Upscale135 8 Jan @ 8:11pm 
Flawless absolutely what was needed. For those who cant get it to work you need to name each (joint) rotor hinge ect. then go into the scrip and insert the names in between the "" example

Correct:
string AD_Name = "base rotor"; //Name of A & D Block / Block group
string WS_Name = "Hinge"; //Name of W & S Block / Block group
string QE_Name = "Pistons2"; //Name of Q & E Block / Block group
string SpaceC_Name = "Pistons"; //Name of Space & C Block / Block group
string MouseY_Name = "neck"; //Name of MouseX/UpDown Arrow Block / Block group
string MouseX_Name = "Hinge3"; //Name of MouseY/LeftRight Arrow Block / Block group
string BN_Name = ""; //Name of B & N Block / Block group