Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local positions = game.Workspace.positions
- local place1 = positions.place1
- local place2 = positions.place2
- local place3 = positions.place3
- local place4 = positions.place4
- local place5 = positions.place5
- local place6 = positions.place6
- local place7 = positions.place7
- local place8 = positions.place8
- local place9 = positions.place9
- local runService = game:GetService("RunService")
- local debounce = false
- script.Parent.Touched:Connect(function(hit)
- if not debounce then
- local playerName = hit:FindFirstAncestorOfClass("Model").Name
- local timeOnCross = game.Workspace.timeValue
- if place1.placeValue.Value == "" then
- local placeValue = place1.placeValue
- placeValue.Value = playerName
- local timeValue = place1.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place2.placeValue.Value == "" then
- local placeValue = place2.placeValue
- placeValue.Value = playerName
- local timeValue = place2.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place3.placeValue.Value == "" then
- local placeValue = place3.placeValue
- placeValue.Value = playerName
- local timeValue = place3.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place4.placeValue.Value == "" then
- local placeValue = place4.placeValue
- placeValue.Value = playerName
- local timeValue = place4.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place5.placeValue.Value == "" then
- local placeValue = place5.placeValue
- placeValue.Value = playerName
- local timeValue = place5.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place6.placeValue.Value == "" then
- local placeValue = place6.placeValue
- placeValue.Value = playerName
- local timeValue = place6.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place7.placeValue.Value == "" then
- local placeValue = place7.placeValue
- placeValue.Value = playerName
- local timeValue = place7.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place8.placeValue.Value == "" then
- local placeValue = place8.placeValue
- placeValue.Value = playerName
- local timeValue = place8.timeValue
- timeValue.Value = timeOnCross.Value
- else
- if place9.placeValue.Value == "" then
- local placeValue = place9.placeValue
- placeValue.Value = playerName
- local timeValue = place9.timeValue
- timeValue.Value = timeOnCross.Value
- end
- end
- end
- end
- end
- end
- end
- end
- end
- runService.Heartbeat:Wait()
- debounce = false
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement