Space Engineers

Space Engineers

Realistic suspension
65 Comments
Skleroz  [author] 10 Jun, 2022 @ 1:32am 
В ближайшее обозримое будущее дорабатывать не буду, для этого нужно свободное время. Поддерживаю их по мере возможности, чтобы не ломались.
zabavski84 9 Jun, 2022 @ 6:18pm 
Да и описание было бы не плохо обновить)
zabavski84 9 Jun, 2022 @ 6:17pm 
@Skleroz а, теперь понятно, там вроде ещё и лимит скорости нельзя менять. Ладно, буду пользоваться тем что есть. Дорабатывать скрипт ещё будете?
Skleroz  [author] 9 Jun, 2022 @ 3:31pm 
@zabavski84 stop сбрасывает внутреннюю логику скрипта, по идее, это не должно влиять на параметры подвески.

Касательно параметров подвески - часть из них удаляли, в т.ч и гашение со скоростью поворота оси. Сами параметры остались, но они не меняют харатеристик подвески, поэтому я их и не удалял.
zabavski84 9 Jun, 2022 @ 1:01pm 
@Skleroz играю на русской версии. Можешь объяснить что именно делают параметры - -SR - Steer Return Speed и -D - Damping?
zabavski84 9 Jun, 2022 @ 12:55pm 
Скрипт хоть и старенький, но очень даже рабочий и полезный. Избавил меня от большинства головняков. Лучше для моих задумок не нашёл.
zabavski84 9 Jun, 2022 @ 12:51pm 
@Skleroz Понятно, спасибо за пояснение. А вот ещё повторное, использование команды stop, сбрасывает текущее состояние. Это на какие параметры, стоковые, или как раз на те что прописаны в названии подвески?
Skleroz  [author] 9 Jun, 2022 @ 12:13pm 
@zabavski84 Привет. Третья переменная добавлена была для проверки длительности прохождения скрипта, это средневзвешенное время работы скрипта.

Срипт достаточно старенький, параметры распределчет сразу на все колеса и вроде как одинаково, без учета ЦТ, так что с индивидуальными настройками подвесок, боюсь, работать он не сможет.

Таймеры вроде не нужны, но мешать работе они не смогут, если что.
zabavski84 9 Jun, 2022 @ 11:50am 
Да, и таймеры как я понял уже не обязательны?
zabavski84 9 Jun, 2022 @ 11:50am 
Привет. В "переменных для точной настройки" в верху скрипта есть третья переменная, за что она отвечает? - Adjustable parameters
const double dForce = 100; //Upper value for strength increase
const double dSafeSpeed = 2; //Limit for verticals speed, after it suspension strength will be encreased
double dA = 0;

И ещё вопрос - если у меня передняя и задняя подвески по разному настроены, как можно их прописать в "преднастройки", или переключаться на них (изначальные)? В описании "преднастройки" влияют на все подвески.
Skleroz  [author] 2 Jan, 2022 @ 12:12am 
@big_blue_4101 Hi! Unfortunately, no, such functionality requires information regarding wheel block coordinates and coordinate changes at least.
big_blue_4101 1 Jan, 2022 @ 7:51pm 
don't know if this has been asked yet. but does this script detect when one or more wheels are not in contact with the ground and auto adjust to bring them back in contact with it?
xpgx1 29 Aug, 2021 @ 7:02am 
Got it =) I was just looking for a solution that's much more straight forward. Thx for considering it, it _is_ pretty "old" now. No need to revampt everythang, it is a niche solution anyway ^-^
Have a gr8 one :selike:
Skleroz  [author] 29 Aug, 2021 @ 6:28am 
@xpgx1 Hi! The whole idea originally was to change settings of the all suspensions on the grid from the list of presets. Like switching gears or something similar. Also, script has some environment handling, don't know, how efficient it works with current version of SE, but at least it worked. List of presets is stored on text panel, so it could be copied and pasted, if needed, this is as much plug and play as it could be, when we are talking about custom grid with unknown parameters. Creating sub-presets for the specific wheel group - this could work for some specific needs, when grid is really unbalanced. And for such situation automatic adjustments, according to the Center of Mass and wheel grip will be more appropriate. Unfortunately, it will take quite some time to re-write it and increase complexity, this script is 5 years old after all =)
xpgx1 23 Aug, 2021 @ 11:04am 
Hey - great script for rather advanced or specific needs =) Could you please work on simplifying the script? I'm having trouble getting the thang to work ^^
In my juvenile madness - I'd propose an argument approach: Just give the user the ability to define profiles for a specific suspension tag, like "[SUSP-01]", and give him the ability to simply hand over an argument to the PB like "set [Profile 01] [SUSP-01], [SUSP-02]". In the code or the custom data box are the profiles and tags defined. This would enable users to pretty much plug and play. We could even share profiles rather easily :hardhat: This would enable you to use super fine tuned profiles for each and every suspension block.

In any case, thank you for sharing this with us :selike:
Skleroz  [author] 8 Nov, 2020 @ 1:29pm 
mkahmvet Hi! Yes, It is no longer needed. I can't find template for this workshop page, as soon as got backup from my old computer, I'll update description.
Skleroz  [author] 8 Nov, 2020 @ 1:28pm 
$anqtuarium Yep, code is not optimized, kinda slow for modern requirements =)
mkahmvet 3 Nov, 2020 @ 9:23am 
Does the auto-start mean a timer block is no longer needed?
Sanki 2 Nov, 2020 @ 8:40am 
Awesome! Thanks! it shows the "ms 0.200~" I hope that's good, didn't notice any stutters, driving is now glorious! :selike:
Skleroz  [author] 1 Nov, 2020 @ 2:40pm 
$anqtuarium Well, it was simple to correct. I added avg runtime and auto-start. Should help with this issue =)
Sanki 1 Nov, 2020 @ 11:30am 
I can't say if this is working as intended but I can notice much better behavior of wheels on different terrains, sadly the programmable block says nothing about if the script is running or not, there are no errors tho...
Skleroz  [author] 1 Nov, 2020 @ 11:17am 
$anqtuarium Thank you! It is not so useful since Keen removed part of the suspension settings, but I'll try to keep it updated/
Sanki 1 Nov, 2020 @ 11:03am 
this script works very good! nice instructions easy setup I like it! I couldn't find any other script like this one.
Skleroz  [author] 4 Sep, 2019 @ 12:01pm 
Juliusz Ave You are welcome!
SOBEK 3 Sep, 2019 @ 10:23pm 
Thanks for update :steamhappy:
Skleroz  [author] 3 Sep, 2019 @ 11:21am 
Juliusz Ave Hi! Totally forget about this script! Updated.
SOBEK 2 Sep, 2019 @ 10:21pm 
Hi , script work after new economy update ? I have warning after check script , some public lcd massage obsolate. What is this ?
Skleroz  [author] 19 Apr, 2019 @ 9:00am 
Church.exe Hi! Wow, thank you! Didn't expect, that it will be in working condition till now =)
Church.exe 18 Apr, 2019 @ 8:48pm 
this is effing amazing, my rover base went from failing to do literally anything to being able to climb mountains (not the huge icy ones, the moderate mountains in the plains area) with relative ease
JDaremo Fireheart 29 Mar, 2019 @ 5:42pm 
What's up with the new Workshop Name for this script?
Nice Bump! (chat off) 14 Mar, 2019 @ 5:36am 
Таймер все еще нужен? Он уже не нужен для скриптов и только раздражает.
DaRa 13 Oct, 2018 @ 2:45pm 
Hello,
I tried on a few of my SUV and I always get the same error in the programmable block bottom right section from terminal :
"Caught exception during execution of script : invalid property at Sandbox.ModAPI.Interfaces.TerminalPropertyExtensions.Cast[TValue]TerminalPropertypropertyà at Program.Main(StringArgument)....
https://imgur.com/a/VS8Efn0
I followed step by step your instructions and made sure I am the owner.
Any idea what's going on please ?
Skleroz  [author] 16 Oct, 2016 @ 11:38pm 
@tyriael_soban Hi! Unfortunately, this functionality will be useless. Script moves active preset to the first row and comment in separate row will become incorrect, when you choose commented preset. You can add comment to the end of preset, using ":" as separator, It should be Ok for script and comment should stay with preset.
tyriael_soban 16 Oct, 2016 @ 10:22am 
Is there a way to make the script ignore a line in the preset memory?

Ive been playing around with an articulated truck concept and the script obviously only runs specific variables, so i put in a line that says "Settings for use with attached trailer only" and the script cant use anything i put after that, i wanted to put in some settings that were aimed at using a loaded articulated trailer, but leaving an explanation as to what the settings were for.
Skleroz  [author] 19 Aug, 2016 @ 12:34pm 
@AllKnight Not an error, just warning about unused variable. Nothing to worry about =)
AllKnight 19 Aug, 2016 @ 10:58am 
Thanks Skleroz! I'm still getting an error when compiling it, but it doesnt seem to affect the basic functionality. Maybe somthing to do with the presets?
Skleroz  [author] 18 Aug, 2016 @ 10:04pm 
@AllKnight Hi! Looks like fixed.
AllKnight 18 Aug, 2016 @ 4:27pm 
Broken as of Today :(
Plz Fix :reheart:
Vandolizm 12 Jul, 2016 @ 11:02pm 
Dude! Your mod is amazing! I can do jumps and not explode easily!
tyriael_soban 26 Jun, 2016 @ 9:37am 
@Skleroz, i actually did get it to work in the end, i didnt realize the script was run each time you pushed a g:up/g:down timer.
Also, a "Range" is a preset in a 4x4 or semi tracktor that discerns what gear drives your transmission, the low range gearing is much smaller and is used for offroad driving, the high range gearing is suited for highway driving.
Look up how an EATON 18 speed semi tractor transmission functions, it might explain it better than i can.
Skleroz  [author] 26 Jun, 2016 @ 7:48am 
@tyriael_soban Hi! Not so sure, that my video guides will be helpfull, I'm not so good in descriptions. At least, this problem helped me to simplify setup to phrase "add "X" to block's name and script will detect it" XD

About "range" mode... do you need to change suspension's parameters? At this moment it is possible in manual mode, using presets. It was quite easy and effective method to adjust suspension to different conditions, without long setup process and messing with script.
tyriael_soban 15 Jun, 2016 @ 6:17am 
I got it working anyway, but id still leave that as a pretty good suggestion.
Furthermore; do you have any plans to add a "range" mode to the script, allowing further manipulation of power and traction settings? (kinda like how a semi-trucks transmission works high/low range for different terrain types/traction and weight capacity, or some 4x4 trucks too)
tyriael_soban 15 Jun, 2016 @ 5:40am 
Can i request a video guide?
People with minds like mine dont work very well when it comes to verbal instructions, but if i see someone else doing it, ill be able to figure out how it works.
Skleroz  [author] 28 May, 2016 @ 12:49am 
@ Zeinder Thank you very much! I really didn't expet this script to be so useful. Will try to do my best and create something interesting =)
Zeinder 27 May, 2016 @ 7:28am 
Hey there, I just want you to know that I found your awesome script by grabbing a blueprinted car used in a patch video (ALB Marauder 3, if you were curious). I can't believe how well this works. Keep up the good work sir.
Skleroz  [author] 23 Apr, 2016 @ 11:30pm 
@ Benie. The adjustment part of the script not so hard to read, but it mixed with parts for smooth turning and presets changing. This part only adjusts strength and dumping, according to car's vertical speed, you still need to make some initial configuration for suspensions.
BenieTheDragon 23 Apr, 2016 @ 10:15pm 
Hmm.. this looks interesting. Is this script hard to understand? Find it interesting how you say it will adjust strength and stuff like that...for you, as in automatic? As in, it will do all the wheel settings for me?
Skleroz  [author] 17 Apr, 2016 @ 10:37am 
@fjakk Not a problem! I'm glad to help! Oh, I forgot to change description for this part, my bad. :steamfacepalm: I had to switch script from mass calculation to speed for two reasons: 1. You have to change blueprint or use mod to put Terminal Block on wheel, to calculate car's mass. Not so good for people, who prefer modless game. 2. Car was really bouncy, when you hit the ground, or even drive fast. It wasn't so hard to jump 300m+, using old calculationn process.
Krem 17 Apr, 2016 @ 9:51am 
Yes that's exactly what I want, I had that enabled, but maybe it didnt give the script time to properly boot :) Thank you very much, and I got the presets working correctly now, thank you for that too :) Although, I have one more question, you say in the description that "-Adjusts strength parameter of the suspension, according to car's weight." Is this true ? Does it do that automatically all the time ? I.E if I put a lot of weight in the cargo containers of my car will the script automaticlly set the correct strengt ?
Thank you againi for all your help

-Best Regards
Skleroz  [author] 17 Apr, 2016 @ 8:41am 
@fjakk If I understand situation correctly, you want this script working after ship copy/paste or world reload? Thi is not a problem, you just need to put timer for this script on self-repeating ("Start" itself). This procedure remains active even after copy/paste, script will be reloaded correctly after 2 seconds.