i = 5 Local function onTouched(partHit,i) Print(i) game.Workspace. Part.connect(0nTouched(i)) end ————————————————————— What’s wrong with this? I get i = nil inside the function
i = 5 Function onTouched(partHit, i) Print(i) end script~~~~~~~~~~~~~~~~~
.Parent.Touched:Connect(onTouched(i) ~~~~~~~~~~~~~~~~~