Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
-1

Repeat until StoppedTouching?

Asked by
KAAK82 16
10 years ago

How exactly would I do this instead of using StoppedTouching:Connect()? cos am not making another function, cos I wanna do stuff until the person stops Touching...

1 answer

Log in to vote
1
Answered by
wazap 100
10 years ago
part.Touched:connect(function(hit)
touch = true
repeat --whatever 
until not touch
end)
part.TouchEnded:connect(function() touch = false end)
0
lol the last line confuses me a lil KAAK82 16 — 10y
0
Well the loop will continue to run until the part.TouchEnded makes touch = false wazap 100 — 10y
Ad

Answer this question