Due to increasing spam attacks, forum registrations are currently paused to keep our community safe and spam-free. Come hang out and stay connected with us on the SimHub Discord: https://discord.com/invite/nBBMuX7!
Catch you on Discord — and thanks for understanding!
Catch you on Discord — and thanks for understanding!
Notifications
Clear all
Topic starter
19/12/2020 1:33 am
I have a multi-frame animation I want to change with pedal input but I'm really new to this. The first way I'd think of doing it is to translate an atlas texture strip X pixels on X pedal pressure but I'm not sure I can do that in a step in Simhub and I'm not sure if this is the most efficient way to go about this. Any help appreciated
Topic starter
19/12/2020 3:44 am
ok - I figured it out. If I use Javascript expression on the vertical translation, I can do a rough animation using a filmstrip like this:
if ($prop('DataCorePlugin.ExternalScript.Steering_Wheel_Angle') < -23) {
return -168
}
if ($prop('DataCorePlugin.ExternalScript.Steering_Wheel_Angle') < -79) {
return -224
}
if ($prop('DataCorePlugin.ExternalScript.Steering_Wheel_Angle') < 23) {
return -112
}
if ($prop('DataCorePlugin.ExternalScript.Steering_Wheel_Angle') > 23) {
return -56
}