Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- skatedamage = false
- local player = game.Players:FindFirstChild(script.Parent.Player.Value)
- local character = player.Character
- if not character or not character.Parent then
- character = player.CharacterAdded:wait()
- end
- game.Workspace:WaitForChild(character.Name)
- hitvalue = false
- local list = {}
- table.insert(list, "Spooky")
- script.Parent.Touched:connect(function(hit)
- if skatedamage == false then
- local ehum = hit.Parent:findFirstChild("Humanoid") or hit.Parent.Parent:findFirstChild("Humanoid")
- print(ehum.Parent)
- skatedamage = true
- if ehum and ehum ~= character.Humanoid then
- stringvalue = ehum.Parent.Name
- hitvalue = false
- for owo = 1,#list do
- if list[owo] == stringvalue then
- print("Hit Before")
- print(list[owo].."owo")
- hitvalue = true
- end
- end
- if hitvalue == false then
- table.insert(list, stringvalue)
- ehum:TakeDamage(30)
- ehum.Sit = true
- local vel = CFrame.new(ehum.Parent.HumanoidRootPart.Position,character.HumanoidRootPart.Position).lookVector
- ehum.Parent.Head.Velocity = vel * math.random(100, 200) * -1
- end
- skateboydamage = coroutine.wrap(seriously)
- skateboydamage()
- end
- end
- end)
- function seriously()
- wait(0.1)
- skatedamage = false
- end
Advertisement
Add Comment
Please, Sign In to add comment