Advertisement
The_God_M8

GRAB BLOOD

May 11th, 2019
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.76 KB | None | 0 0
  1. --]]
  2. --//====================================================\\--
  3. --|| CREATED BY SHACKLUSTER
  4. --\\====================================================//--
  5. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  6. local Player,game,owner = owner,game
  7. local RealPlayer = Player
  8. do
  9. print("FE Compatibility code by Mokiros")
  10. local rp = RealPlayer
  11. script.Parent = rp.Character
  12.  
  13. --RemoteEvent for communicating
  14. local Event = Instance.new("RemoteEvent")
  15. Event.Name = "UserInput_Event"
  16.  
  17. --Fake event to make stuff like Mouse.KeyDown work
  18. local function fakeEvent()
  19. local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
  20. t.connect = t.Connect
  21. return t
  22. end
  23.  
  24. --Creating fake input objects with fake variables
  25. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  26. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  27. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  28. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  29. end}
  30. --Merged 2 functions into one by checking amount of arguments
  31. CAS.UnbindAction = CAS.BindAction
  32.  
  33. --This function will trigger the events that have been :Connect()'ed
  34. local function te(self,ev,...)
  35. local t = m[ev]
  36. if t and t._fakeEvent then
  37. for _,f in pairs(t.Functions) do
  38. f(...)
  39. end
  40. end
  41. end
  42. m.TrigEvent = te
  43. UIS.TrigEvent = te
  44.  
  45. Event.OnServerEvent:Connect(function(plr,io)
  46. if plr~=rp then return end
  47. m.Target = io.Target
  48. m.Hit = io.Hit
  49. if not io.isMouse then
  50. local b = io.UserInputState == Enum.UserInputState.Begin
  51. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  52. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  53. end
  54. for _,t in pairs(CAS.Actions) do
  55. for _,k in pairs(t.Keys) do
  56. if k==io.KeyCode then
  57. t.Function(t.Name,io.UserInputState,io)
  58. end
  59. end
  60. end
  61. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  62. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  63. end
  64. end)
  65. Event.Parent = NLS([==[
  66. local Player = game:GetService("Players").LocalPlayer
  67. local Event = script:WaitForChild("UserInput_Event")
  68.  
  69. local Mouse = Player:GetMouse()
  70. local UIS = game:GetService("UserInputService")
  71. local input = function(io,a)
  72. if a then return end
  73. --Since InputObject is a client-side instance, we create and pass table instead
  74. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
  75. end
  76. UIS.InputBegan:Connect(input)
  77. UIS.InputEnded:Connect(input)
  78.  
  79. local h,t
  80. --Give the server mouse data 30 times every second, but only if the values changed
  81. --If player is not moving their mouse, client won't fire events
  82. while wait(1/30) do
  83. if h~=Mouse.Hit or t~=Mouse.Target then
  84. h,t=Mouse.Hit,Mouse.Target
  85. Event:FireServer({isMouse=true,Target=t,Hit=h})
  86. end
  87. end]==],Player.Character)
  88.  
  89. ----Sandboxed game object that allows the usage of client-side methods and services
  90. --Real game object
  91. local _rg = game
  92.  
  93. --Metatable for fake service
  94. local fsmt = {
  95. __index = function(self,k)
  96. local s = rawget(self,"_RealService")
  97. if s then return s[k] end
  98. end,
  99. __newindex = function(self,k,v)
  100. local s = rawget(self,"_RealService")
  101. if s then s[k]=v end
  102. end,
  103. __call = function(self,...)
  104. local s = rawget(self,"_RealService")
  105. if s then return s(...) end
  106. end
  107. }
  108. local function FakeService(t,RealService)
  109. t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService
  110. return setmetatable(t,fsmt)
  111. end
  112.  
  113. --Fake game object
  114. local g = {
  115. GetService = function(self,s)
  116. return self[s]
  117. end,
  118. Players = FakeService({
  119. LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
  120. },"Players"),
  121. UserInputService = FakeService(UIS,"UserInputService"),
  122. ContextActionService = FakeService(CAS,"ContextActionService"),
  123. }
  124. rawset(g.Players,"localPlayer",g.Players.LocalPlayer)
  125. g.service = g.GetService
  126.  
  127. g.RunService = FakeService({
  128. RenderStepped = _rg:GetService("RunService").Heartbeat,
  129. BindToRenderStep = function(self,name,_,fun)
  130.  
  131. end,
  132. UnbindFromRenderStep = function(self,name)
  133. self._btrs[name]:Disconnect()
  134. end,
  135. },"RunService")
  136.  
  137. setmetatable(g,{
  138. __index=function(self,s)
  139. return _rg:GetService(s) or typeof(_rg[s])=="function"
  140. and function(_,...)return _rg[s](_rg,...)end or _rg[s]
  141. end,
  142. __newindex = fsmt.__newindex,
  143. __call = fsmt.__call
  144. })
  145. --Changing owner to fake player object to support owner:GetMouse()
  146. game,owner = g,g.Players.LocalPlayer
  147. end
  148.  
  149. wait(1) --For running in rbx studio
  150. mee = owner
  151. pistol = Instance.new("Tool", mee.Backpack)
  152. pistol.GripForward = Vector3.new(-0.149, 0.984, -0.099)
  153. pistol.GripPos = Vector3.new(0.1, -0.55, -0.2)
  154. pistol.GripRight = Vector3.new(0.989, 0.148, -0.015)
  155. pistol.GripUp = Vector3.new(0, 0.1, 0.995)
  156. pistol.ToolTip = "Hmm? Mitu is kinda lazy"
  157. pistol.Name = "Pistol"
  158. pistolpart = Instance.new("Part", pistol)
  159. pistolpart.Name = "Handle"
  160. pistolpart.BrickColor = BrickColor.new("Black")
  161. pistolpart.Material = "SmoothPlastic"
  162. pistolpart.Orientation = Vector3.new(-88.99, 152.78, 135.7)
  163. pistolpart.Size = Vector3.new(0.2, 1.12, 0.6)
  164. pistolmesh = Instance.new("SpecialMesh", pistolpart)
  165. pistolmesh.MeshId = "rbxassetid://430060386"
  166. pistolmesh.Scale = Vector3.new(2, 2, 2)
  167. pistolmesh.TextureId = "rbxassetid://430060404"
  168. pistolmesh.VertexColor = Vector3.new(2, 2, 2)
  169. gunshotsound = Instance.new("Sound", pistolpart)
  170. gunshotsound.SoundId = "rbxassetid://213603013"
  171.  
  172.  
  173. pistol.Equipped:connect(function(mouse)
  174. local torso = mee.Character.HumanoidRootPart
  175. local mouseturning = owner:GetMouse()
  176.  
  177. end)
  178. local mouse = owner:GetMouse()
  179. mouse.Button1Down:connect(function()
  180. gunshotsound:Play()
  181. MakeShell()
  182. local ray = Ray.new(pistol.Handle.CFrame.p, (mouse.Hit.p - pistol.Handle.CFrame.p).unit * 300)
  183. local part, position = workspace:FindPartOnRay(ray, mee.Character, false, true)
  184.  
  185. local beam = Instance.new("Part", workspace)
  186. beam.BrickColor = BrickColor.new("White")
  187. beam.FormFactor = "Custom"
  188. beam.Material = "Neon"
  189. beam.Transparency = 0.7
  190. beam.Anchored = true
  191. beam.Locked = true
  192. beam.CanCollide = false
  193.  
  194. local distance = (pistol.Handle.CFrame.p - position).magnitude
  195. beam.Size = Vector3.new(0.3, 0.3, distance)
  196. beam.CFrame = CFrame.new(pistol.Handle.CFrame.p, position) * CFrame.new(0, 0, -distance / 2)
  197.  
  198. game:GetService("Debris"):AddItem(beam, 0.1)
  199.  
  200. if part then
  201. local humanoid = part.Parent:FindFirstChild("Humanoid")
  202.  
  203. if not humanoid then
  204. humanoid = part.Parent.Parent:FindFirstChild("Humanoid")
  205. end
  206.  
  207. if humanoid then
  208. plrmodel = humanoid.Parent
  209. if plrmodel.Humanoid.Health ~= 0 then
  210. --blood
  211. plrmodel.Archivable = true
  212. local Char = plrmodel
  213. local Hum = Char:FindFirstChild("Humanoid")
  214. local Tor = Char:FindFirstChild("Torso") or Char:FindFirstChild("UpperTorso")
  215. local Health = Hum.Health
  216.  
  217. local M = math.random
  218. local R = math.rad
  219. local rates = {.05, .075, .1, .15}
  220.  
  221. local smooth = function(P)
  222. local SM = Enum.SurfaceType.SmoothNoOutlines
  223. P.TopSurface = SM
  224. P.BottomSurface = SM
  225. P.RightSurface = SM
  226. P.LeftSurface = SM
  227. P.FrontSurface = SM
  228. P.BackSurface = SM
  229. end
  230.  
  231. local function BloodPool(Part,Size)
  232. local Torso = Char:FindFirstChild("Torso") or Char:FindFirstChild("UpperTorso")
  233. local Pool = Instance.new("Part",game.Workspace)
  234. Pool.TopSurface = 0
  235. Pool.BrickColor = BrickColor.new("Crimson")
  236. Pool.Transparency = 0
  237. Pool.Anchored = true
  238. local ree = Instance.new('ParticleEmitter',Torso)
  239. ree.Color = ColorSequence.new({ColorSequenceKeypoint.new(0,Color3.fromRGB(50,0,0)),ColorSequenceKeypoint.new(1,Color3.fromRGB(50,0,0))})
  240. ree.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,0.1),NumberSequenceKeypoint.new(1,0.1)})
  241. ree.Texture = 'rbxassetid://867743272'
  242. ree.Lifetime = NumberRange.new(0.1)
  243. ree.Rate = 70
  244. ree.LockedToPart = true
  245. ree.Speed = NumberRange.new(0, 3)
  246. Pool.Material = Enum.Material.Granite
  247. local cyl = Instance.new('CylinderMesh',Pool)
  248. Pool.Name = "BloodPoolPart"
  249. smooth(Pool)
  250. cyl.Scale = Vector3.new(1,0.1,1)
  251. Pool.FormFactor = Enum.FormFactor.Custom
  252. Pool.Size = Vector3.new(1,0.2,1)
  253.  
  254. local c = Part.CFrame*CFrame.new(M(-3.01,3.01),-2.9,M(-3.01,3.01))
  255. coroutine.resume(coroutine.create(function()
  256. local rate = rates[M(1,#rates)]
  257. game.Debris:AddItem(Pool,15)
  258. for i = 1,M(25,70) do
  259. wait()
  260. Pool.CFrame = c
  261. Pool.Size = Pool.Size+Vector3.new(rate,0,rate)
  262. end
  263. wait(2)
  264. ree:Destroy()
  265. wait(5)
  266. Pool.Transparency = 0.1
  267. wait(0.1)
  268. Pool.Transparency=0.2
  269. wait(0.1)
  270. Pool.Transparency=0.3
  271. wait(0.1)
  272. Pool.Transparency=0.4
  273. wait(0.1)
  274. Pool.Transparency=0.5
  275. wait(0.1)
  276. Pool.Transparency=0.6
  277. wait(0.1)
  278. Pool.Transparency=0.7
  279. wait(0.1)
  280. Pool.Transparency=0.8
  281. wait(0.1)
  282. Pool.Transparency=0.9
  283. wait(0.1)
  284. Pool.Transparency=1
  285. wait(5)
  286. Pool:Destroy()
  287. end))
  288. end
  289. local function BloodDrops(Size,Area)
  290. local Blood = Instance.new("Part",game.Workspace)
  291. Blood.BrickColor = BrickColor.new("Crimson")
  292. Blood.Parent = plrmodel
  293. Blood.TopSurface = 0
  294. Blood.CanCollide = false
  295. Blood.Anchored = false
  296. Blood.FormFactor = Enum.FormFactor.Custom
  297. Blood.Size = Size
  298. Blood.CFrame = Area*CFrame.new(M(-1.00,1.00),M(-1.00,1.00),M(-1.00,1.00))
  299. return Blood
  300. end
  301.  
  302.  
  303. Hum.Changed:connect(function()
  304. if Hum.Health < Health then
  305. Health = Hum.Health
  306. for i = 1, math.random(4,10)do
  307. local Size = Vector3.new(M(-0.25,0.25),.2,M(-.25,.25))
  308. local Blood = BloodDrops(Size,Tor.CFrame)
  309. local Stopper = false
  310. local Size2 = Vector3.new(M(-0.25,0.25),.2,M(-.25,.25))
  311. BloodPool(Tor,Size2)
  312. end
  313. end
  314. end)
  315. end
  316.  
  317. --Ragdoll
  318. wait()
  319. function getAttachment0(attachmentName)
  320. for _,child in next,plrmodel:GetChildren() do
  321. local attachment = child:FindFirstChild(attachmentName)
  322. if attachment then
  323. return attachment
  324. end
  325. end
  326. end
  327. plrmodel.Humanoid.Died:Connect(function(var)
  328. local removeHRP = true
  329. local head = plrmodel["Head"]
  330. local leftarm = plrmodel["Left Arm"]
  331. local leftleg = plrmodel["Left Leg"]
  332. local rightleg = plrmodel["Right Leg"]
  333. local rightarm = plrmodel["Right Arm"]
  334. local torso = plrmodel.Torso
  335. local root = plrmodel.HumanoidRootPart
  336. if removeHRP == true then
  337. root:Destroy()
  338. end
  339. local rootA =Instance.new("Attachment")
  340. local HeadA = Instance.new("Attachment")
  341. local LeftArmA = Instance.new("Attachment")
  342. local LeftLegA = Instance.new("Attachment")
  343. local RightArmA = Instance.new("Attachment")
  344. local RightLegA = Instance.new("Attachment")
  345. local TorsoA = Instance.new("Attachment")
  346. local TorsoA1 = Instance.new("Attachment")
  347. local TorsoA2 = Instance.new("Attachment")
  348. local TorsoA3 = Instance.new("Attachment")
  349. local TorsoA4 = Instance.new("Attachment")
  350. local TorsoA5 = Instance.new("Attachment")
  351. local function set1()
  352. HeadA.Name = "HeadA"
  353. HeadA.Parent = head
  354. HeadA.Position = Vector3.new(0, -0.5, 0)
  355. HeadA.Rotation = Vector3.new(0, 0, 0)
  356. HeadA.Axis = Vector3.new(1, 0, 0)
  357. HeadA.SecondaryAxis = Vector3.new(0, 1, 0)
  358. LeftArmA.Name = "LeftArmA"
  359. LeftArmA.Parent = leftarm
  360. LeftArmA.Position = Vector3.new(0.5, 1, 0)
  361. LeftArmA.Rotation = Vector3.new(0, 0, 0)
  362. LeftArmA.Axis = Vector3.new(1, 0, 0)
  363. LeftArmA.SecondaryAxis = Vector3.new(0, 1, 0)
  364. LeftLegA.Name = "LeftLegA"
  365. LeftLegA.Parent = leftleg
  366. LeftLegA.Position = Vector3.new(0, 1, 0)
  367. LeftLegA.Rotation = Vector3.new(0, 0, 0)
  368. LeftLegA.Axis = Vector3.new(1, 0, 0)
  369. LeftLegA.SecondaryAxis = Vector3.new(0, 1, 0)
  370. RightArmA.Name = "RightArmA"
  371. RightArmA.Parent = rightarm
  372. RightArmA.Position = Vector3.new(-0.5, 1, 0)
  373. RightArmA.Rotation = Vector3.new(0, 0, 0)
  374. RightArmA.Axis = Vector3.new(1, 0, 0)
  375. RightArmA.SecondaryAxis = Vector3.new(0, 1, 0)
  376. RightLegA.Name = "RightLegA"
  377. RightLegA.Parent = rightleg
  378. RightLegA.Position = Vector3.new(0, 1, 0)
  379. RightLegA.Rotation = Vector3.new(0, 0, 0)
  380. RightLegA.Axis = Vector3.new(1, 0, 0)
  381. RightLegA.SecondaryAxis = Vector3.new(0, 1, 0)
  382. rootA.Name= "rootA"
  383. rootA.Parent = root
  384. rootA.Position = Vector3.new(0, 0, 0)
  385. rootA.Rotation = Vector3.new(0, 90, 0)
  386. rootA.Axis = Vector3.new(0, 0, -1)
  387. rootA.SecondaryAxis = Vector3.new(0, 1, 0)
  388. end
  389. local function set2()
  390. TorsoA.Name = "TorsoA"
  391. TorsoA.Parent = torso
  392. TorsoA.Position = Vector3.new(0.5, -1, 0)
  393. TorsoA.Rotation = Vector3.new(0, 0, 0)
  394. TorsoA.Axis = Vector3.new(1, 0, 0)
  395. TorsoA.SecondaryAxis = Vector3.new(0, 1, 0)
  396. TorsoA1.Name = "TorsoA1"
  397. TorsoA1.Parent = torso
  398. TorsoA1.Position = Vector3.new(-0.5, -1, 0)
  399. TorsoA1.Rotation = Vector3.new(0, 0, 0)
  400. TorsoA1.Axis = Vector3.new(1, 0, 0)
  401. TorsoA1.SecondaryAxis = Vector3.new(0, 1, 0)
  402. TorsoA2.Name = "TorsoA2"
  403. TorsoA2.Parent = torso
  404. TorsoA2.Position = Vector3.new(-1, 1, 0)
  405. TorsoA2.Rotation = Vector3.new(0, 0, 0)
  406. TorsoA2.Axis = Vector3.new(1, 0, 0)
  407. TorsoA2.SecondaryAxis = Vector3.new(0, 1, 0)
  408. TorsoA3.Name = "TorsoA3"
  409. TorsoA3.Parent = torso
  410. TorsoA3.Position = Vector3.new(1, 1, 0)
  411. TorsoA3.Rotation = Vector3.new(0, 0, 0)
  412. TorsoA3.Axis = Vector3.new(1, 0, 0)
  413. TorsoA3.SecondaryAxis = Vector3.new(0, 1, 0)
  414. TorsoA4.Name = "TorsoA4"
  415. TorsoA4.Parent = torso
  416. TorsoA4.Position = Vector3.new(0, 1, 0)
  417. TorsoA4.Rotation = Vector3.new(0, 0, 0)
  418. TorsoA4.Axis = Vector3.new(1, 0, 0)
  419. TorsoA4.SecondaryAxis = Vector3.new(0, 1, 0)
  420. TorsoA5.Name = "TorsoA5"
  421. TorsoA5.Parent = torso
  422. TorsoA5.Position = Vector3.new(0, 0, 0)
  423. TorsoA5.Rotation = Vector3.new(0, 90, 0)
  424. TorsoA5.Axis = Vector3.new(0, 0, -1)
  425. TorsoA5.SecondaryAxis = Vector3.new(0, 1, 0)
  426. end
  427. local function set3()
  428. end
  429. spawn(set1);
  430. spawn(set2);
  431. local HA = Instance.new("HingeConstraint")
  432. HA.Parent = head
  433. HA.Attachment0 = HeadA
  434. HA.Attachment1 = TorsoA4
  435. HA.Enabled = true
  436. HA.LimitsEnabled=true
  437. HA.LowerAngle=0
  438. HA.UpperAngle=0
  439. local LAT = Instance.new("BallSocketConstraint")
  440. LAT.Parent = leftarm
  441. LAT.Attachment0 = LeftArmA
  442. LAT.Attachment1 = TorsoA2
  443. LAT.Enabled = true
  444. LAT.LimitsEnabled=true
  445. LAT.UpperAngle=90
  446. local RAT = Instance.new("BallSocketConstraint")
  447. RAT.Parent = rightarm
  448. RAT.Attachment0 = RightArmA
  449. RAT.Attachment1 = TorsoA3
  450. RAT.Enabled = true
  451. RAT.LimitsEnabled=true
  452. RAT.UpperAngle=90
  453. local HA = Instance.new("BallSocketConstraint")
  454. HA.Parent = head
  455. HA.Attachment0 = HeadA
  456. HA.Attachment1 = TorsoA4
  457. HA.Enabled = true
  458. local TLL = Instance.new("BallSocketConstraint")
  459. TLL.Parent = torso
  460. TLL.Attachment0 = TorsoA1
  461. TLL.Attachment1 = LeftLegA
  462. TLL.Enabled = true
  463. TLL.LimitsEnabled=true
  464. TLL.UpperAngle=90
  465. local TRL = Instance.new("BallSocketConstraint")
  466. TRL.Parent = torso
  467. TRL.Attachment0 = TorsoA
  468. TRL.Attachment1 = RightLegA
  469. TRL.Enabled = true
  470. TRL.LimitsEnabled=true
  471. TRL.UpperAngle=90
  472. local RTA = Instance.new("BallSocketConstraint")
  473. RTA.Parent = root
  474. RTA.Attachment0 = rootA
  475. RTA.Attachment1 = TorsoA5
  476. RTA.Enabled = true
  477. RTA.LimitsEnabled=true
  478. RTA.UpperAngle=0
  479. head.Velocity = head.CFrame.lookVector*30
  480.  
  481. for _,child in next,plrmodel:GetChildren() do
  482. if child:IsA("Accoutrement") then
  483. for _,part in next,child:GetChildren() do
  484. if part:IsA("BasePart") then
  485. part.Parent = plrmodel
  486. child:remove()
  487. local attachment1 = part:FindFirstChildOfClass("Attachment")
  488. local attachment0 = getAttachment0(attachment1.Name)
  489. if attachment0 and attachment1 then
  490. local constraint = Instance.new("HingeConstraint")
  491. constraint.Attachment0 = attachment0
  492. constraint.Attachment1 = attachment1
  493. constraint.LimitsEnabled = true
  494. constraint.UpperAngle = 0
  495. constraint.LowerAngle = 0
  496. constraint.Parent = plrmodel
  497. end
  498. end
  499. end
  500. end
  501. end
  502. end)
  503.  
  504. end
  505. if humanoid.Health ~= 0 then
  506. humanoid.Walkspeed = 0
  507. humanoid.Jumppower = 0
  508. humanoid.Health = 50
  509. wait(3)
  510. while true do
  511. if humanoid.Health ~= 0 then
  512. humanoid.Health = 0 --This loop is a strange kill system I know, but this prevents doing 99 damage instead of 100 for some reason.s
  513. else
  514. break
  515. end
  516. wait(0.3)
  517. end
  518. end
  519. end
  520. end)
  521.  
  522. pistol.Unequipped:connect(function()
  523. wait(0.2)
  524.  
  525. end)
  526. function MakeShell()
  527. Shell = Instance.new("Part", workspace)
  528. Shell.Size = Vector3.new(0.2, 0.2, 0.6)
  529. ShellMesh = Instance.new("SpecialMesh", Shell)
  530. ShellMesh.MeshId = "http://www.roblox.com/asset/?id=94295100"
  531. ShellMesh.Scale = Vector3.new(4, 4, 4)
  532. ShellMesh.TextureId = "http://www.roblox.com/asset/?id=94287792"
  533. Shell.Position = pistolpart.Position
  534. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement