Advertisement
NextFlamePB

ROBLOX Weaboo Script

Dec 18th, 2016
2,896
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 28.86 KB | None | 0 0
  1.  
  2. //{Controls:              
  3. // F - Toggle Memes
  4. ==================================]}
  5. --]]
  6.  
  7. Player=game:GetService("Players").LocalPlayer
  8. Character=Player.Character
  9. PlayerGui=Player.PlayerGui
  10. Backpack=Player.Backpack
  11. Torso=Character.Torso
  12. Head=Character.Head
  13. Humanoid=Character.Humanoid
  14. m=Instance.new('Model',Character)
  15. LeftArm=Character["Left Arm"]
  16. LeftLeg=Character["Left Leg"]
  17. RightArm=Character["Right Arm"]
  18. RightLeg=Character["Right Leg"]
  19. LS=Torso["Left Shoulder"]
  20. LH=Torso["Left Hip"]
  21. RS=Torso["Right Shoulder"]
  22. RH=Torso["Right Hip"]
  23. Neck=Torso.Neck
  24. it=Instance.new
  25. attacktype=1
  26. vt=Vector3.new
  27. cf=CFrame.new
  28. euler=CFrame.fromEulerAnglesXYZ
  29. angles=CFrame.Angles
  30. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  31. necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  32. LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
  33. LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
  34. RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
  35. RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
  36. RootPart=Character.HumanoidRootPart
  37. RootJoint=RootPart.RootJoint
  38. RootCF=euler(-1.57,0,3.14)
  39. attack = false
  40. attackdebounce = false
  41. deb=false
  42. equipped=true
  43. hand=false
  44. MMouse=nil
  45. combo=0
  46. mana=0
  47. cam=workspace.CurrentCamera
  48. RocketTarget=nil
  49. Targetting=false
  50. trispeed=.2
  51. attackmode='none'
  52. local idle=0
  53. local Anim="Idle"
  54. local Effects={}
  55. local gun=false
  56. local shoot=false
  57. local issprinting=false
  58. local memeing=false
  59. player=nil
  60. mouse=Player:GetMouse()
  61. --save shoulders
  62. RSH, LSH=nil, nil
  63. --welds
  64. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  65. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  66. LH=Torso["Left Hip"]
  67. RH=Torso["Right Hip"]
  68. TorsoColor=Torso.BrickColor
  69. function NoOutline(Part)
  70. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  71. end
  72. player=Player
  73. ch=Character
  74. RSH=ch.Torso["Right Shoulder"]
  75. LSH=ch.Torso["Left Shoulder"]
  76. --
  77. RSH.Parent=nil
  78. LSH.Parent=nil
  79. --
  80. RW.Name="Right Shoulder"
  81. RW.Part0=ch.Torso
  82. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  83. RW.C1=cf(0, 0.5, 0)
  84. RW.Part1=ch["Right Arm"]
  85. RW.Parent=ch.Torso
  86. --
  87. LW.Name="Left Shoulder"
  88. LW.Part0=ch.Torso
  89. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  90. LW.C1=cf(0, 0.5, 0)
  91. LW.Part1=ch["Left Arm"]
  92. LW.Parent=ch.Torso
  93.  
  94. if Humanoid:findFirstChild("Animate") then
  95.   Humanoid:findFirstChild("Animate"):Destroy()
  96. elseif Character:findFirstChild("Animate") then
  97.   Character:findFirstChild("Animate"):Destroy()
  98. end
  99.  
  100.  
  101. local WEEB = Instance.new("Sound",Torso)
  102. WEEB.Volume=0
  103. WEEB.Pitch=0
  104. WEEB.SoundId="http://www.roblox.com/asset/?id=239632147"
  105. WEEB.Looped=true
  106. wait()
  107. WEEB:play()
  108.  
  109.  
  110. local Stats=Instance.new("BoolValue")
  111. Stats.Name="Stats"
  112. Stats.Parent=Character
  113. local Atk=Instance.new("NumberValue")
  114. Atk.Name="Damage"
  115. Atk.Parent=Stats
  116. Atk.Value=1
  117. local Def=Instance.new("NumberValue")
  118. Def.Name="Defense"
  119. Def.Parent=Stats
  120. Def.Value=1
  121. local Speed=Instance.new("NumberValue")
  122. Speed.Name="Speed"
  123. Speed.Parent=Stats
  124. Speed.Value=1
  125. local Mvmt=Instance.new("NumberValue")
  126. Mvmt.Name="Movement"
  127. Mvmt.Parent=Stats
  128. Mvmt.Value=1
  129.  
  130.  
  131. local donum=0
  132.  
  133. function part(formfactor,parent,reflectance,transparency,brickcolor,name,size)
  134. local fp=it("Part")
  135. fp.formFactor=formfactor
  136. fp.Parent=parent
  137. fp.Reflectance=reflectance
  138. fp.Transparency=transparency
  139. fp.CanCollide=false
  140. fp.Locked=true
  141. fp.BrickColor=brickcolor
  142. fp.Name=name
  143. fp.Size=size
  144. fp.Position=Torso.Position
  145. NoOutline(fp)
  146. fp.Material="SmoothPlastic"
  147. fp:BreakJoints()
  148. return fp
  149. end
  150.  
  151. function part2(formfactor, parent, material, reflectance, transparency, brickcolor, name, size)
  152.     local fp = Instance.new("Part")
  153.         fp.formFactor = formfactor
  154.         fp.Parent = parent
  155.         fp.Reflectance = reflectance
  156.         fp.Transparency = transparency
  157.         fp.CanCollide = false
  158.         fp.Locked = true
  159.         fp.BrickColor = BrickColor.new(tostring(brickcolor))
  160.         fp.Name = name
  161.         fp.Size = size
  162.         fp.Position = Character.Torso.Position
  163.         fp.Material = material
  164.    
  165.     NoOutline(fp)
  166.     return fp
  167. end
  168.  
  169. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  170. local mesh=it(Mesh)
  171. mesh.Parent=part
  172. if Mesh=="SpecialMesh" then
  173. mesh.MeshType=meshtype
  174. mesh.MeshId=meshid
  175. end
  176. mesh.Offset=offset
  177. mesh.Scale=scale
  178. return mesh
  179. end
  180.  
  181. function weld(parent,part0,part1,c0)
  182. local weld=it("Weld")
  183. weld.Parent=parent
  184. weld.Part0=part0
  185. weld.Part1=part1
  186. weld.C0=c0
  187. return weld
  188. end
  189.  
  190. function weld2(parent, part0, part1, c0, c1)
  191.     local Weld = Instance.new("Weld")
  192.         Weld.Parent = parent
  193.         Weld.Part0 = part0
  194.         Weld.Part1 = part1
  195.         Weld.C0 = c0
  196.         Weld.C1 = c1
  197.    
  198.     return Weld
  199. end
  200.  
  201. local Color1=Torso.BrickColor
  202.  
  203. local bodvel=Instance.new("BodyVelocity")
  204. local bg=Instance.new("BodyGyro")
  205.  
  206. ArtificialHB = Instance.new("BindableEvent", script)
  207. ArtificialHB.Name = "Heartbeat"
  208.  
  209. script:WaitForChild("Heartbeat")
  210.  
  211. frame = 1 / 60
  212. tf = 0
  213. allowframeloss = true
  214. tossremainder = false
  215. lastframe = tick()
  216. script.Heartbeat:Fire()
  217.  
  218. game:GetService("RunService").Heartbeat:connect(function(s, p)
  219.     tf = tf + s
  220.     if tf >= frame then
  221.         if allowframeloss then
  222.             script.Heartbeat:Fire()
  223.             lastframe = tick()
  224.         else
  225.             for i = 1, math.floor(tf / frame) do
  226.                 script.Heartbeat:Fire()
  227.             end
  228.             lastframe = tick()
  229.         end
  230.         if tossremainder then
  231.             tf = 0
  232.         else
  233.             tf = tf - frame * math.floor(tf / frame)
  234.         end
  235.     end
  236. end)
  237.  
  238. function swait(num)
  239.     if num == 0 or num == nil then
  240.         ArtificialHB.Event:wait()
  241.     else
  242.         for i = 0, num do
  243.             ArtificialHB.Event:wait()
  244.         end
  245.     end
  246. end
  247.  
  248.  
  249. so = function(id,par,vol,pit)
  250. coroutine.resume(coroutine.create(function()
  251. local sou = Instance.new("Sound",par or workspace)
  252. sou.Volume=vol
  253. sou.Pitch=pit or 1
  254. sou.SoundId=id
  255. swait()
  256. sou:play()
  257. game:GetService("Debris"):AddItem(sou,6)
  258. end))
  259. end
  260.  
  261. function clerp(a,b,t)
  262. local qa = {QuaternionFromCFrame(a)}
  263. local qb = {QuaternionFromCFrame(b)}
  264. local ax, ay, az = a.x, a.y, a.z
  265. local bx, by, bz = b.x, b.y, b.z
  266. local _t = 1-t
  267. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  268. end
  269.  
  270. function QuaternionFromCFrame(cf)
  271. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  272. local trace = m00 + m11 + m22
  273. if trace > 0 then
  274. local s = math.sqrt(1 + trace)
  275. local recip = 0.5/s
  276. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  277. else
  278. local i = 0
  279. if m11 > m00 then
  280. i = 1
  281. end
  282. if m22 > (i == 0 and m00 or m11) then
  283. i = 2
  284. end
  285. if i == 0 then
  286. local s = math.sqrt(m00-m11-m22+1)
  287. local recip = 0.5/s
  288. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  289. elseif i == 1 then
  290. local s = math.sqrt(m11-m22-m00+1)
  291. local recip = 0.5/s
  292. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  293. elseif i == 2 then
  294. local s = math.sqrt(m22-m00-m11+1)
  295. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  296. end
  297. end
  298. end
  299.  
  300. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  301. local xs, ys, zs = x + x, y + y, z + z
  302. local wx, wy, wz = w*xs, w*ys, w*zs
  303. local xx = x*xs
  304. local xy = x*ys
  305. local xz = x*zs
  306. local yy = y*ys
  307. local yz = y*zs
  308. local zz = z*zs
  309. return CFrame.new(px, py, pz,1-(yy+zz), xy - wz, xz + wy,xy + wz, 1-(xx+zz), yz - wx, xz - wy, yz + wx, 1-(xx+yy))
  310. end
  311.  
  312. function QuaternionSlerp(a, b, t)
  313. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  314. local startInterp, finishInterp;
  315. if cosTheta >= 0.0001 then
  316. if (1 - cosTheta) > 0.0001 then
  317. local theta = math.acos(cosTheta)
  318. local invSinTheta = 1/math.sin(theta)
  319. startInterp = math.sin((1-t)*theta)*invSinTheta
  320. finishInterp = math.sin(t*theta)*invSinTheta  
  321. else
  322. startInterp = 1-t
  323. finishInterp = t
  324. end
  325. else
  326. if (1+cosTheta) > 0.0001 then
  327. local theta = math.acos(-cosTheta)
  328. local invSinTheta = 1/math.sin(theta)
  329. startInterp = math.sin((t-1)*theta)*invSinTheta
  330. finishInterp = math.sin(t*theta)*invSinTheta
  331. else
  332. startInterp = t-1
  333. finishInterp = t
  334. end
  335. end
  336. return a[1]*startInterp + b[1]*finishInterp, a[2]*startInterp + b[2]*finishInterp, a[3]*startInterp + b[3]*finishInterp, a[4]*startInterp + b[4]*finishInterp
  337. end
  338.  
  339. function rayCast(Pos, Dir, Max, Ignore)  -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  340. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  341. end
  342.  
  343. Damagefunc = function(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) --bm1
  344.     if hit.Parent == nil then
  345.         return
  346.     end
  347.     local h = hit.Parent:FindFirstChild("Humanoid")
  348.     for _, v in pairs(hit.Parent:children()) do
  349.         if v:IsA("Humanoid") then
  350.             h = v
  351.         end
  352.     end
  353.     if h ~= nil and hit.Parent.Name ~= Character.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
  354.         if hit.Parent:findFirstChild("DebounceHit") ~= nil then
  355.             if hit.Parent.DebounceHit.Value == true then
  356.                 return
  357.             end
  358.         end
  359.         if h.MaxHealth >= math.huge then
  360.             hit:BreakJoints()
  361.         end
  362.         --[[                if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  363.                         return
  364.                 end]]
  365. --                        hs(hit,1.2)
  366.         local c = Instance.new("ObjectValue")
  367.             c.Name = "creator"
  368.             c.Value = game:service("Players").LocalPlayer
  369.             c.Parent = h
  370.        
  371.         game:GetService("Debris"):AddItem(c, .5)
  372.         if HitSound ~= nil and HitPitch ~= nil then
  373.             so(HitSound, hit, 1, HitPitch)
  374.         end
  375.         local Damage = math.random(minim, maxim)
  376. --                h:TakeDamage(Damage)
  377.         local blocked = false
  378.         local block = hit.Parent:findFirstChild("Block")
  379.         if block ~= nil then
  380.             if block.className == "IntValue" then
  381.                 if block.Value > 0 then
  382.                     blocked = true
  383.                     block.Value = block.Value - 1
  384.                     print(block.Value)
  385.                 end
  386.             end
  387.         end
  388.         if blocked == false then
  389. --                h:TakeDamage(Damage)
  390.             h.Health = h.Health - Damage
  391.             if Damage ~= 0 then
  392.             ShowDamage2((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, BrickColor.new("Institutional white").Color)
  393.             end
  394.         else
  395.             h.Health = h.Health - (Damage / 2)
  396.             if Damage ~=0 then
  397.             ShowDamage2((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, BrickColor.new("Institutional white").Color)
  398.             end
  399.         end
  400.         if Type == "Knockdown" then
  401.             local hum = hit.Parent.Humanoid
  402.             hum.PlatformStand = true
  403.             coroutine.resume(coroutine.create(function(HHumanoid)
  404.                 swait(1)
  405.                 HHumanoid.PlatformStand = false
  406.             end), hum)
  407.             local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit
  408.             local bodvol = Instance.new("BodyVelocity")
  409.                 bodvol.velocity = angle * knockback
  410.                 bodvol.P = 5000
  411.                 bodvol.maxForce = Vector3.new(8e+003, 8e+003, 8e+003)
  412.                 bodvol.Parent = hit
  413.            
  414.             local rl = Instance.new("BodyAngularVelocity")
  415.                 rl.P = 3000
  416.                 rl.maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000
  417.                 rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10))
  418.                 rl.Parent = hit
  419.            
  420.             game:GetService("Debris"):AddItem(bodvol, .5)
  421.             game:GetService("Debris"):AddItem(rl, .5)
  422.         elseif Type == "Plat" then
  423.             local hum = hit.Parent.Humanoid
  424.             hum.PlatformStand = true
  425.             coroutine.resume(coroutine.create(function(HHumanoid)
  426.                 swait(2)
  427.                 HHumanoid.PlatformStand = false
  428.             end), hum)
  429.  
  430.             local rl = Instance.new("BodyAngularVelocity")
  431.                 rl.P = 3000
  432.                 rl.maxTorque = Vector3.new(100, 100, 100) * 500
  433.                 rl.angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10))
  434.                 rl.Parent = hit
  435.                
  436.             game:GetService("Debris"):AddItem(rl, .5)
  437.         elseif Type == "Normal" then
  438.             local vp = Instance.new("BodyVelocity")
  439.                 vp.P = 500
  440.                 vp.maxForce = Vector3.new(math.huge, 0, math.huge)
  441.                 vp.velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05
  442.            
  443.             if knockback > 0 then
  444.                 vp.Parent = hit.Parent.Torso
  445.             end
  446.             game:GetService("Debris"):AddItem(vp, .5)
  447.         elseif Type == "Up" then
  448.             local bodyVelocity = Instance.new("BodyVelocity")
  449.                 bodyVelocity.velocity = vt(0, 20, 0)
  450.                 bodyVelocity.P = 5000
  451.                 bodyVelocity.maxForce = Vector3.new(8e+003, 8e+003, 8e+003)
  452.                 bodyVelocity.Parent = hit
  453.            
  454.             game:GetService("Debris"):AddItem(bodyVelocity, .5)
  455.         elseif Type == "Snare" then
  456.             local bp = Instance.new("BodyPosition")
  457.                 bp.P = 2000
  458.                 bp.D = 100
  459.                 bp.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  460.                 bp.position = hit.Parent.Torso.Position
  461.                 bp.Parent = hit.Parent.Torso
  462.             game:GetService("Debris"):AddItem(bp, 1)
  463.  
  464.         elseif Type == "Freeze" then
  465.             local BodPos = Instance.new("BodyPosition")
  466.                 BodPos.P = 50000
  467.                 BodPos.D = 1000
  468.                 BodPos.maxForce = Vector3.new(math.huge, math.huge, math.huge)
  469.                 BodPos.position = hit.Parent.Torso.Position
  470.                 BodPos.Parent = hit.Parent.Torso
  471.            
  472.             local BodGy = Instance.new("BodyGyro")
  473.                 BodGy.maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge
  474.                 BodGy.P = 20e+003
  475.                 BodGy.Parent = hit.Parent.Torso
  476.                 BodGy.cframe = hit.Parent.Torso.CFrame
  477.            
  478.             hit.Parent.Torso.Anchored = true
  479.             coroutine.resume(coroutine.create(function(Part)
  480.                 swait(1.5)
  481.                 Part.Anchored = false
  482.             end), hit.Parent.Torso)
  483.             game:GetService("Debris"):AddItem(BodPos, 3)
  484.             game:GetService("Debris"):AddItem(BodGy, 3)
  485.        
  486.        
  487.                 elseif Type=="Target" then
  488.                 if Targetting==false then
  489.                 ZTarget=hit.Parent.Torso
  490.                 coroutine.resume(coroutine.create(function(Part)
  491.                 so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)  
  492.                 swait(5)
  493.                 so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  494.                 end),ZTarget)
  495.                 TargHum=ZTarget.Parent:findFirstChild("Humanoid")
  496.                 targetgui=Instance.new("BillboardGui")
  497.                 targetgui.Parent=ZTarget
  498.                 targetgui.Size=UDim2.new(10,100,10,100)
  499.                 targ=Instance.new("ImageLabel")
  500.                 targ.Parent=targetgui
  501.                 targ.BackgroundTransparency=1
  502.                 targ.Image="rbxassetid://4834067"
  503.                 targ.Size=UDim2.new(1,0,1,0)
  504.                 cam.CameraType="Scriptable"
  505.                 cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  506.                 dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  507.                 workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  508.                 Targetting=true
  509.                 RocketTarget=ZTarget
  510.                 for i=1,Property do
  511.                 if Humanoid.Health>0 and Character.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then
  512.                 swait()
  513.                 end
  514.                 cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  515.                 dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  516.                 cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0)
  517.                 end
  518.                 Targetting=false
  519.                 RocketTarget=nil
  520.                 targetgui.Parent=nil
  521.                 cam.CameraType="Custom"
  522.                 end
  523.         end    
  524.        
  525.         local debounce = Instance.new("BoolValue")
  526.         debounce.Name = "DebounceHit"
  527.         debounce.Parent = hit.Parent
  528.         debounce.Value = true
  529.         game:GetService("Debris"):AddItem(debounce, Delay)
  530.         c = Instance.new("ObjectValue")
  531.         c.Name = "creator"
  532.         c.Value = Player
  533.         c.Parent = h
  534.         game:GetService("Debris"):AddItem(c, .5)
  535.     end
  536. end
  537.  
  538. function ShowDamage2(Pos, Text, Time, Color)
  539.     local Rate = (1 / 30)
  540.     local Pos = (Pos or Vector3.new(0, 0, 0))
  541.     local Text = (Text or "")
  542.     local Time = (Time or 2)
  543.     local Color = (Color or Color3.new(1, 0, 0))
  544.     local EffectPart = part2("Custom", workspace, "Neon", 0, 1, BrickColor.new(Color), "Effect", vt(0, 0, 0))
  545.     EffectPart.Anchored = true
  546.     local BillboardGui = Instance.new("BillboardGui")
  547.         BillboardGui.Size = UDim2.new(3, 0, 3, 0)
  548.         BillboardGui.Adornee = EffectPart
  549.         BillboardGui.Parent = EffectPart
  550.    
  551.     local TextLabel = Instance.new("TextLabel")
  552.         TextLabel.BackgroundTransparency = 1
  553.         TextLabel.Size = UDim2.new(1, 0, 1, 0)
  554.         TextLabel.Text = Text
  555.         TextLabel.TextColor3 = Color
  556.         TextLabel.TextScaled = true
  557.         TextLabel.Font = Enum.Font.ArialBold
  558.         TextLabel.Parent = BillboardGui
  559.    
  560.     game.Debris:AddItem(EffectPart, (Time + 0.1))
  561.     EffectPart.Parent = game:GetService("Workspace")
  562.     delay(0, function()
  563.         local Frames = (Time / Rate)
  564.         for Frame = 1, Frames do
  565.             wait(Rate)
  566.             local Percent = (Frame / Frames)
  567.             EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0)
  568.             TextLabel.TextTransparency = Percent
  569.         end
  570.         if EffectPart and EffectPart.Parent then
  571.             EffectPart:Destroy()
  572.         end
  573.     end)
  574. end
  575.  
  576. function BlastEffect(brickcolor, cframe, x1, y1, z1, x2, y2, z2)
  577.     local prt = part2(3, workspace, "Neon", 0, 0, brickcolor, "Effect", vt(0.5, 0.5, 0.5))
  578.     prt.Anchored = true
  579.     prt.CFrame = cframe
  580.     local msh = mesh("SpecialMesh", prt, "FileMesh", "http://www.roblox.com/asset/?id=20329976", vt(0, 0, 0), vt(x1, y1, z1))
  581.     coroutine.resume(coroutine.create(function()
  582.         for i = 0, 1, 0.05 do
  583.             wait()
  584.             prt.Transparency = i
  585.             msh.Scale = msh.Scale + vt(x2, y2, z2)
  586.         end
  587.         prt.Parent = nil
  588.     end))
  589. end
  590.  
  591. function weld(parent, part0, part1, c0, c1)
  592.     local Weld = Instance.new("Weld")
  593.         Weld.Parent = parent
  594.         Weld.Part0 = part0
  595.         Weld.Part1 = part1
  596.         Weld.C0 = c0
  597.         Weld.C1 = c1
  598.    
  599.     return Weld
  600. end
  601.  
  602. function MagniDamage(Hit, Part, magni, mindam, maxdam, knock, Type)
  603.     for _, c in pairs(workspace:children()) do
  604.         local hum = c:findFirstChild("Humanoid")
  605.         if hum ~= nil then
  606.             local head = c:findFirstChild("Torso")
  607.             if head ~= nil then
  608.                 local targ = head.Position - Part.Position
  609.                 local mag = targ.magnitude
  610.                 if mag <= magni and c.Name ~= Player.Name then
  611.                     Damagefunc(head, head, mindam, maxdam, knock, Type, RootPart, .2, 1, 3)
  612.                 end
  613.             end
  614.         end
  615.     end
  616. end
  617.  
  618. function MagicCircle(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay)
  619.     local prt = part2(3, workspace, "Neon", 0, 0, brickcolor, "Effect", vt(0.5, 0.5, 0.5))
  620.     prt.Anchored = true
  621.     prt.CFrame = cframe
  622.     local msh = mesh("SpecialMesh", prt, "Sphere", "", vt(0, 0, 0), vt(x1, y1, z1))
  623.     game:GetService("Debris"):AddItem(prt, 2)
  624.     coroutine.resume(coroutine.create(function(Part, Mesh)
  625.         for i = 0, 1, delay do
  626.             swait()
  627.             Part.CFrame = Part.CFrame
  628.             Part.Transparency = i
  629.             Mesh.Scale = Mesh.Scale + vt(x3, y3, z3)
  630.         end
  631.         Part.Parent = nil
  632.     end), prt, msh)
  633. end
  634.  
  635. function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  636.     local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  637.     prt.Anchored=true
  638.     prt.CFrame=cframe
  639.     local msh = mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  640.     game:GetService("Debris"):AddItem(prt,2)
  641.     coroutine.resume(coroutine.create(function(Part,Mesh)
  642.         for i=0,1,delay do
  643.             swait()
  644.             Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  645.             Part.Transparency=i
  646.             Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  647.         end
  648.         Part.Parent=nil
  649.     end),prt,msh)
  650. end
  651.  
  652.  
  653.     user=game:service'Players'.localPlayer
  654.     char=user.Character
  655.     mouse=user:GetMouse()
  656.    
  657.  
  658. local function weldBetween(a, b, name)
  659.     local weld = Instance.new("ManualWeld")
  660.     weld.Part0 = a
  661.     weld.Part1 = b
  662.     weld.C0 = CFrame.new()
  663.     weld.C1 = b.CFrame:inverse() * a.CFrame
  664.     weld.Parent = a
  665.     weld.Name=name or 'weldb1'
  666.     weld.Parent=m
  667.     return weld;
  668. end
  669.  
  670.  
  671. player=game.Players.localPlayer
  672. char=player.Character
  673. Effects={}
  674. vt=Vector3.new
  675. cf=CFrame.new
  676. euler=CFrame.fromEulerAnglesXYZ
  677. m=Instance.new("Model",char)
  678.  
  679. mouse.Button1Down:connect(function()
  680. print("NEIN")
  681. end)
  682.  
  683. local mdel = false
  684.  
  685. mouse.KeyDown:connect(function(k)
  686.     k=k:lower()
  687.     if k=='f' then
  688.         if attack==false then
  689.             ToggleMemes()
  690.         end
  691.     end
  692. end)
  693.  
  694. function ToggleMemes()
  695.     if memeing == true and mdel == false then
  696.         memeing = false
  697.         issprinting=false
  698.         Humanoid.WalkSpeed = 16
  699.         mdel = true
  700.         for i = 1,0,-0.1 do
  701.             wait(0.05)
  702.             WEEB.Volume = i
  703.         end
  704.         WEEB.Pitch = 0
  705.         mdel = false
  706.     elseif memeing == false and mdel == false then
  707.         memeing = true
  708.         issprinting=true
  709.         Humanoid.WalkSpeed=35
  710.         WEEB.Pitch = 1
  711.         mdel = true
  712.         for i = 0,1,.1 do
  713.             wait(0.05)
  714.             WEEB.Volume = i
  715.         end
  716.         mdel = false
  717.     end
  718. end
  719.  
  720. local function CFrameFromTopBack(at, top, back)
  721. local right = top:Cross(back)
  722. return CFrame.new(at.x, at.y, at.z,
  723. right.x, top.x, back.x,
  724. right.y, top.y, back.y,
  725. right.z, top.z, back.z)
  726. end
  727.  
  728. function Triangle(a, b, c)
  729. local edg1 = (c-a):Dot((b-a).unit)
  730. local edg2 = (a-b):Dot((c-b).unit)
  731. local edg3 = (b-c):Dot((a-c).unit)
  732. if edg1 <= (b-a).magnitude and edg1 >= 0 then
  733. a, b, c = a, b, c
  734. elseif edg2 <= (c-b).magnitude and edg2 >= 0 then
  735. a, b, c = b, c, a
  736. elseif edg3 <= (a-c).magnitude and edg3 >= 0 then
  737. a, b, c = c, a, b
  738. else
  739. assert(false, "unreachable")
  740. end
  741.  
  742. local len1 = (c-a):Dot((b-a).unit)
  743. local len2 = (b-a).magnitude - len1
  744. local width = (a + (b-a).unit*len1 - c).magnitude
  745.  
  746. local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit)
  747.  
  748. local list = {}
  749.  
  750. if len1 > 0.01 then
  751. local w1 = Instance.new('WedgePart', m)
  752. game:GetService("Debris"):AddItem(w1,5)
  753. w1.Material = "SmoothPlastic"
  754. w1.FormFactor = 'Custom'
  755. w1.BrickColor = TorsoColor
  756. w1.Transparency = 0
  757. w1.Reflectance = 0
  758. w1.Material = "SmoothPlastic"
  759. w1.CanCollide = false
  760. NoOutline(w1)
  761. local sz = Vector3.new(0.2, width, len1)
  762. w1.Size = sz
  763. local sp = Instance.new("SpecialMesh",w1)
  764. sp.MeshType = "Wedge"
  765. sp.Scale = Vector3.new(0,1,1) * sz/w1.Size
  766. w1:BreakJoints()
  767. w1.Anchored = true
  768. w1.Parent = workspace
  769. w1.Transparency = 0.7
  770. table.insert(Effects,{w1,"Disappear",.01})
  771. w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  772. table.insert(list,w1)
  773. end
  774.  
  775. if len2 > 0.01 then
  776. local w2 = Instance.new('WedgePart', m)
  777. game:GetService("Debris"):AddItem(w2,5)
  778. w2.Material = "SmoothPlastic"
  779. w2.FormFactor = 'Custom'
  780. w2.BrickColor = TorsoColor
  781. w2.Transparency = 0
  782. w2.Reflectance = 0
  783. w2.Material = "SmoothPlastic"
  784. w2.CanCollide = false
  785. NoOutline(w2)
  786. local sz = Vector3.new(0.2, width, len2)
  787. w2.Size = sz
  788. local sp = Instance.new("SpecialMesh",w2)
  789. sp.MeshType = "Wedge"
  790. sp.Scale = Vector3.new(0,1,1) * sz/w2.Size
  791. w2:BreakJoints()
  792. w2.Anchored = true
  793. w2.Parent = workspace
  794. w2.Transparency = 0.7
  795. table.insert(Effects,{w2,"Disappear",.01})
  796. w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  797. table.insert(list,w2)
  798. end
  799. return unpack(list)
  800. end
  801.  
  802. function NoOutline(Part)
  803. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  804. end
  805.  
  806. local sine = 0
  807. local change = 1
  808. local val = 0
  809.  
  810. if #Effects>0 then
  811. --table.insert(Effects,{prt,"Block1",delay})
  812. for e=1,#Effects do
  813. if Effects[e]~=nil then
  814. --for j=1,#Effects[e] do
  815. local Thing=Effects[e]
  816. if Thing~=nil then
  817. local Part=Thing[1]
  818. local Mode=Thing[2]
  819. local Delay=Thing[3]
  820. local IncX=Thing[4]
  821. local IncY=Thing[5]
  822. local IncZ=Thing[6]
  823. if Thing[1].Transparency<=1 then
  824. if Thing[2]=="Block1" then
  825. Thing[1].CFrame=Thing[1].CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  826. Mesh=Thing[1].Mesh
  827. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  828. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  829. elseif Thing[2]=="Cylinder" then
  830. Mesh=Thing[1].Mesh
  831. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  832. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  833. elseif Thing[2]=="Blood" then
  834. Mesh=Thing[1].Mesh
  835. Thing[1].CFrame=Thing[1].CFrame*cf(0,.5,0)
  836. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  837. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  838. elseif Thing[2]=="Elec" then
  839. Mesh=Thing[1].Mesh
  840. Mesh.Scale=Mesh.Scale+vt(Thing[7],Thing[8],Thing[9])
  841. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  842. elseif Thing[2]=="Disappear" then
  843. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  844. end
  845. else
  846. Part.Parent=nil
  847. table.remove(Effects,e)
  848. end
  849. end
  850. --end
  851. end
  852. end
  853. end
  854.  
  855. cn = CFrame.new
  856. local NeckCF = cn(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  857. local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14)
  858. local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0)
  859. local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0)
  860.  
  861. local mananum=0
  862. while true do
  863. swait()
  864. sine = sine + change
  865. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  866. local velderp=RootPart.Velocity.y
  867. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  868. if equipped==true or equipped==false then
  869. if attack==false then
  870. idle=idle+1
  871. else
  872. idle=0
  873. end
  874. if idle>=500 then
  875. if attack==false then
  876. --Sheath()
  877. end
  878. end
  879. if RootPart.Velocity.y > 1 and hitfloor==nil then
  880. Anim="Jump"
  881. if attack==false then
  882. Neck.C0=clerp(Neck.C0,necko*euler(-0.2,0,0),.3)
  883. Neck.C1=clerp(Neck.C1,necko2*euler(0,0,0),.3)
  884. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.3)
  885. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(-.5,0,0.5),.3)
  886. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  887. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(-.5,0,-0.5),.3)
  888. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  889. RH.C0=clerp(RH.C0,cf(1,-1,-.3)*euler(-0.5,1.57,0)*euler(-.2,0,0),.3)
  890. LH.C0=clerp(LH.C0,cf(-1,-1,-.3)*euler(-0.5,-1.57,0)*euler(-.2,0,0),.3)
  891. end
  892. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  893. Anim="Fall"
  894. if attack==false then
  895. Neck.C0=clerp(Neck.C0,necko*euler(0.4,0,0),.3)
  896. Neck.C1=clerp(Neck.C1,necko2*euler(0,0,0),.3)
  897. RootJoint.C0=clerp(RootJoint.C0,RootCF*euler(0,0,0),.3)
  898. RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*euler(0.3,0,0.2),.3)
  899. RW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  900. LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(0.3,0,-0.2),.3)
  901. LW.C1=clerp(LW.C1,cf(0,0.5,0)*euler(0,0,0),.3)
  902. RH.C0=clerp(RH.C0,cf(1,-1,0)*euler(0.4,1.57,0),.3)
  903. LH.C0=clerp(LH.C0,cf(-1,-1,0)*euler(-0.2,-1.57,0),.3)
  904. end
  905. elseif torvel<1 and hitfloor~=nil then
  906. Anim="Idle"
  907. if attack==false then
  908. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, -0.1 + 0.1 * math.cos(sine / 25)) * angles(math.rad(0), math.rad(0), math.rad(5)), .3)
  909. Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(5 - 2 * math.cos(sine / 25)), math.rad(0), math.rad(-5)), .3)
  910. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(5 + 3 * math.cos(sine / 25))), 0.3)
  911. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-5 - 3 * math.cos(sine / 25))), 0.3)
  912. RH.C0 = clerp(RH.C0, cn(1, -.9 - 0.1 * math.cos(sine / 25), 0) * RHCF * angles(math.rad(-2 + 2 * math.cos(sine / 25)), math.rad(-5), math.rad(0 + 2 * math.cos(sine / 25))), .3)
  913. LH.C0 = clerp(LH.C0, cn(-1, -.9 - 0.1 * math.cos(sine / 25), 0) * LHCF * angles(math.rad(-2 + 2 * math.cos(sine / 25)), math.rad(-5), math.rad(0 + 2 * math.cos(sine / 25))), .3)
  914. end
  915. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  916. Anim="Walk"
  917. if attack==false then
  918. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0, -0.05 + .1 * math.cos(sine / 5)) * angles(math.rad(5), math.rad(0) + RootPart.RotVelocity.Y / 30, math.rad(5 * math.cos(sine / 10))), .2)
  919. Torso.Neck.C0 = clerp(Torso.Neck.C0, NeckCF * angles(math.rad(-3), math.rad(0), math.rad(-5 * math.cos(sine / 10)) + RootPart.RotVelocity.Y / 15), .2)
  920. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-10 * math.cos(sine / 13)), math.rad(0), math.rad(4 * math.cos(sine / 13))), .2)
  921. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(10 * math.cos(sine / 13)), math.rad(0), math.rad(4 * math.cos(sine / 13))), .2)
  922. RH.C0 = clerp(RH.C0, cn(1, -1 + .1 * math.cos(sine / 5), 0) * RHCF * angles(math.rad(-2), math.rad(0), math.rad(30 * math.cos(sine / 7))), .3)
  923. LH.C0 = clerp(LH.C0, cn(-1, -1 + .1 * math.cos(sine / 5), 0) * LHCF * angles(math.rad(-2), math.rad(0), math.rad(30 * math.cos(sine / 7))), .3)
  924. end
  925. elseif torvel>=22 and issprinting==true and hitfloor~=nil then
  926. Anim="Run"
  927. if attack==false then
  928. RootJoint.C0 = clerp(RootJoint.C0, RootCF * cn(0, 0.5, -0.05 + .1 * 2.5 * math.cos(sine / 2)) * angles(math.rad(50), math.rad(2) + RootPart.RotVelocity.Y / 30, math.rad(5 * math.cos(sine / 2))), .2)
  929. Torso.Neck.C0 = clerp(Torso.Neck.C0, cn(0, 1.1, -0.2, -1, -0, -0, 0, 0, 1, 0, 1, 0) * angles(math.rad(-50), math.rad(0), math.rad(-5 * math.cos(sine / 10)) + RootPart.RotVelocity.Y / 15), .2)
  930. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0.4) * angles(math.rad(75 * math.cos(6 / 2)), math.rad(-5), math.rad(25 * math.cos(sine / 3))), .2)
  931. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0.4) * angles(math.rad(75 * math.cos(6 / 2)), math.rad(5), math.rad(25 * math.cos(sine / 3))), .2)
  932. RH.C0 = clerp(RH.C0, cn(1, -1 + .1 * math.cos(sine / 5), 0) * RHCF * angles(math.rad(-2), math.rad(0), math.rad(55 * math.cos(sine / 3))), .3)
  933. LH.C0 = clerp(LH.C0, cn(-1, -1 + .1 * math.cos(sine / 5), 0) * LHCF * angles(math.rad(-2), math.rad(0), math.rad(55 * math.cos(sine / 3))), .3)
  934. end
  935. end
  936. end
  937. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement