For some strange reasons, the For loop doesn’t run to the end.
Example:
for i = 0, 1, 0.05 do
frame.BackgroundTransparency = i
wait(0.05)
end
The background transparency is supposed to end up at 1, but when I checked in the explorer, it showed 0.95. Is this a bug because when I tested the code with integers it worked fine?
It should be fine, try placing the yield in front of the loop;
for i = 0, 1, 0.05 do
wait(0.05)
frame.BackgroundTransparency = i
end
Additionally, it seems as if you’re trying to tween background transparency straightforward, you may want to consider TweenService instead for this as it can create smoother transitions, animations and effects.
In that case, test with a goal of 1.05, integers divided by integers, or a different loop that changes a created variable before the loop instead to see any difference.