Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local damageindicators = require(game.ServerScriptService.Damagehandler)
- local serverdb = {}
- damageindicators.Ready()
- game.ReplicatedStorage.RemoteEvent.OnServerEvent:Connect(function(player, mouse, typew)
- if typew == 1 then
- --blood orb
- if not serverdb[player] then
- serverdb[player] = true
- coroutine.wrap(function()
- wait(5)
- serverdb[player] = false
- end)()
- local borb = game.ServerStorage.Blood.BloodOrb:Clone()
- local bcyc = game.ServerStorage.Blood.BloodCylinder:Clone()
- local char = player.Character
- borb.Position = Vector3.new(char.LeftHand.Position.X + 2.5, char.LeftHand.Position.Y, char.LeftHand.Position.Z)
- borb.Parent = workspace
- borb:SetNetworkOwner(nil)
- local bv = Instance.new("BodyVelocity")
- bv.Parent = borb
- bv.Velocity = (mouse.p - borb.Position).Unit * 80
- bv.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
- local hitdb = {}
- borb.Touched:Connect(function(obj)
- if obj and obj.Parent and obj.Parent:FindFirstChild("Humanoid") and not hitdb[obj.Parent] and obj.Parent ~= player.Character then
- hitdb[obj.Parent] = true
- damageindicators.DealDamage(obj.Parent, math.random(30,50), Color3.fromRGB(189,0,0), Color3.fromRGB(89,0,0))
- coroutine.wrap(function()
- wait(1)
- hitdb[obj.Parent] = false
- end)()
- end
- end)
- game:GetService("Debris"):AddItem(borb, 10)
- end
- end
- if typew == 2 then
- if not serverdb[player] then
- serverdb[player] = true
- coroutine.wrap(function()
- wait(5)
- serverdb[player] = false
- end)()
- local borb = game.ServerStorage.Blood.BloodOrb:Clone()
- local bcyc = game.ServerStorage.Blood.BloodCylinder:Clone()
- local char = player.Character
- borb.Position = mouse.p
- borb.Anchored = true
- borb.CanCollide = false
- borb.Parent = workspace
- coroutine.wrap(function()
- local hitdb = {}
- local b1 = borb:Clone()
- local b2 = borb:Clone()
- local b3 = borb:Clone()
- local b4 = borb:Clone()
- local hittables = {b1,b2,b3,b4, borb, bcyc}
- local bdamage1 = math.random(5,10)
- local bdamage2 = math.random(10,20)
- local bdamage3 = math.random(20,30)
- local bdamage4 = math.random(40,45)
- local cycdamage = math.random(80,160)
- for i,hit in pairs(hittables) do
- game:GetService("Debris"):AddItem(hit, 1 * i)
- hit.Touched:Connect(function(obj)
- if obj and obj.Parent and obj.Parent:FindFirstChild("Humanoid") and not hitdb[obj.Parent] and obj.Parent ~= player.Character then
- hitdb[obj.Parent] = true
- if not obj.Parent.PrimaryPart:FindFirstChild("BodyPosition") then
- local bv = Instance.new("BodyPosition")
- bv.Parent = obj.Parent.PrimaryPart
- bv.P = 1000
- bv.Position = hit.Position
- bv.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
- end
- damageindicators.DealDamage(obj.Parent, math.random(game.ServerStorage.Blood.DamageDataType2["min"..i].Value, game.ServerStorage.Blood.DamageDataType2["max"..i].Value), Color3.fromRGB(189,0,0), Color3.fromRGB(89,0,0))
- coroutine.wrap(function()
- wait(0.3)
- hitdb[obj.Parent] = false
- end)()
- end
- end)
- end
- game:GetService("TweenService"):Create(borb, TweenInfo.new(0.6, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(12,12,12)}):Play()
- wait(0.6)
- b1.Parent = workspace
- game:GetService("TweenService"):Create(b1, TweenInfo.new(0.6, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(15,15,15)}):Play()
- wait(0.6)
- b2.Parent = workspace
- game:GetService("TweenService"):Create(b2, TweenInfo.new(0.6, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(18,18,18)}):Play()
- wait(0.6)
- b3.Parent = workspace
- game:GetService("TweenService"):Create(b3, TweenInfo.new(0.6, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(21,21,21)}):Play()
- wait(0.6)
- b4.Parent = workspace
- game:GetService("TweenService"):Create(b4, TweenInfo.new(0.6, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(24,24,24)}):Play()
- wait(1)
- bcyc.Position = mouse.p
- bcyc.Anchored = true
- bcyc.CanCollide = false
- bcyc.Parent = workspace
- game:GetService("TweenService"):Create(bcyc, TweenInfo.new(1, Enum.EasingStyle.Cubic, Enum.EasingDirection.InOut), {Transparency = 1, Size = Vector3.new(500,200,200)}):Play()
- end)()
- end
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement