i am making a turretless tank destroyer, but i do not know how to make it behave like it does not have a turret without making it explode or stuff.
i am making a turretless tank destroyer, but i do not know how to make it behave like it does not have a turret without making it explode or stuff.
(edit: oh ok this probably isnt for what you meant sorry) Idk if you've already solved it but I think
smooth(Roll=0?0:sign(Roll),abs(Roll)*X)
for the side to side canon rotation (its like a clamped sum function but better)
and
(smooth(Roll=0?0:sign(Roll),abs(Roll)*X) = 1) ? Roll : ((smooth(Roll=0?0:sign(Roll),abs(Roll)*X) = -1) ? Roll : 0)
for steering the whole tank when it reaches the maximum angle.
X is the speed multiplier, use the same input or number
but in this case
smooth(clamp(99999*Yaw,-1,1),abs(pow(Yaw,2)))
and make sure your rotator is a normal rotator with a input of Yaw, not a hinge rotator, and see that the rotator is set to 25 degrees as your pic shows there
@winterro
smooth(clamp(99999*Yaw,-0.3,0.7),abs(pow(Yaw,2)))
this is one I'm using for a ISU-152
@winterro
yeah, I'll check again, just remember mine isn't an auto-aim one
@THEYE @iniMiiW i tried the codes, but none seem to work? maybe something was spelled wrong?
Hmmm maybe these
((cos(TargetElevation) * TargetDistance)/(cos((atan(((pow(2000,2)) - (sqrt((pow(2000,4)) - (9.81 * ((9.81 * pow((cos(TargetElevation) * TargetDistance), 2)) + ((2 * ((sin(TargetElevation) * TargetDistance))) * pow(2000,2)))))))/(9.81 * (cos(TargetElevation) * TargetDistance))) + rate(TargetElevation) * (TargetDistance / 2000)) / 1) * 2000))
Or these
sum(0.5clamp01(Roll))+(-(sum(0.5clamp01(-Roll))))
It also works for elevation, but just remember to adjust it a bit to fit your needs
smooth(clamp(99999*Yaw,1,1),abs(pow(Yaw,3)))
That's if you want to use Yaw for turret traverse on a tank destroyer but no auto-aim
Oh, wait, auto-aim, nah fam, I don't know auto aim but I could give you something else
clamp it lol
I'll give you a code later when I'm at my computer, sit tight for now :)