Right now, my script looks like this:
1 | if script.Parent:GetTouchingParts( nil ) then |
2 |
3 | end |
But that doesn't work. How would I make it so that it works?
try to check if the length of the table that GetTouchingParts()
is returning is equal to 0:
1 | if #script.Parent:GetTouchingParts() = = 0 then |
2 |
3 | end |
1 | local IfTouchingPart = script.Parent:GetTouchingParts() |
2 |
3 | if not IfTouchingPart then |
4 | -- Code if nothing is touching the part |
5 | end |