Hello I’m Ryxku and I wanted to make a tween service move with a character which moves in constant but the output says Constant doesn’t exist, that’s weird that’s not a thing out of Animation Editor :
It makes sense to have a “step” type easing style for animations. I don’t think the request is related to tweens, and the usecase for tweens is unclear since it would only be used for a single motion, unlike an animation where many motions are choreographed together.
The animation editor’s “Constant” easing-style is not a “step” style (where progress would be stepped between [0, 1]), it is the same as just a single property set.
This feature request is also in direct relation to tweens because of the nature of the Enum itself, which is used specifically for TweenService and other Tween functions.
The main point is that this Feature Request is needless, a single property set would be the same as what this is suggesting (if in the context of TweenService or any other Roblox provided tween function).
This cannot be a tween style because there are no keyframes–or points–to jump to. It is equivalent to changing the position property of a part, waiting a few seconds, and repeat.
Just because it acts like something else does not mean that it shouldn’t exist.
Take this hypothetical example:
math.sqrt(4) == 4 ^ 0.5
They’re both the same thing. Imagine the exponent was a variable:
local foo = 4 ^ x
But, because sqrt already exists, the developers of Lua decided to not allow anything to the power of 0.5. This is dumb, because now you have to do something like this:
local foo
if x == 0.5 then
foo = sqrt(4)
else
foo = 4 ^ x
end
Instead of:
local foo = 4 ^ x
Reason being, if we so happen to allow for variable modifications, it would be quite a hassle. Take a look at a use case in the thread I posted:
“Use-cases” and as far as I read there is only one, and that is to make your data format more consistent; which btw, can easily be done with just “Enum.EasingStyle?” typing. From what it looks like, it’s more of an implementation concern on the users end than Roblox’s.
Every Enum Roblox has is used by them (which is why they exist), there’s no reason for Roblox to have this Enum on their backend, especially in the context of which it is already used.
An enum is less than negligible in terms of performance. It only requires a few bytes of memory. It doesn’t take a minute to add, either.
An implementation concern is quite a valid concern. Especially for programs that want to juice out as much speed as possible. Checking if a string is equal to “Constant” is quite a bottleneck to performance. Instead of having to run zero if statements every frame, you’d have to run one if else block as well as set up more boilerplate code. Especially for the example I listed, if you make a custom animation serializer, you’d have to painstakingly take that into account as well.