Tween:wait
method#Pauses the script until the tween ends, then carries on.
Tween:wait() -> ()
example
tween:wait()Use it forletting a door open all the way before players can walk through.
A movement or color change that is playing on an instance, which you get back from Instance:tween.
You listen to these with :connect, which the Event page covers.
Pauses the script until the tween ends, then carries on.
tween:wait()Use it forletting a door open all the way before players can walk through.
Stops the tween where it is, so the instance stays at that point.
tween:cancel()Use it forstopping a closing door when someone steps underneath it.