Space Engineers

Space Engineers

1,158 ratings
SWCS | Whip's Subgrid Wheel Control Script
7
3
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
810.377 KB
19 Jul, 2018 @ 5:20am
18 Apr, 2023 @ 4:51pm
13 Change Notes ( view )

Subscribe to download
SWCS | Whip's Subgrid Wheel Control Script

In 1 collection by Whiplash141
Whip's Scripts
22 items
Description

  Description

This script allows you to control steering and propulsion of wheels attached via pistons, rotors, or hinges using regular movement keys! Wheels will also emulate brake inputs as well.

The acronym is pronounced like "swicks" :)

This is a feature we have been dying for for ages, and Keen has finally allowed this control in the new MP update :D




  How Do I Use This?!
Setup
  1. Place this script on your ship with subgrid wheels
  2. CHECK OWNERSHIP
  3. Enjoy!

Seat Priority
Seat prioritization closely matches vanilla for simplicity. In order of highest priority to least:
  1. The main cockpit on the ship
  2. The first controlled seat that can control wheels
  3. The first seat the code finds

Other Features
  • You can configure variables like the braking constant in the Custom Data of the programmable blocks this runs from
  • Handbrake (P or toggling handbrake on for the seat that you are controlling the wheels from) is synchronized across all ship controllers on the grid. If you place remote controls on the subgrids that have wheels, this will make the parking brake much more effective!


  How the heck does braking work?
Poorly. This is because of several things:
  1. There is no brake toggle option for individual wheels. To apply brakes to a wheel, you must do that via a ship controller.
  2. A ship controller can only apply brakes to the wheels on its grid
  3. As of update 1.199, ship controllers with no wheels on their grids can no longer be used to read braking information

Handbrake
If you hold space...
Hand brakes will be enabled for the duration of the keypress.

Toggling Parking Brake
If your main ship controller has no wheels on its grid...
To toggle parking brake, you must use one of the following script arguments:
brake_toggle brake_on brake_off
If your main ship controller does have wheels on its grid...
To toggle parking brake, hit the

key (default parking brake key)

How Brakes Are Applied
If your subgrid wheels are on the same grid as a ship controller...
When parking brake is toggled, the ship controller will be used to turn brakes on for that grid's wheels.
If your subgrid wheels are on not the same grid as a ship controller...
When parking brake is toggled, the script will attempt to approximate parking brake by controlling the wheels to slow you down. This is less effective than the alternative, but it is better than nothing.


  Author's Notes

I hope y'all enjoy this! I've had a framework waiting for ages on the chance that this functionality would be added, so I was ecstatic when I saw that these functions were in the MP test branch!

I tried to make this script crazy simple to configure, so I hope it doesn't backfire XD

There is no brake override (the checkbox in terminal is something completely different), so I had to improvise. It isn't perfect but it works.

Be sure to report any bugs below in the Bug Reports discussion.

(Also, this should also go without saying, but do not reupload without explicit permission from me, not even to mod.io.)

Popular Discussions View All (5)
52
14 minutes ago
PINNED: Bug Reports
Whiplash141
8
22 Nov, 2021 @ 6:44pm
PINNED: SWCS Creations!
Whiplash141
1
25 Aug, 2020 @ 2:22pm
Great Concepts I have for. Scripts
mhwyoshi
517 Comments
Whiplash141  [author] 8 Jul @ 2:48pm 
Scripts are vanilla; however, I don't know anything about subgrid control without scripts.
Kywau Cyn4uk 8 Jul @ 9:32am 
This is a feature we have been dying for for ages, and Keen has finally allowed this control in the new MP update :D
Does it mean I can somehow make it in vanila without this script? (Without scripts at all to be clear)
Grebanton1234 28 Jun @ 1:22pm 
Thank you very much!
Whiplash141  [author] 28 Jun @ 12:27pm 
You can use my scripts however you want, I don't even need attribution since that lives in the script itself. If you create derivative work (like modifying the actual script), I only ask for attribution and a clear indication that the work is not officially supported by me.
Grebanton1234 27 Jun @ 11:46am 
Hey there, may I use your script for the current research bunker competition? I think legally I have to ask you for permission because I think by submitting the build I give Keen the right to use it how they want to.
godsshadow755 3 Oct, 2024 @ 1:53am 
ok i got it had to put the arguments in custom data then toobar the run PB Argument Brake_toggle, then everything started working right
godsshadow755 3 Oct, 2024 @ 1:39am 
where do i put the arguments do i put it in the custom data of the cockpit or the program block itself?
Whiplash141  [author] 2 Oct, 2024 @ 11:47pm 
have you read the entire "How the heck does braking work" section above?
godsshadow755 2 Oct, 2024 @ 11:03pm 
cant seem to get the braking to work on sub grids, I put that argument in the cockpit but I cant turn brakes on
OVERLORDTHOR 23 Sep, 2024 @ 10:45pm 
Is there a way to get this working with remote control?