Advertisement
Tiberiuoctavian

Really Fast Baldi

Jun 23rd, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 47.96 KB | None | 0 0
  1. local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
  2. local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
  3. local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
  4. local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
  5. local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
  6. local R3 = {N=Region3.new}
  7. local De = S.Debris
  8. local WS = workspace
  9. local Lght = S.Lighting
  10. local RepS = S.ReplicatedStorage
  11. local IN = Instance.new
  12. local Plrs = S.Players
  13.  
  14. --// Initializing \\--
  15. local Plr = Plrs.LocalPlayer
  16. local Char = Plr.Character
  17. local Hum = Char:FindFirstChildOfClass'Humanoid'
  18. local RArm = Char["Right Arm"]
  19. local LArm = Char["Left Arm"]
  20. local RLeg = Char["Right Leg"]
  21. local LLeg = Char["Left Leg"]
  22. local Root = Char:FindFirstChild'HumanoidRootPart'
  23. local Torso = Char.Torso
  24. local Head = Char.Head
  25. local NeutralAnims = true
  26. local Attack = false
  27. local Debounces = {Debounces={}}
  28. local Mouse = Plr:GetMouse()
  29. local Hit = {}
  30. local Sine = 0
  31. local Change = 1
  32. local BloodPuddles = {}
  33.  
  34. local Effects = IN("Folder",Char)
  35. Effects.Name = "Effects"
  36.  
  37.  
  38. --// Debounce System \\--
  39.  
  40.  
  41. function Debounces:New(name,cooldown)
  42. local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
  43. setmetatable(aaaaa,{__index = Debounces})
  44. Debounces.Debounces[name] = aaaaa
  45. return aaaaa
  46. end
  47.  
  48. function Debounces:Use(overrideUsable)
  49. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  50. if(self.Usable or overrideUsable)then
  51. self.Usable = false
  52. self.CoolingDown = true
  53. local LastUse = time()
  54. self.LastUse = LastUse
  55. delay(self.Cooldown or 2,function()
  56. if(self.LastUse == LastUse)then
  57. self.CoolingDown = false
  58. self.Usable = true
  59. end
  60. end)
  61. end
  62. end
  63.  
  64. function Debounces:Get(name)
  65. assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
  66. for i,v in next, Debounces.Debounces do
  67. if(i == name)then
  68. return v;
  69. end
  70. end
  71. end
  72.  
  73. function Debounces:GetProgressPercentage()
  74. assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use")
  75. if(self.CoolingDown and not self.Usable)then
  76. return math.max(
  77. math.floor(
  78. (
  79. (time()-self.LastUse)/self.Cooldown or 2
  80. )*100
  81. )
  82. )
  83. else
  84. return 100
  85. end
  86. end
  87.  
  88. --// Instance Creation Functions \\--
  89. local baseSound = IN("Sound")
  90. function Sound(parent,id,pitch,volume,looped,effect,autoPlay)
  91. local Sound = baseSound:Clone()
  92. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  93. Sound.Pitch = pitch or 1
  94. Sound.Volume = volume or 1
  95. Sound.Looped = looped or false
  96. if(autoPlay)then
  97. coroutine.wrap(function()
  98. repeat wait() until Sound.IsLoaded
  99. Sound.Playing = autoPlay or false
  100. end)()
  101. end
  102. if(not looped and effect)then
  103. Sound.Stopped:connect(function()
  104. Sound.Volume = 0
  105. Sound:destroy()
  106. end)
  107. elseif(effect)then
  108. warn("Sound can't be looped and a sound effect!")
  109. end
  110. Sound.Parent =parent or Torso
  111. return Sound
  112. end
  113. function Part(parent,color,material,size,cframe,anchored,cancollide)
  114. local part = IN("Part")
  115. part.Parent = parent or Char
  116. part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(0,0,0)
  117. part.Material = material or Enum.Material.SmoothPlastic
  118. part.TopSurface,part.BottomSurface=10,10
  119. part.Size = size or V3.N(1,1,1)
  120. part.CFrame = cframe or CF.N(0,0,0)
  121. part.CanCollide = cancollide or false
  122. part.Anchored = anchored or false
  123. return part
  124. end
  125.  
  126. function Weld(part0,part1,c0,c1)
  127. local weld = IN("Weld")
  128. weld.Parent = part0
  129. weld.Part0 = part0
  130. weld.Part1 = part1
  131. weld.C0 = c0 or CF.N()
  132. weld.C1 = c1 or CF.N()
  133. return weld
  134. end
  135.  
  136. function Mesh(parent,meshtype,meshid,textid,scale,offset)
  137. local part = IN("SpecialMesh")
  138. part.MeshId = meshid or ""
  139. part.TextureId = textid or ""
  140. part.Scale = scale or V3.N(1,1,1)
  141. part.Offset = offset or V3.N(0,0,0)
  142. part.MeshType = meshtype or Enum.MeshType.Sphere
  143. part.Parent = parent
  144. return part
  145. end
  146.  
  147. NewInstance = function(instance,parent,properties)
  148. local inst = Instance.new(instance)
  149. inst.Parent = parent
  150. if(properties)then
  151. for i,v in next, properties do
  152. pcall(function() inst[i] = v end)
  153. end
  154. end
  155. return inst;
  156. end
  157.  
  158. function Clone(instance,parent,properties)
  159. local inst = instance:Clone()
  160. inst.Parent = parent
  161. if(properties)then
  162. for i,v in next, properties do
  163. pcall(function() inst[i] = v end)
  164. end
  165. end
  166. return inst;
  167. end
  168.  
  169. function SoundPart(id,pitch,volume,looped,effect,autoPlay,cf)
  170. local soundPart = NewInstance("Part",Effects,{Transparency=1,CFrame=cf or Torso.CFrame,Anchored=true,CanCollide=false,Size=V3.N()})
  171. local Sound = IN("Sound")
  172. Sound.SoundId = "rbxassetid://".. tostring(id or 0)
  173. Sound.Pitch = pitch or 1
  174. Sound.Volume = volume or 1
  175. Sound.Looped = looped or false
  176. if(autoPlay)then
  177. coroutine.wrap(function()
  178. repeat wait() until Sound.IsLoaded
  179. Sound.Playing = autoPlay or false
  180. end)()
  181. end
  182. if(not looped and effect)then
  183. Sound.Stopped:connect(function()
  184. Sound.Volume = 0
  185. soundPart:destroy()
  186. end)
  187. elseif(effect)then
  188. warn("Sound can't be looped and a sound effect!")
  189. end
  190. Sound.Parent = soundPart
  191. return Sound
  192. end
  193.  
  194.  
  195. --// Extended ROBLOX tables \\--
  196. local Instance = setmetatable({ClearChildrenOfClass = function(where,class,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do if(v:IsA(class))then v:destroy();end;end;end},{__index = Instance})
  197. --// Require stuff \\--
  198. function CamShake(who,times,intense,origin)
  199. coroutine.wrap(function()
  200. if(script:FindFirstChild'CamShake')then
  201. local cam = script.CamShake:Clone()
  202. cam:WaitForChild'intensity'.Value = intense
  203. cam:WaitForChild'times'.Value = times
  204.  
  205. if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
  206. cam.Parent = who
  207. wait()
  208. cam.Disabled = false
  209. elseif(who == Plr or who == Char or who:IsDescendantOf(Plr))then
  210. local intensity = intense
  211. if(Hum and not Hum:FindFirstChild'CamShaking')then
  212. local cam = workspace.CurrentCamera
  213. local oCO = Hum.CameraOffset
  214. local cs = Instance.new("BoolValue",Hum)
  215. cs.Name = "CamShaking"
  216. for i = 1, times do
  217. local camDistFromOrigin
  218. if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then
  219. camDistFromOrigin = math.floor( (cam.CoordinateFrame.p-origin.Position).magnitude )/25
  220. elseif(typeof(origin) == 'Vector3')then
  221. camDistFromOrigin = math.floor( (cam.CoordinateFrame.p-origin).magnitude )/25
  222. end
  223. if(camDistFromOrigin)then
  224. intensity = math.min(intense, math.floor(intense/camDistFromOrigin))
  225. end
  226. --cam.CoordinateFrame = cam.CoordinateFrame*CFrame.fromEulerAnglesXYZ(math.random(-intensity,intensity)/200,math.random(-intensity,intensity)/200,math.random(-intensity,intensity)/200)
  227. if(Hum)then
  228. Hum.CameraOffset = Vector3.new(math.random(-intensity,intensity)/200,math.random(-intensity,intensity)/200,math.random(-intensity,intensity)/200)
  229. end
  230. swait()
  231. end
  232. if(Hum)then
  233. Hum.CameraOffset = oCO
  234. end
  235. cs:destroy()
  236. end
  237. end
  238. end)()
  239. end
  240.  
  241.  
  242. function CamShakeAll(times,intense,origin)
  243. for _,v in next, Plrs:players() do
  244. CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin)
  245. end
  246. end
  247.  
  248. function ServerScript(code)
  249. if(script:FindFirstChild'Loadstring')then
  250. local load = script.Loadstring:Clone()
  251. load:WaitForChild'Sauce'.Value = code
  252. load.Disabled = false
  253. load.Parent = workspace
  254. elseif(NS and typeof(NS) == 'function')then
  255. NS(code,workspace)
  256. else
  257. warn("no serverscripts lol")
  258. end
  259. end
  260.  
  261. function LocalOnPlayer(who,code)
  262. ServerScript([[
  263. wait()
  264. script.Parent=nil
  265. if(not _G.Http)then _G.Http = game:service'HttpService' end
  266.  
  267. local Http = _G.Http or game:service'HttpService'
  268.  
  269. local source = ]].."[["..code.."]]"..[[
  270. local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php"
  271. local asd = Http:PostAsync(link,source)
  272. repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID
  273. local ID = Http:JSONDecode(asd).Result.Require_ID
  274. local vs = require(ID).VORTH_SCRIPT
  275. vs.Parent = game:service'Players'.]]..who.Name..[[.Character
  276. ]])
  277. end
  278.  
  279.  
  280. --// Customization \\--
  281.  
  282. local Frame_Speed = 100 -- The frame speed for swait. 1 is automatically divided by this
  283. local Remove_Hats = true
  284. local Remove_Clothing = true
  285. local PlayerSize = 1
  286. local DamageColor = BrickColor.new'Really red'
  287. local MusicID = 1718183351
  288. local God = false
  289. local Muted = false
  290. local angerCounter = 1; -- lower = faster
  291. local angry = false
  292.  
  293. local WalkSpeed = 16
  294.  
  295. --// Weapon and GUI creation, and Character Customization \\--
  296.  
  297. if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
  298. if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
  299.  
  300. local rule = Part(Char,BrickColor.new'Linen',Enum.Material.Wood,V3.N(.2,.5,4),CF.N(),false,false)
  301. local rd = NewInstance("Decal",rule,{Texture='rbxassetid://109519158',Face='Right'})
  302. local ld = NewInstance("Decal",rule,{Texture='rbxassetid://109519158',Face='Left'})
  303.  
  304. if(PlayerSize ~= 1)then
  305. for _,v in next, Char:GetDescendants() do
  306. if(v:IsA'BasePart')then
  307. v.Size = v.Size * PlayerSize
  308. end
  309. end
  310. end
  311.  
  312.  
  313. local Music = Sound(Char,MusicID,1,3,true,false,true)
  314. Music.Name = 'Music'
  315.  
  316. --// Stop animations \\--
  317. for _,v in next, Hum:GetPlayingAnimationTracks() do
  318. v:Stop();
  319. end
  320.  
  321. pcall(game.Destroy,Char:FindFirstChild'Animate')
  322. pcall(game.Destroy,Hum:FindFirstChild'Animator')
  323.  
  324. --// Joints \\--
  325.  
  326. local LS = NewInstance('Motor',Char,{Part0=Torso,Part1=LArm,C0 = CF.N(-1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
  327. local RS = NewInstance('Motor',Char,{Part0=Torso,Part1=RArm,C0 = CF.N(1.5 * PlayerSize,0.5 * PlayerSize,0),C1 = CF.N(0,.5 * PlayerSize,0)})
  328. local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5 * PlayerSize,0)})
  329. local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  330. local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5 * PlayerSize,-1 * PlayerSize,0),C1 = CF.N(0,1 * PlayerSize,0)})
  331. local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
  332. local HW = NewInstance('Motor',Char,{Part0=RArm,Part1=rule,C0=CF.N(0,-1,-1)})
  333.  
  334. local LSC0 = LS.C0
  335. local RSC0 = RS.C0
  336. local NKC0 = NK.C0
  337. local LHC0 = LH.C0
  338. local RHC0 = RH.C0
  339. local RJC0 = RJ.C0
  340.  
  341. --// Artificial HB \\--
  342.  
  343. local ArtificialHB = IN("BindableEvent", script)
  344. ArtificialHB.Name = "Heartbeat"
  345.  
  346. script:WaitForChild("Heartbeat")
  347.  
  348. local tf = 0
  349. local allowframeloss = false
  350. local tossremainder = false
  351. local lastframe = tick()
  352. local frame = 1/Frame_Speed
  353. ArtificialHB:Fire()
  354.  
  355. game:GetService("RunService").Heartbeat:connect(function(s, p)
  356. tf = tf + s
  357. if tf >= frame then
  358. if allowframeloss then
  359. script.Heartbeat:Fire()
  360. lastframe = tick()
  361. else
  362. for i = 1, math.floor(tf / frame) do
  363. ArtificialHB:Fire()
  364. end
  365. lastframe = tick()
  366. end
  367. if tossremainder then
  368. tf = 0
  369. else
  370. tf = tf - frame * math.floor(tf / frame)
  371. end
  372. end
  373. end)
  374.  
  375. function swait(num)
  376. if num == 0 or num == nil then
  377. ArtificialHB.Event:wait()
  378. else
  379. for i = 0, num do
  380. ArtificialHB.Event:wait()
  381. end
  382. end
  383. end
  384.  
  385.  
  386. --// Effect Function(s) \\--
  387.  
  388. function NoobySphere(Lifetime,Speed,Type,Pos,StartSize,Inc,Color,Range,MeshId,Axis)
  389. local fxP = Part(Effects,Color,Enum.Material.Neon,V3.N(1,1,1),Pos+Pos.lookVector*Range,true,false)
  390. local fxM = Mesh(fxP,(MeshId and Enum.MeshType.FileMesh or Enum.MeshType.Sphere),(MeshId and "rbxassetid://"..MeshId or ""),"",StartSize,V3.N())
  391. local Scale = 1
  392. local speeder = Speed
  393. if(Type == "Multiply")then
  394. Scale = 1*Inc
  395. elseif(Type == "Divide")then
  396. Scale = 1/Inc
  397. end
  398. coroutine.wrap(function()
  399. for i = 0,10/Lifetime,.1 do
  400.  
  401. if(Type == "Multiply")then
  402. Scale = Scale - 0.01*Inc/Lifetime
  403. elseif(Type == "Divide")then
  404. Scale = Scale - 0.01/Inc*Lifetime
  405. end
  406. speeder = speeder - 0.01*Speed*Lifetime
  407. fxP.CFrame = fxP.CFrame + fxP.CFrame.lookVector*speeder*Lifetime
  408. fxP.Transparency = fxP.Transparency + 0.01*Lifetime
  409. if(Axis == 'x')then
  410. fxM.Scale = fxM.Scale + Vector3.new(Scale*Lifetime, 0, 0)
  411. elseif(Axis == 'y')then
  412. fxM.Scale = fxM.Scale + Vector3.new(0, Scale*Lifetime, 0)
  413. elseif(Axis == 'z')then
  414. fxM.Scale = fxM.Scale + Vector3.new(0, 0, Scale*Lifetime)
  415. elseif(Axis == 'xyz')then
  416. fxM.Scale = fxM.Scale + Vector3.new(Scale*Lifetime,Scale*Lifetime,Scale*Lifetime)
  417. elseif(Axis == 'yz')then
  418. fxM.Scale = fxM.Scale + Vector3.new(0,Scale*Lifetime,Scale*Lifetime)
  419. elseif(Axis == 'xz')then
  420. fxM.Scale = fxM.Scale + Vector3.new(Scale*Lifetime,0,Scale*Lifetime)
  421. else
  422. fxM.Scale = fxM.Scale + Vector3.new(Scale*Lifetime, Scale*Lifetime, 0)
  423. end
  424. if(fxP.Transparency >= 1)then break end
  425. swait()
  426. end
  427. fxP:destroy()
  428. end)()
  429. return fxP
  430. end
  431.  
  432. function NoobySphere2(Lifetime,Type,Pos,StartSize,Inc,Color,MeshId)
  433. local fxP = Part(Effects,Color,Enum.Material.Neon,V3.N(1,1,1),Pos,true,false)
  434. local fxM = Mesh(fxP,(MeshId and Enum.MeshType.FileMesh or Enum.MeshType.Sphere),(MeshId and "rbxassetid://"..MeshId or ""),"",StartSize,V3.N())
  435.  
  436. local Scale = 1
  437. if(Type == "Multiply")then
  438. Scale = 1*Inc
  439. elseif(Type == "Divide")then
  440. Scale = 1/Inc
  441. end
  442. coroutine.wrap(function()
  443. for i = 0,10/Lifetime,.1 do
  444.  
  445. if(Type == "Multiply")then
  446. Scale = Scale - 0.01*Inc/Lifetime
  447. elseif(Type == "Divide")then
  448. Scale = Scale - 0.01/Inc*Lifetime
  449. end
  450. fxP.Transparency = fxP.Transparency + 0.01*Lifetime
  451. fxM.Scale = fxM.Scale + Vector3.new(Scale*Lifetime, Scale*Lifetime, Scale*Lifetime)
  452. swait()
  453. end
  454. fxP:destroy()
  455. end)()
  456. end
  457.  
  458. function NoobyBlock(Lifetime,Speed,Type,Pos,StartSize,Inc,Color,Range,Fade,MeshId)
  459. local fxP = Part(Effects,Color,Enum.Material.Neon,V3.N(1,1,1),Pos+Pos.lookVector*Range,true,false)
  460. local fxM = Mesh(fxP,(MeshId and Enum.MeshType.FileMesh or Enum.MeshType.Brick),(MeshId and "rbxassetid://"..MeshId or ""),"",StartSize,V3.N())
  461. local Scale = 1
  462. local speeder = Speed
  463. if(Type == "Multiply")then
  464. Scale = 1*Inc
  465. elseif(Type == "Divide")then
  466. Scale = 1/Inc
  467. end
  468. coroutine.wrap(function()
  469. for i = 0,10/Lifetime,.1 do
  470. if(Type == "Multiply")then
  471. Scale = Scale - 0.01*Inc/Lifetime
  472. elseif(Type == "Divide")then
  473. Scale = Scale - 0.01/Inc*Lifetime
  474. end
  475. if(Fade)then
  476. fxP.Transparency = i/(10/Lifetime)
  477. end
  478. speeder = speeder - 0.01*Speed*Lifetime/10
  479. fxP.CFrame = fxP.CFrame + fxP.CFrame.lookVector*speeder*Lifetime
  480. fxM.Scale = fxM.Scale - Vector3.new(Scale*Lifetime, Scale*Lifetime, Scale*Lifetime)
  481. swait()
  482. end
  483. fxP:destroy()
  484. end)()
  485. end
  486.  
  487. function Bezier(startpos, pos2, pos3, endpos, t)
  488. local A = startpos:lerp(pos2, t)
  489. local B = pos2:lerp(pos3, t)
  490. local C = pos3:lerp(endpos, t)
  491. local lerp1 = A:lerp(B, t)
  492. local lerp2 = B:lerp(C, t)
  493. local cubic = lerp1:lerp(lerp2, t)
  494. return cubic
  495. end
  496. function Puddle(hit,pos,norm,data)
  497. local material = data.Material or Enum.Material.SmoothPlastic
  498. local color = data.Color or BrickColor.new'Crimson'
  499. local size = data.Size or 1
  500.  
  501. if(hit.Name ~= 'BloodPuddle')then
  502. local Puddle = NewInstance('Part',workspace,{Material=material,BrickColor=color,Size=V3.N(size,.1,size),CFrame=CF.N(pos,pos+norm)*CF.A(90*M.P/180,0,0),Anchored=true,CanCollide=false,Archivable=false,Locked=true,Name='BloodPuddle'})
  503. local Cyl = NewInstance('CylinderMesh',Puddle,{Name='CylinderMesh'})
  504. BloodPuddles[Puddle] = 0
  505. else
  506. local cyl = hit:FindFirstChild'CylinderMesh'
  507. if(cyl)then
  508. BloodPuddles[hit] = 0
  509. cyl.Scale = cyl.Scale + V3.N(size,0,size)
  510. hit.Transparency = 0
  511. end
  512. end
  513. end
  514.  
  515. function Droplet(data)
  516. --ShootBullet{Size=V3.N(3,3,3),Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
  517. local Size = data.Size or 1
  518. local Color = data.Color or BrickColor.new'Crimson'
  519. local StudsPerFrame = data.Speed or 1
  520. local Shape = data.Shape or 'Ball'
  521. local Frames = (data.Frames or 160)+1
  522. local Pos = data.Origin or Root.CFrame
  523. local Direction = data.Direction or Root.CFrame.lookVector*100000
  524. local Material = data.Material or Enum.Material.SmoothPlastic
  525. local Drop = data.Drop or .05
  526. local Ignorelist = data.Ignorelist or nil
  527.  
  528. local Bullet = Part(Effects,Color,Material,V3.N(Size,Size,Size),Pos,true,false)
  529. local BMesh = Mesh(Bullet,Enum.MeshType.Brick,"","",V3.N(1,1,1),V3.N())
  530. if(Shape == 'Ball')then
  531. BMesh.MeshType = Enum.MeshType.Sphere
  532. elseif(Shape == 'Head')then
  533. BMesh.MeshType = Enum.MeshType.Head
  534. elseif(Shape == 'Cylinder')then
  535. BMesh.MeshType = Enum.MeshType.Cylinder
  536. end
  537.  
  538. coroutine.wrap(function()
  539. for i = 1, Frames do
  540. Pos = Pos * CF.N(0,-(Drop*i),0)
  541. local hit,pos,norm,dist = CastRay(Bullet.CFrame.p,CF.N(Pos.p,Direction)*CF.N(0,0,-(StudsPerFrame*i)).p,StudsPerFrame)
  542. if(hit and (not hit.Parent or not hit.Parent:FindFirstChildOfClass'Humanoid' and not hit.Parent:IsA'Accessory'))then
  543. Puddle(hit,pos,norm,data)
  544. break;
  545. else
  546. Bullet.CFrame = CF.N(Pos.p,Direction)*CF.N(0,0,-(StudsPerFrame*i))
  547. end
  548. swait()
  549. end
  550. Bullet:destroy()
  551. end)()
  552. end
  553.  
  554. function SphereFX(duration,color,scale,pos,endScale,increment)
  555. return Effect{
  556. Effect='ResizeAndFade',
  557. Color=color,
  558. Size=scale,
  559. Mesh={MeshType=Enum.MeshType.Sphere},
  560. CFrame=pos,
  561. FXSettings={
  562. EndSize=endScale,
  563. EndIsIncrement=increment
  564. }
  565. }
  566. end
  567.  
  568. function BlastFX(duration,color,scale,pos,endScale,increment)
  569. return Effect{
  570. Effect='ResizeAndFade',
  571. Color=color,
  572. Size=scale,
  573. Mesh={MeshType=Enum.MeshType.FileMesh,MeshId='rbxassetid://20329976'},
  574. CFrame=pos,
  575. FXSettings={
  576. EndSize=endScale,
  577. EndIsIncrement=increment
  578. }
  579. }
  580. end
  581.  
  582. function BlockFX(duration,color,scale,pos,endScale,increment)
  583. return Effect{
  584. Effect='ResizeAndFade',
  585. Color=color,
  586. Size=scale,
  587. CFrame=pos,
  588. FXSettings={
  589. EndSize=endScale,
  590. EndIsIncrement=increment
  591. }
  592. }
  593. end
  594.  
  595. function ShootBullet(data)
  596. --ShootBullet{Size=V3.N(3,3,3),Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
  597. local Size = data.Size or V3.N(2,2,2)
  598. local Color = data.Color or BrickColor.new'Crimson'
  599. local StudsPerFrame = data.Speed or 10
  600. local Shape = data.Shape or 'Ball'
  601. local Frames = data.Frames or 160
  602. local Pos = data.Origin or Torso.CFrame
  603. local Direction = data.Direction or Mouse.Hit
  604. local Material = data.Material or Enum.Material.Neon
  605. local OnHit = data.HitFunction or function(hit,pos)
  606. Effect{
  607. Effect='ResizeAndFade',
  608. Color=Color,
  609. Size=V3.N(10,10,10),
  610. Mesh={MeshType=Enum.MeshType.Sphere},
  611. CFrame=CF.N(pos),
  612. FXSettings={
  613. EndSize=V3.N(.05,.05,.05),
  614. EndIsIncrement=true
  615. }
  616. }
  617. for i = 1, 5 do
  618. local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180))
  619. Effect{
  620. Effect='Fade',
  621. Frames=65,
  622. Size=V3.N(5,5,10),
  623. CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-10).p,pos),
  624. Mesh = {MeshType=Enum.MeshType.Sphere},
  625. Material=Enum.Material.Neon,
  626. Color=Color,
  627. MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p,
  628. }
  629. end
  630. end
  631.  
  632. local Bullet = Part(Effects,Color,Material,Size,Pos,true,false)
  633. local BMesh = Mesh(Bullet,Enum.MeshType.Brick,"","",V3.N(1,1,1),V3.N())
  634. if(Shape == 'Ball')then
  635. BMesh.MeshType = Enum.MeshType.Sphere
  636. elseif(Shape == 'Head')then
  637. BMesh.MeshType = Enum.MeshType.Head
  638. elseif(Shape == 'Cylinder')then
  639. BMesh.MeshType = Enum.MeshType.Cylinder
  640. end
  641.  
  642. coroutine.wrap(function()
  643. for i = 1, Frames+1 do
  644. local hit,pos,norm,dist = CastRay(Bullet.CFrame.p,CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame).p,StudsPerFrame)
  645. if(hit)then
  646. OnHit(hit,pos,norm,dist)
  647. break;
  648. else
  649. Bullet.CFrame = CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame)
  650. end
  651. swait()
  652. end
  653. Bullet:destroy()
  654. end)()
  655.  
  656. end
  657.  
  658.  
  659. function Zap(data)
  660. local sCF,eCF = data.StartCFrame,data.EndCFrame
  661. assert(sCF,"You need a start CFrame!")
  662. assert(eCF,"You need an end CFrame!")
  663. local parts = data.PartCount or 15
  664. local zapRot = data.ZapRotation or {-5,5}
  665. local startThick = data.StartSize or 3;
  666. local endThick = data.EndSize or startThick/2;
  667. local color = data.Color or BrickColor.new'Electric blue'
  668. local delay = data.Delay or 35
  669. local delayInc = data.DelayInc or 0
  670. local lastLightning;
  671. local MagZ = (sCF.p - eCF.p).magnitude
  672. local thick = startThick
  673. local inc = (startThick/parts)-(endThick/parts)
  674.  
  675. for i = 1, parts do
  676. local pos = sCF.p
  677. if(lastLightning)then
  678. pos = lastLightning.CFrame*CF.N(0,0,MagZ/parts/2).p
  679. end
  680. delay = delay + delayInc
  681. local zapPart = Part(Effects,color,Enum.Material.Neon,V3.N(thick,thick,MagZ/parts),CF.N(pos),true,false)
  682. local posie = CF.N(pos,eCF.p)*CF.N(0,0,MagZ/parts).p+V3.N(M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)))
  683. if(parts == i)then
  684. local MagZ = (pos-eCF.p).magnitude
  685. zapPart.Size = V3.N(endThick,endThick,MagZ)
  686. zapPart.CFrame = CF.N(pos, eCF.p)*CF.N(0,0,-MagZ/2)
  687. Effect{Effect='ResizeAndFade',Size=V3.N(thick,thick,thick),CFrame=eCF*CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)),Color=color,Frames=delay*2,FXSettings={EndSize=V3.N(thick*8,thick*8,thick*8)}}
  688. else
  689. zapPart.CFrame = CF.N(pos,posie)*CF.N(0,0,MagZ/parts/2)
  690. end
  691.  
  692. lastLightning = zapPart
  693. Effect{Effect='Fade',Manual=zapPart,Frames=delay}
  694.  
  695. thick=thick-inc
  696.  
  697. end
  698. end
  699.  
  700. function Zap2(data)
  701. local Color = data.Color or BrickColor.new'Electric blue'
  702. local StartPos = data.Start or Torso.Position
  703. local EndPos = data.End or Mouse.Hit.p
  704. local SegLength = data.SegL or 2
  705. local Thicc = data.Thickness or 0.5
  706. local Fades = data.Fade or 45
  707. local Parent = data.Parent or Effects
  708. local MaxD = data.MaxDist or 200
  709. local Branch = data.Branches or false
  710. local Material = data.Material or Enum.Material.Neon
  711. local Raycasts = data.Raycasts or false
  712. local Offset = data.Offset or {0,360}
  713. local AddMesh = (data.Mesh == nil and true or data.Mesh)
  714. if((StartPos-EndPos).magnitude > MaxD)then
  715. EndPos = CF.N(StartPos,EndPos)*CF.N(0,0,-MaxD).p
  716. end
  717. local hit,pos,norm,dist=nil,EndPos,nil,(StartPos-EndPos).magnitude
  718. if(Raycasts)then
  719. hit,pos,norm,dist = CastRay(StartPos,EndPos,MaxD)
  720. end
  721. local segments = dist/SegLength
  722. local model = IN("Model",Parent)
  723. model.Name = 'Lightning'
  724. local Last;
  725. for i = 1, segments do
  726. local size = (segments-i)/25
  727. local prt = Part(model,Color,Material,V3.N(Thicc+size,SegLength,Thicc+size),CF.N(),true,false)
  728. if(AddMesh)then IN("CylinderMesh",prt) end
  729. if(Last and math.floor(segments) == i)then
  730. local MagZ = (Last.CFrame*CF.N(0,-SegLength/2,0).p-EndPos).magnitude
  731. prt.Size = V3.N(Thicc+size,MagZ,Thicc+size)
  732. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,EndPos)*CF.A(M.R(90),0,0)*CF.N(0,-MagZ/2,0)
  733. elseif(not Last)then
  734. prt.CFrame = CF.N(StartPos,pos)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  735. else
  736. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,CF.N(pos)*CF.A(M.R(M.RNG(0,360)),M.R(M.RNG(0,360)),M.R(M.RNG(0,360)))*CF.N(0,0,SegLength/3+(segments-i)).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  737. end
  738. Last = prt
  739. if(Branch)then
  740. local choice = M.RNG(1,7+((segments-i)*2))
  741. if(choice == 1)then
  742. local LastB;
  743. for i2 = 1,M.RNG(2,5) do
  744. local size2 = ((segments-i)/35)/i2
  745. local prt = Part(model,Color,Material,V3.N(Thicc+size2,SegLength,Thicc+size2),CF.N(),true,false)
  746. if(AddMesh)then IN("CylinderMesh",prt) end
  747. if(not LastB)then
  748. prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,Last.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  749. else
  750. prt.CFrame = CF.N(LastB.CFrame*CF.N(0,-SegLength/2,0).p,LastB.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0)
  751. end
  752. LastB = prt
  753. end
  754. end
  755. end
  756. end
  757. if(Fades > 0)then
  758. coroutine.wrap(function()
  759. for i = 1, Fades do
  760. for _,v in next, model:children() do
  761. if(v:IsA'BasePart')then
  762. v.Transparency = (i/Fades)
  763. end
  764. end
  765. swait()
  766. end
  767. model:destroy()
  768. end)()
  769. else
  770. S.Debris:AddItem(model,.01)
  771. end
  772. return {End=(Last and Last.CFrame*CF.N(0,-Last.Size.Y/2,0).p),Last=Last,Model=model}
  773. end
  774.  
  775. function Tween(obj,props,time,easing,direction,repeats,backwards)
  776. local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false)
  777. local tween = S.TweenService:Create(obj, info, props)
  778.  
  779. tween:Play()
  780. end
  781.  
  782. function Effect(data)
  783. local FX = data.Effect or 'ResizeAndFade'
  784. local Parent = data.Parent or Effects
  785. local Color = data.Color or C3.N(0,0,0)
  786. local Size = data.Size or V3.N(1,1,1)
  787. local MoveDir = data.MoveDirection or nil
  788. local MeshData = data.Mesh or nil
  789. local SndData = data.Sound or nil
  790. local Frames = data.Frames or 45
  791. local Manual = data.Manual or nil
  792. local Material = data.Material or nil
  793. local CFra = data.CFrame or Torso.CFrame
  794. local Settings = data.FXSettings or {}
  795. local Shape = data.Shape or Enum.PartType.Block
  796. local Snd,Prt,Msh;
  797. local RotInc = data.RotInc or {0,0,0}
  798. if(typeof(RotInc) == 'number')then
  799. RotInc = {RotInc,RotInc,RotInc}
  800. end
  801. coroutine.wrap(function()
  802. if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then
  803. Prt = Manual
  804. else
  805. Prt = Part(Parent,Color,Material,Size,CFra,true,false)
  806. Prt.Shape = Shape
  807. end
  808. if(typeof(MeshData) == 'table')then
  809. Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset)
  810. elseif(typeof(MeshData) == 'Instance')then
  811. Msh = MeshData:Clone()
  812. Msh.Parent = Prt
  813. elseif(Shape == Enum.PartType.Block)then
  814. Msh = Mesh(Prt,Enum.MeshType.Brick)
  815. end
  816. if(typeof(SndData) == 'table' or typeof(SndData) == 'Instance')then
  817. Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true)
  818. end
  819. if(Snd)then
  820. repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0
  821. Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch
  822. end
  823. Size = (Msh and Msh.Scale or Size)
  824. local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2)
  825.  
  826. local MoveSpeed = nil;
  827. if(MoveDir)then
  828. MoveSpeed = (CFra.p - MoveDir).magnitude/Frames
  829. end
  830. if(FX ~= 'Arc')then
  831. for Frame = 1, Frames do
  832. if(FX == "Fade")then
  833. Prt.Transparency = (Frame/Frames)
  834. elseif(FX == "Resize")then
  835. if(not Settings.EndSize)then
  836. Settings.EndSize = V3.N(0,0,0)
  837. end
  838. if(Settings.EndIsIncrement)then
  839. if(Msh)then
  840. Msh.Scale = Msh.Scale + Settings.EndSize
  841. else
  842. Prt.Size = Prt.Size + Settings.EndSize
  843. end
  844. else
  845. if(Msh)then
  846. Msh.Scale = Msh.Scale - grow/Frames
  847. else
  848. Prt.Size = Prt.Size - grow/Frames
  849. end
  850. end
  851. elseif(FX == "ResizeAndFade")then
  852. if(not Settings.EndSize)then
  853. Settings.EndSize = V3.N(0,0,0)
  854. end
  855. if(Settings.EndIsIncrement)then
  856. if(Msh)then
  857. Msh.Scale = Msh.Scale + Settings.EndSize
  858. else
  859. Prt.Size = Prt.Size + Settings.EndSize
  860. end
  861. else
  862. if(Msh)then
  863. Msh.Scale = Msh.Scale - grow/Frames
  864. else
  865. Prt.Size = Prt.Size - grow/Frames
  866. end
  867. end
  868. Prt.Transparency = (Frame/Frames)
  869. end
  870. if(Settings.RandomizeCFrame)then
  871. Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360))
  872. else
  873. Prt.CFrame = Prt.CFrame * CF.A(unpack(RotInc))
  874. end
  875. if(MoveDir and MoveSpeed)then
  876. local Orientation = Prt.Orientation
  877. Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed)
  878. Prt.Orientation = Orientation
  879. end
  880. swait()
  881. end
  882. Prt:destroy()
  883. else
  884. local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End
  885. if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end
  886. if(start and endP)then
  887. local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  888. local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25))
  889. for Frame = 0, 1, (Settings.Speed or 0.01) do
  890. if(Settings.Home)then
  891. endP = Settings.Home.CFrame
  892. end
  893. Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame)
  894. end
  895. if(Settings.RemoveOnGoal)then
  896. Prt:destroy()
  897. end
  898. else
  899. Prt:destroy()
  900. assert(start,"You need a start position!")
  901. assert(endP,"You need a start position!")
  902. end
  903. end
  904. end)()
  905. return Prt,Msh,Snd
  906. end
  907. function SoulSteal(whom)
  908. local torso = (whom:FindFirstChild'Head' or whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart')
  909. print(torso)
  910. if(torso and torso:IsA'BasePart')then
  911. local Model = Instance.new("Model",Effects)
  912. Model.Name = whom.Name.."'s Soul"
  913. whom:BreakJoints()
  914. local Soul = Part(Model,BrickColor.new'Really red','Glass',V3.N(.5,.5,.5),torso.CFrame,true,false)
  915. Soul.Name = 'Head'
  916. NewInstance("Humanoid",Model,{Health=0,MaxHealth=0})
  917. Effect{
  918. Effect="Arc",
  919. Manual = Soul,
  920. FXSettings={
  921. Start=torso.CFrame,
  922. Home = Torso,
  923. RemoveOnGoal = true,
  924. }
  925. }
  926. local lastPoint = Soul.CFrame.p
  927.  
  928. for i = 0, 1, 0.01 do
  929. local point = CFrame.new(lastPoint, Soul.Position) * CFrame.Angles(-math.pi/2, 0, 0)
  930. local mag = (lastPoint - Soul.Position).magnitude
  931. Effect{
  932. Effect = "Fade",
  933. CFrame = point * CF.N(0, mag/2, 0),
  934. Size = V3.N(.5,mag+.5,.5),
  935. Color = Soul.BrickColor
  936. }
  937. lastPoint = Soul.CFrame.p
  938. swait()
  939. end
  940. for i = 1, 5 do
  941. Effect{
  942. Effect="Fade",
  943. Color = BrickColor.new'Really red',
  944. MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p
  945. }
  946. end
  947. end
  948. end
  949.  
  950. --// Other Functions \\ --
  951.  
  952. function CastRay(startPos,endPos,range,ignoreList)
  953. local ray = Ray.new(startPos,(endPos-startPos).unit*range)
  954. local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
  955. return part,pos,norm,(pos and (startPos-pos).magnitude)
  956. end
  957.  
  958. function getRegion(point,range,ignore)
  959. return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100)
  960. end
  961.  
  962. function clerp(startCF,endCF,alpha)
  963. return startCF:lerp(endCF, alpha)
  964. end
  965.  
  966. function GetTorso(char)
  967. return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart'
  968. end
  969.  
  970.  
  971. function ShowDamage(Pos, Text, Time, Color)
  972. coroutine.wrap(function()
  973. local Rate = (1 / Frame_Speed)
  974. local Pos = (Pos or Vector3.new(0, 0, 0))
  975. local Text = (Text or "")
  976. local Time = (Time or 2)
  977. local Color = (Color or Color3.new(1, 0, 1))
  978. local EffectPart = NewInstance("Part",Effects,{
  979. Material=Enum.Material.SmoothPlastic,
  980. Reflectance = 0,
  981. Transparency = 1,
  982. BrickColor = BrickColor.new(Color),
  983. Name = "Effect",
  984. Size = Vector3.new(0,0,0),
  985. Anchored = true,
  986. CFrame = CF.N(Pos)
  987. })
  988. local BillboardGui = NewInstance("BillboardGui",EffectPart,{
  989. Size = UDim2.new(1.25, 0, 1.25, 0),
  990. Adornee = EffectPart,
  991. })
  992. local TextLabel = NewInstance("TextLabel",BillboardGui,{
  993. BackgroundTransparency = 1,
  994. Size = UDim2.new(1, 0, 1, 0),
  995. Text = Text,
  996. Font = "Bodoni",
  997. TextColor3 = Color,
  998. TextStrokeColor3 = Color3.new(0,0,0),
  999. TextStrokeTransparency=0,
  1000. TextScaled = true,
  1001. })
  1002. S.Debris:AddItem(EffectPart, (Time))
  1003. EffectPart.Parent = workspace
  1004. delay(0, function()
  1005. Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
  1006. local Frames = (Time / Rate)
  1007. for Frame = 1, Frames do
  1008. swait()
  1009. local Percent = (Frame / Frames)
  1010. TextLabel.TextTransparency = Percent
  1011. TextLabel.TextStrokeTransparency = Percent
  1012. end
  1013. if EffectPart and EffectPart.Parent then
  1014. EffectPart:Destroy()
  1015. end
  1016. end) end)()
  1017. end
  1018.  
  1019. function DealDamage(data)
  1020. local Who = data.Who;
  1021. local MinDam = data.MinimumDamage or 15;
  1022. local MaxDam = data.MaximumDamage or 30;
  1023. local MaxHP = data.MaxHP or 1e5;
  1024.  
  1025. local DB = data.Debounce or .2;
  1026.  
  1027. local CritData = data.Crit or {}
  1028. local CritChance = CritData.Chance or 0;
  1029. local CritMultiplier = CritData.Multiplier or 1;
  1030.  
  1031. local DamageEffects = data.DamageFX or {}
  1032. local DamageType = DamageEffects.Type or "Normal"
  1033. local DeathFunction = DamageEffects.DeathFunction
  1034.  
  1035. assert(Who,"Specify someone to damage!")
  1036.  
  1037. local Humanoid = Who:FindFirstChildOfClass'Humanoid'
  1038. local DoneDamage = M.RNG(MinDam,MaxDam) * (M.RNG(1,100) <= CritChance and CritMultiplier or 1)
  1039.  
  1040. local canHit = true
  1041. if(Humanoid)then
  1042. for _, p in pairs(Hit) do
  1043. if p[1] == Humanoid then
  1044. if(time() - p[2] <= DB) then
  1045. canHit = false
  1046. else
  1047. Hit[_] = nil
  1048. end
  1049. end
  1050. end
  1051. if(canHit)then
  1052. table.insert(Hit,{Humanoid,time()})
  1053. local HitTorso = GetTorso(Who)
  1054. local player = S.Players:GetPlayerFromCharacter(Who)
  1055. if(not player or player.UserId ~= 5719877 and player.UserId ~= 61573184 and player.UserId ~= 19081129)then
  1056. if(Humanoid.MaxHealth >= MaxHP and Humanoid.Health > 0)then
  1057. print'Got kill'
  1058. Humanoid.Health = 0;
  1059. Who:BreakJoints();
  1060. if(DeathFunction)then DeathFunction(Who,Humanoid) end
  1061. else
  1062. local c = Instance.new("ObjectValue",Hum)
  1063. c.Name = "creator"
  1064. c.Value = Plr
  1065. S.Debris:AddItem(c,0.35)
  1066. if(Who:FindFirstChild'Head' and Humanoid.Health > 0)then
  1067. ShowDamage((Who.Head.CFrame * CF.N(0, 0, (Who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), DoneDamage, 1.5, DamageColor.Color)
  1068. end
  1069. if(Humanoid.Health > 0 and Humanoid.Health-DoneDamage <= 0)then print'Got kill' if(DeathFunction)then DeathFunction(Who,Humanoid) end end
  1070. Humanoid.Health = Humanoid.Health - DoneDamage
  1071.  
  1072. if(DamageType == 'Knockback' and HitTorso)then
  1073. local up = DamageEffects.KnockUp or 25
  1074. local back = DamageEffects.KnockBack or 25
  1075. local origin = DamageEffects.Origin or Root
  1076. local decay = DamageEffects.Decay or .5;
  1077.  
  1078. local bfos = Instance.new("BodyVelocity",HitTorso)
  1079. bfos.P = 20000
  1080. bfos.MaxForce = Vector3.new(math.huge,math.huge,math.huge)
  1081. bfos.Velocity = Vector3.new(0,up,0) + (origin.CFrame.lookVector * back)
  1082. S.Debris:AddItem(bfos,decay)
  1083. end
  1084. end
  1085. end
  1086. end
  1087. end
  1088. end
  1089.  
  1090. function Kill(whom,hum)
  1091. whom:breakJoints()
  1092. swait()
  1093. angerCounter = 1
  1094. local t = GetTorso(whom)
  1095. if(t)then
  1096. SoundPart(1846449729,1,1,false,true,true,t.CFrame)
  1097. end
  1098. whom:destroy()
  1099. end
  1100.  
  1101. function AOEDamage(where,range,options)
  1102. local hit = {}
  1103. for _,v in next, getRegion(where,range,{Char}) do
  1104. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' and not hit[v.Parent])then
  1105. local callTable = {Who=v.Parent}
  1106. hit[v.Parent] = true
  1107. for _,v in next, options do callTable[_] = v end
  1108. DealDamage(callTable)
  1109. end
  1110. end
  1111. return hit
  1112. end
  1113.  
  1114. function AOEKill(where,range)
  1115. local hit = {}
  1116. local closest,closestHum,closestDist=nil,nil,0;
  1117. for _,v in next, getRegion(where,range,{Char}) do
  1118. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' and not hit[v.Parent] and GetTorso(v.Parent))then
  1119. local dist = (closest == nil and math.huge) or (closest.CFrame.p-Root.CFrame.p).magnitude
  1120. if(dist > closestDist)then
  1121. closest = GetTorso(v.Parent)
  1122. closestHum = v.Parent:FindFirstChildOfClass'Humanoid'
  1123. closestDist = dist
  1124. end
  1125. end
  1126. end
  1127. if(closest)then
  1128. Kill(closest.Parent,closestHum)
  1129. end
  1130. return closest
  1131. end
  1132.  
  1133. function CheckAOE(where,range)
  1134. local hit = {}
  1135. for _,v in next, getRegion(where,range,{Char}) do
  1136. if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' and not hit[v.Parent] and GetTorso(v.Parent))then
  1137. return true
  1138. end
  1139. end
  1140. return false
  1141. end
  1142.  
  1143. function AOEHeal(where,range,amount)
  1144. local healed = {}
  1145. for _,v in next, getRegion(where,range,{Char}) do
  1146. local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil)
  1147. if(hum and not healed[hum])then
  1148. hum.Health = hum.Health + amount
  1149. if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then
  1150. ShowDamage((v.Parent.Head.CFrame * CF.N(0, 0, (v.Parent.Head.Size.Z / 2)).p+V3.N(0,1.5,0)), "+"..amount, 1.5, BrickColor.new'Lime green'.Color)
  1151. end
  1152. end
  1153. end
  1154. end
  1155.  
  1156.  
  1157. --// Wrap it all up \\--
  1158.  
  1159. Mouse.KeyDown:connect(function(k)
  1160. if(k == 'f')then
  1161. angry = not angry
  1162. end
  1163. end)
  1164.  
  1165. local idle = 0;
  1166. local gat = 0;
  1167. local smacked = false;
  1168. while true do
  1169. swait()
  1170. Sine = Sine + Change
  1171. if(not Music or not Music.Parent)then
  1172. local tp = (Music and Music.TimePosition)
  1173. Music = Sound(Char,MusicID,1,10,true,false,true)
  1174. Music.Name = 'Music'
  1175. Music.TimePosition = tp
  1176. end
  1177. Music.SoundId = "rbxassetid://"..MusicID
  1178. Music.Parent = Torso
  1179. Music.Pitch = 1
  1180. Music.Volume = 3
  1181. if(not angry)then
  1182. Music:Resume()
  1183. else
  1184. Music:Pause()
  1185. end
  1186.  
  1187. Torso.BrickColor = BrickColor.new'Bright green'
  1188. Head.BrickColor = BrickColor.new'Pastel brown'
  1189. RArm.BrickColor = BrickColor.new'Bright green'
  1190. LArm.BrickColor = BrickColor.new'Bright green'
  1191. RLeg.BrickColor = BrickColor.new'Deep blue'
  1192. LLeg.BrickColor = BrickColor.new'Deep blue'
  1193. if(God)then
  1194. Hum.MaxHealth = 1e100
  1195. Hum.Health = 1e100
  1196. if(not Char:FindFirstChildOfClass'ForceField')then IN("ForceField",Char).Visible = false end
  1197. Hum.Name = M.RNG()*100
  1198. end
  1199.  
  1200. local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4*PlayerSize)), Char)
  1201.  
  1202. local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1)
  1203. local State = (Hum.PlatformStand and 'Paralyzed' or Hum.Sit and 'Sit' or not hitfloor and Root.Velocity.y < -1 and "Fall" or not hitfloor and Root.Velocity.y > 1 and "Jump" or hitfloor and Walking and (Hum.WalkSpeed < 24 and "Walk" or "Run") or hitfloor and "Idle")
  1204. if(not Effects or not Effects.Parent)then
  1205. Effects = IN("Model",Char)
  1206. Effects.Name = "Effects"
  1207. end
  1208.  
  1209. Hum.WalkSpeed = WalkSpeed
  1210. if(Remove_Hats)then Instance.ClearChildrenOfClass(Char,"Accessory",true) end
  1211. if(Remove_Clothing)then Instance.ClearChildrenOfClass(Char,"Clothing",true) Instance.ClearChildrenOfClass(Char,"ShirtGraphic",true) end
  1212.  
  1213. if(angry)then
  1214. local AOE = CheckAOE(Torso.CFrame.p,100)
  1215. if(not AOE)then
  1216. angerCounter = math.min(angerCounter+.005,4)
  1217. end
  1218. rule.Transparency = 0
  1219. ld.Transparency = 0
  1220. rd.Transparency = 0
  1221. idle = idle + 1
  1222.  
  1223. if(idle < (angerCounter*15))then
  1224. WalkSpeed = 0
  1225. gat = 0
  1226. NK.C0 = NKC0
  1227. RJ.C0 = RJC0
  1228. LS.C0 = LSC0*CF.N(0,0,-.25)*CF.A(M.R(65),M.R(180),0)
  1229. RS.C0 = RSC0*CF.A(M.R(90),0,0)
  1230. LH.C0 = LHC0
  1231. RH.C0 = RHC0
  1232. smacked = false
  1233. else
  1234. AOEKill(Torso.CFrame.p,3)
  1235. WalkSpeed = 24
  1236. local fat = (idle - (angerCounter*15))
  1237. if(fat > 9)then
  1238. gat = gat - 10
  1239. if(not smacked)then
  1240. CamShakeAll(15,15,rule)
  1241. smacked = true
  1242. Sound(rule,1804495872,1,3,false,true,true)
  1243. end
  1244. else
  1245. gat = gat + 10
  1246. end
  1247. if(gat <= 0)then
  1248. idle = 0
  1249. end
  1250. NK.C0 = NKC0
  1251. RJ.C0 = RJC0
  1252. LS.C0 = LSC0*CF.N(0,0,-.25)*CF.A(M.R(65),M.R(180),0)
  1253. RS.C0 = RSC0*CF.A(M.R(90),M.R(gat),0)
  1254. LH.C0 = LHC0
  1255. RH.C0 = RHC0
  1256. end
  1257. else
  1258. idle = 0
  1259. gat = 0
  1260. rule.Transparency = 1
  1261. ld.Transparency = 1
  1262. rd.Transparency = 1
  1263. WalkSpeed = 0
  1264. NK.C0 = NKC0
  1265. RJ.C0 = RJC0
  1266. LS.C0 = LSC0
  1267. RS.C0 = RSC0
  1268. LH.C0 = LHC0
  1269. RH.C0 = RHC0
  1270. smacked = false
  1271. end
  1272. for i,v in next, BloodPuddles do
  1273. local mesh = i:FindFirstChild'CylinderMesh'
  1274. BloodPuddles[i] = v + 1
  1275. if(not mesh or i.Transparency >= 1)then
  1276. i:destroy()
  1277. BloodPuddles[i] = nil
  1278. elseif(v >= Frame_Speed*4)then
  1279. local trans = (v-Frame_Speed*4)/(Frame_Speed*2)
  1280. i.Transparency = trans
  1281. if(mesh.Scale.Z > 0)then
  1282. mesh.Scale = mesh.Scale-V3.N(.05,0,.05)
  1283. end
  1284. else
  1285. i.Transparency = 0
  1286. end
  1287. end
  1288. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement