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

Why wont my script end? i am making a part that will increase max zoom onTouch [closed]

Asked by 3 years ago















local function onPartTouch(otherPart)

local partParent = otherPart.Parent
local humanoid = partParent:FindFirstChildWhichIsA("Humanoid")

if ( humanoid ) then
game.StarterPlayer.CameraMode = Classic
game.StarterPlayer.CameraMaxZoomDistance = 100
         end
     end 







Part.Touched:Connect(onPartTouch())
end)   

Closed as Non-Descriptive by Nguyenlegiahung and JesseSong

This question has been closed because its title or content does not adequately describe the problem you are trying to solve.
Please ensure that your question pertains to your actual problem, rather than your attempted solution. That is, you were trying to solve problem X, and you thought solution Y would work, but instead of asking about X when you ran into trouble, you asked about Y.

Why was this question closed?

2 answers

Log in to vote
0
Answered by
CedCed6 32
3 years ago

Maybe line 16 and 17 are way too down. Im not really sure....

0
@Ceded6 Nope still has a red line under end, thats ok dangboxxer2786 4 — 3y
0
oof CedCed6 32 — 3y
Ad
Log in to vote
0
Answered by 3 years ago

I'm pretty sure that Part.Touched:Connect(onPartTouch()) should be above if ( humanoid ) then hope this works!

0
It now says"Unknown Global Part" And "Unknown Global Classic" dangboxxer2786 4 — 3y