Advertisement
Guest User

Untitled

a guest
Jan 19th, 2019
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 67.59 KB | None | 0 0
  1. -- This script has been converted to FE by iPxter
  2.  
  3.  
  4. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  5. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  6. do
  7. print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
  8. script.Parent = Player.Character
  9.  
  10. --RemoteEvent for communicating
  11. local Event = Instance.new("RemoteEvent")
  12. Event.Name = "UserInput_Event"
  13.  
  14. --Fake event to make stuff like Mouse.KeyDown work
  15. local function fakeEvent()
  16. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  17. t.connect = t.Connect
  18. return t
  19. end
  20.  
  21. --Creating fake input objects with fake variables
  22. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  23. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  24. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  25. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  26. end}
  27. --Merged 2 functions into one by checking amount of arguments
  28. CAS.UnbindAction = CAS.BindAction
  29.  
  30. --This function will trigger the events that have been :Connect()'ed
  31. local function te(self,ev,...)
  32. local t = m[ev]
  33. if t and t._fakeEvent and t.Function then
  34. t.Function(...)
  35. end
  36. end
  37. m.TrigEvent = te
  38. UIS.TrigEvent = te
  39.  
  40. Event.OnServerEvent:Connect(function(plr,io)
  41. if plr~=Player then return end
  42. if io.isMouse then
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. else
  46. local b = io.UserInputState == Enum.UserInputState.Begin
  47. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  48. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  49. end
  50. for _,t in pairs(CAS.Actions) do
  51. for _,k in pairs(t.Keys) do
  52. if k==io.KeyCode then
  53. t.Function(t.Name,io.UserInputState,io)
  54. end
  55. end
  56. end
  57. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  58. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  59. end
  60. end)
  61. Event.Parent = NLS([==[
  62. local Player = game:GetService("Players").LocalPlayer
  63. local Event = script:WaitForChild("UserInput_Event")
  64.  
  65. local UIS = game:GetService("UserInputService")
  66. local input = function(io,a)
  67. if a then return end
  68. --Since InputObject is a client-side instance, we create and pass table instead
  69. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  70. end
  71. UIS.InputBegan:Connect(input)
  72. UIS.InputEnded:Connect(input)
  73.  
  74. local Mouse = Player:GetMouse()
  75. local h,t
  76. --Give the server mouse data 30 times every second, but only if the values changed
  77. --If player is not moving their mouse, client won't fire events
  78. while wait(1/30) do
  79. if h~=Mouse.Hit or t~=Mouse.Target then
  80. h,t=Mouse.Hit,Mouse.Target
  81. Event:FireServer({isMouse=true,Target=t,Hit=h})
  82. end
  83. end]==],Player.Character)
  84. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  85. end
  86.  
  87.  
  88.  
  89. Player=owner
  90. Character=Player.Character
  91. PlayerGui=Player.PlayerGui
  92. Backpack=Player.Backpack
  93. Torso=Character.Torso
  94. Head=Character.Head
  95. Humanoid=Character.Humanoid
  96. m=Instance.new('Model',Character)
  97. LeftArm=Character["Left Arm"]
  98. LeftLeg=Character["Left Leg"]
  99. RightArm=Character["Right Arm"]
  100. RightLeg=Character["Right Leg"]
  101. LS=Torso["Left Shoulder"]
  102. LH=Torso["Left Hip"]
  103. RS=Torso["Right Shoulder"]
  104. RH=Torso["Right Hip"]
  105. Face = Head.face
  106. Neck=Torso.Neck
  107. it=Instance.new
  108. attacktype=1
  109. vt=Vector3.new
  110. cf=CFrame.new
  111. euler=CFrame.fromEulerAnglesXYZ
  112. angles=CFrame.Angles
  113. cloaked=false
  114. necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  115. necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
  116. LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
  117. LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
  118. RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
  119. RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
  120. RootPart=Character.HumanoidRootPart
  121. RootJoint=RootPart.RootJoint
  122. RootCF=euler(-1.57,0,3.14)
  123. attack = false
  124. attackdebounce = false
  125. deb=false
  126. equipped=true
  127. hand=false
  128. MMouse=nil
  129. combo=0
  130. mana=0
  131. trispeed=.2
  132. attackmode='none'
  133. local idle=0
  134. local Anim="Idle"
  135. local Effects={}
  136. local gun=false
  137. local shoot=false
  138. player=nil
  139. mana=0
  140. --save shoulders
  141. RSH, LSH=nil, nil
  142. --welds
  143. RW, LW=Instance.new("Weld"), Instance.new("Weld")
  144. RW.Name="Right Shoulder" LW.Name="Left Shoulder"
  145. LH=Torso["Left Hip"]
  146. RH=Torso["Right Hip"]
  147. TorsoColor=Torso.BrickColor
  148. function NoOutline(Part)
  149. Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
  150. end
  151. player=Player
  152. ch=Character
  153. RSH=ch.Torso["Right Shoulder"]
  154. LSH=ch.Torso["Left Shoulder"]
  155. --
  156. RSH.Parent=nil
  157. LSH.Parent=nil
  158. --
  159. RW.Name="Right Shoulder"
  160. RW.Part0=ch.Torso
  161. RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
  162. RW.C1=cf(0, 0.5, 0)
  163. RW.Part1=ch["Right Arm"]
  164. RW.Parent=ch.Torso
  165. --
  166. LW.Name="Left Shoulder"
  167. LW.Part0=ch.Torso
  168. LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
  169. LW.C1=cf(0, 0.5, 0)
  170. LW.Part1=ch["Left Arm"]
  171. LW.Parent=ch.Torso
  172.  
  173. Player=owner
  174. Character=Player.Character
  175. m=Instance.new('Model',Character)
  176.  
  177.  
  178. local function weldBetween(a, b)
  179. local weldd = Instance.new("ManualWeld")
  180. weldd.Part0 = a
  181. weldd.Part1 = b
  182. weldd.C0 = CFrame.new()
  183. weldd.C1 = b.CFrame:inverse() * a.CFrame
  184. weldd.Parent = a
  185. return weldd
  186. end
  187.  
  188. function swait(num)
  189. if num==0 or num==nil then
  190. game:service'RunService'.Stepped:wait(0)
  191. else
  192. for i=0,num do
  193. game:service'RunService'.Stepped:wait(0)
  194. end
  195. end
  196. end
  197.  
  198. function nooutline(part)
  199. part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
  200. end
  201.  
  202. function part(formfactor,parent,material,reflectance,transparency,brickcolor,name,size)
  203. local fp=it("Part")
  204. fp.formFactor=formfactor
  205. fp.Parent=parent
  206. fp.Reflectance=reflectance
  207. fp.Transparency=transparency
  208. fp.CanCollide=false
  209. fp.Locked=true
  210. fp.BrickColor=BrickColor.new(tostring(brickcolor))
  211. fp.Name=name
  212. fp.Size=size
  213. fp.Position=Character.Torso.Position
  214. nooutline(fp)
  215. fp.Material=material
  216. fp:BreakJoints()
  217. return fp
  218. end
  219.  
  220. function mesh(Mesh,part,meshtype,meshid,offset,scale)
  221. local mesh=it(Mesh)
  222. mesh.Parent=part
  223. if Mesh=="SpecialMesh" then
  224. mesh.MeshType=meshtype
  225. mesh.MeshId=meshid
  226. end
  227. mesh.Offset=offset
  228. mesh.Scale=scale
  229. return mesh
  230. end
  231.  
  232. function weld(parent,part0,part1,c0,c1)
  233. local weld=it("Weld")
  234. weld.Parent=parent
  235. weld.Part0=part0
  236. weld.Part1=part1
  237. weld.C0=c0
  238. weld.C1=c1
  239. return weld
  240. end
  241.  
  242.  
  243. local function CFrameFromTopBack(at, top, back)
  244. local right = top:Cross(back)
  245. return CFrame.new(at.x, at.y, at.z,
  246. right.x, top.x, back.x,
  247. right.y, top.y, back.y,
  248. right.z, top.z, back.z)
  249. end
  250.  
  251. function Triangle(a, b, c)
  252. local edg1 = (c-a):Dot((b-a).unit)
  253. local edg2 = (a-b):Dot((c-b).unit)
  254. local edg3 = (b-c):Dot((a-c).unit)
  255. if edg1 <= (b-a).magnitude and edg1 >= 0 then
  256. a, b, c = a, b, c
  257. elseif edg2 <= (c-b).magnitude and edg2 >= 0 then
  258. a, b, c = b, c, a
  259. elseif edg3 <= (a-c).magnitude and edg3 >= 0 then
  260. a, b, c = c, a, b
  261. else
  262. assert(false, "unreachable")
  263. end
  264.  
  265. local len1 = (c-a):Dot((b-a).unit)
  266. local len2 = (b-a).magnitude - len1
  267. local width = (a + (b-a).unit*len1 - c).magnitude
  268.  
  269. local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit)
  270.  
  271. local list = {}
  272.  
  273. local TrailColor = ("Dark grey")
  274.  
  275. if len1 > 0.01 then
  276. local w1 = Instance.new('WedgePart', m)
  277. game:GetService("Debris"):AddItem(w1,5)
  278. w1.Material = "SmoothPlastic"
  279. w1.FormFactor = 'Custom'
  280. w1.BrickColor = BrickColor.new(TrailColor)
  281. w1.Transparency = 0
  282. w1.Reflectance = 0
  283. w1.Material = "SmoothPlastic"
  284. w1.CanCollide = false
  285. NoOutline(w1)
  286. local sz = Vector3.new(0.2, width, len1)
  287. w1.Size = sz
  288. local sp = Instance.new("SpecialMesh",w1)
  289. sp.MeshType = "Wedge"
  290. sp.Scale = Vector3.new(0,1,1) * sz/w1.Size
  291. w1:BreakJoints()
  292. w1.Anchored = true
  293. w1.Parent = workspace
  294. w1.Transparency = 0.7
  295. table.insert(Effects,{w1,"Disappear",.01})
  296. w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2)
  297. table.insert(list,w1)
  298. end
  299.  
  300. if len2 > 0.01 then
  301. local w2 = Instance.new('WedgePart', m)
  302. game:GetService("Debris"):AddItem(w2,5)
  303. w2.Material = "SmoothPlastic"
  304. w2.FormFactor = 'Custom'
  305. w2.BrickColor = BrickColor.new(TrailColor)
  306. w2.Transparency = 0
  307. w2.Reflectance = 0
  308. w2.Material = "SmoothPlastic"
  309. w2.CanCollide = false
  310. NoOutline(w2)
  311. local sz = Vector3.new(0.2, width, len2)
  312. w2.Size = sz
  313. local sp = Instance.new("SpecialMesh",w2)
  314. sp.MeshType = "Wedge"
  315. sp.Scale = Vector3.new(0,1,1) * sz/w2.Size
  316. w2:BreakJoints()
  317. w2.Anchored = true
  318. w2.Parent = workspace
  319. w2.Transparency = 0.7
  320. table.insert(Effects,{w2,"Disappear",.01})
  321. w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2)
  322. table.insert(list,w2)
  323. end
  324. return unpack(list)
  325. end
  326.  
  327.  
  328. so = function(id,par,vol,pit)
  329. coroutine.resume(coroutine.create(function()
  330. local sou = Instance.new("Sound",par or workspace)
  331. sou.Volume=vol
  332. sou.Pitch=pit or 1
  333. sou.SoundId=id
  334. swait()
  335. sou:play()
  336. game:GetService("Debris"):AddItem(sou,6)
  337. end))
  338. end
  339.  
  340. function clerp(a,b,t)
  341. local qa = {QuaternionFromCFrame(a)}
  342. local qb = {QuaternionFromCFrame(b)}
  343. local ax, ay, az = a.x, a.y, a.z
  344. local bx, by, bz = b.x, b.y, b.z
  345. local _t = 1-t
  346. return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
  347. end
  348.  
  349. function QuaternionFromCFrame(cf)
  350. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  351. local trace = m00 + m11 + m22
  352. if trace > 0 then
  353. local s = math.sqrt(1 + trace)
  354. local recip = 0.5/s
  355. return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
  356. else
  357. local i = 0
  358. if m11 > m00 then
  359. i = 1
  360. end
  361. if m22 > (i == 0 and m00 or m11) then
  362. i = 2
  363. end
  364. if i == 0 then
  365. local s = math.sqrt(m00-m11-m22+1)
  366. local recip = 0.5/s
  367. return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
  368. elseif i == 1 then
  369. local s = math.sqrt(m11-m22-m00+1)
  370. local recip = 0.5/s
  371. return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
  372. elseif i == 2 then
  373. local s = math.sqrt(m22-m00-m11+1)
  374. local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
  375. end
  376. end
  377. end
  378.  
  379. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  380. local xs, ys, zs = x + x, y + y, z + z
  381. local wx, wy, wz = w*xs, w*ys, w*zs
  382. local xx = x*xs
  383. local xy = x*ys
  384. local xz = x*zs
  385. local yy = y*ys
  386. local yz = y*zs
  387. local zz = z*zs
  388. 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))
  389. end
  390.  
  391. function QuaternionSlerp(a, b, t)
  392. local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
  393. local startInterp, finishInterp;
  394. if cosTheta >= 0.0001 then
  395. if (1 - cosTheta) > 0.0001 then
  396. local theta = math.acos(cosTheta)
  397. local invSinTheta = 1/math.sin(theta)
  398. startInterp = math.sin((1-t)*theta)*invSinTheta
  399. finishInterp = math.sin(t*theta)*invSinTheta
  400. else
  401. startInterp = 1-t
  402. finishInterp = t
  403. end
  404. else
  405. if (1+cosTheta) > 0.0001 then
  406. local theta = math.acos(-cosTheta)
  407. local invSinTheta = 1/math.sin(theta)
  408. startInterp = math.sin((t-1)*theta)*invSinTheta
  409. finishInterp = math.sin(t*theta)*invSinTheta
  410. else
  411. startInterp = t-1
  412. finishInterp = t
  413. end
  414. end
  415. 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
  416. end
  417.  
  418. --Example: Torso.Weld.C0 = clerp(Torso.Weld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(0), math.rad(0)), 0.4)
  419.  
  420.  
  421. function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
  422. return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
  423. end
  424.  
  425. Damagefunc=function(hit,minim,maxim,knockback,Type,Property,Delay,KnockbackType,decreaseblock)
  426. if hit.Parent==nil then
  427. return
  428. end
  429. h=hit.Parent:FindFirstChild("Humanoid")
  430. for _,v in pairs(hit.Parent:children()) do
  431. if v:IsA("Humanoid") then
  432. h=v
  433. end
  434. end
  435. if hit.Parent.Parent:FindFirstChild("Torso")~=nil then
  436. h=hit.Parent.Parent:FindFirstChild("Humanoid")
  437. end
  438. if hit.Parent.className=="Hat" then
  439. hit=hit.Parent.Parent:findFirstChild("Head")
  440. end
  441. if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent:FindFirstChild("Torso")~=nil then
  442. if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
  443. --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
  444. return
  445. end]]
  446. -- hs(hit,1.2)
  447. c=Instance.new("ObjectValue")
  448. c.Name="creator"
  449. c.Value=owner
  450. c.Parent=h
  451. game:GetService("Debris"):AddItem(c,.5)
  452. Damage=math.random(minim,maxim)
  453. -- h:TakeDamage(Damage)
  454. blocked=false
  455. block=hit.Parent:findFirstChild("Block")
  456. if block~=nil then
  457. print(block.className)
  458. if block.className=="NumberValue" then
  459. if block.Value>0 then
  460. blocked=true
  461. if decreaseblock==nil then
  462. block.Value=block.Value-1
  463. end
  464. end
  465. end
  466. if block.className=="IntValue" then
  467. if block.Value>0 then
  468. blocked=true
  469. if decreaseblock~=nil then
  470. block.Value=block.Value-1
  471. end
  472. end
  473. end
  474. end
  475. if blocked==false then
  476. -- h:TakeDamage(Damage)
  477. h.Health=h.Health-Damage
  478. showDamage(hit.Parent,Damage,.5,BrickColor.new("Cyan"))
  479. else
  480. h.Health=h.Health-(Damage/2)
  481. showDamage(hit.Parent,Damage/2,.5,BrickColor.new("Bright blue"))
  482. end
  483. if Type=="Knockdown" then
  484. hum=hit.Parent.Humanoid
  485. hum.PlatformStand=true
  486. coroutine.resume(coroutine.create(function(HHumanoid)
  487. swait(1)
  488. HHumanoid.PlatformStand=false
  489. end),hum)
  490. local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
  491. --hit.CFrame=CFrame.new(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
  492. local bodvol=Instance.new("BodyVelocity")
  493. bodvol.velocity=angle*knockback
  494. bodvol.P=5000
  495. bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  496. bodvol.Parent=hit
  497. rl=Instance.new("BodyAngularVelocity")
  498. rl.P=3000
  499. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  500. rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
  501. rl.Parent=hit
  502. game:GetService("Debris"):AddItem(bodvol,.5)
  503. game:GetService("Debris"):AddItem(rl,.5)
  504. elseif Type=="Normal" then
  505. vp=Instance.new("BodyVelocity")
  506. vp.P=500
  507. vp.maxForce=Vector3.new(math.huge,0,math.huge)
  508. -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
  509. if KnockbackType==1 then
  510. vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
  511. elseif KnockbackType==2 then
  512. vp.velocity=Property.CFrame.lookVector*knockback
  513. end
  514. if knockback>0 then
  515. vp.Parent=hit.Parent.Torso
  516. end
  517. game:GetService("Debris"):AddItem(vp,.5)
  518. elseif Type=="Up" then
  519. local bodyVelocity=Instance.new("BodyVelocity")
  520. bodyVelocity.velocity=vt(0,60,0)
  521. bodyVelocity.P=5000
  522. bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
  523. bodyVelocity.Parent=hit
  524. game:GetService("Debris"):AddItem(bodyVelocity,1)
  525. rl=Instance.new("BodyAngularVelocity")
  526. rl.P=3000
  527. rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
  528. rl.angularvelocity=Vector3.new(math.random(-30,30),math.random(-30,30),math.random(-30,30))
  529. rl.Parent=hit
  530. game:GetService("Debris"):AddItem(rl,.5)
  531. elseif Type=="Snare" then
  532. bp=Instance.new("BodyPosition")
  533. bp.P=2000
  534. bp.D=100
  535. bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  536. bp.position=hit.Parent.Torso.Position
  537. bp.Parent=hit.Parent.Torso
  538. game:GetService("Debris"):AddItem(bp,1)
  539. elseif Type=="Target" then
  540. if Targetting==false then
  541. ZTarget=hit.Parent.Torso
  542. coroutine.resume(coroutine.create(function(Part)
  543. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  544. swait(5)
  545. so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
  546. end),ZTarget)
  547. TargHum=ZTarget.Parent:findFirstChild("Humanoid")
  548. targetgui=Instance.new("BillboardGui")
  549. targetgui.Parent=ZTarget
  550. targetgui.Size=UDim2.new(10,100,10,100)
  551. targ=Instance.new("ImageLabel")
  552. targ.Parent=targetgui
  553. targ.BackgroundTransparency=1
  554. targ.Image="rbxassetid://4834067"
  555. targ.Size=UDim2.new(1,0,1,0)
  556. cam.CameraType="Scriptable"
  557. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  558. dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  559. workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  560. Targetting=true
  561. RocketTarget=ZTarget
  562. for i=1,Property do
  563. --while Targetting==true and Humanoid.Health>0 and Character.Parent~=nil do
  564. if Humanoid.Health>0 and Character.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then
  565. swait()
  566. end
  567. --workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,Head.CFrame.p+rmdir*100)
  568. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
  569. dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
  570. cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0)
  571. end
  572. Targetting=false
  573. RocketTarget=nil
  574. targetgui.Parent=nil
  575. cam.CameraType="Custom"
  576. end
  577. end
  578. debounce=Instance.new("BoolValue")
  579. debounce.Name="DebounceHit"
  580. debounce.Parent=hit.Parent
  581. debounce.Value=true
  582. game:GetService("Debris"):AddItem(debounce,Delay)
  583. c=Instance.new("ObjectValue")
  584. c.Name="creator"
  585. c.Value=Player
  586. c.Parent=h
  587. game:GetService("Debris"):AddItem(c,.5)
  588. CRIT=false
  589. hitDeb=true
  590. AttackPos=6
  591. end
  592. end
  593.  
  594. showDamage=function(Char,Dealt,du,Color)
  595. m=Instance.new("Model")
  596. m.Name=tostring(Dealt)
  597. h=Instance.new("Humanoid")
  598. h.Health=0
  599. h.MaxHealth=0
  600. h.Parent=m
  601. c=Instance.new("Part")
  602. c.Transparency=0
  603. c.BrickColor=Color
  604. c.Name="Head"
  605. c.TopSurface=0
  606. c.BottomSurface=0
  607. c.formFactor="Plate"
  608. c.Size=Vector3.new(1,.4,1)
  609. ms=Instance.new("CylinderMesh")
  610. ms.Scale=Vector3.new(.8,.8,.8)
  611. if CRIT==true then
  612. ms.Scale=Vector3.new(1,1.25,1)
  613. end
  614. ms.Parent=c
  615. c.Reflectance=0
  616. Instance.new("BodyGyro").Parent=c
  617. c.Parent=m
  618. if Char:findFirstChild("Head")~=nil then
  619. c.CFrame=CFrame.new(Char["Head"].CFrame.p+Vector3.new(0,1.5,0))
  620. elseif Char.Parent:findFirstChild("Head")~=nil then
  621. c.CFrame=CFrame.new(Char.Parent["Head"].CFrame.p+Vector3.new(0,1.5,0))
  622. end
  623. f=Instance.new("BodyPosition")
  624. f.P=2000
  625. f.D=100
  626. f.maxForce=Vector3.new(math.huge,math.huge,math.huge)
  627. f.position=c.Position+Vector3.new(0,3,0)
  628. f.Parent=c
  629. game:GetService("Debris"):AddItem(m,.5+du)
  630. c.CanCollide=false
  631. m.Parent=workspace
  632. c.CanCollide=false
  633. end
  634.  
  635. handle=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Handle",Vector3.new(0.200000003, 0.200000003, 0.510347784))
  636. handleweld=weld(m,Character["Right Arm"],handle,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0134277344, -1.08377826, 0.236021042, -0.999991059, 1.64970497e-005, -3.57626704e-005, -1.64969497e-005, -0.999997199, -5.89981786e-010, -3.53156356e-005, -1.55431202e-015, 0.999991059))
  637. mesh("BlockMesh",handle,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 1))
  638. Barrel=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,1,"Really black","Barrel",Vector3.new(0.400000036, 0.600000024, 0.400000006))
  639. Barrelweld=weld(m,handle,Barrel,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0165214539, -0.556964874, 1.65633035, -0.999990225, -1.64588746e-005, -3.51069939e-005, 3.59414771e-005, 5.92924765e-010, -0.99999088, 1.65416641e-005, -0.999996066, -2.07900868e-007))
  640. mesh("BlockMesh",Barrel,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  641. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  642. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-8.77380371e-005, -0.551608682, 0.933853149, 0.999982119, 4.92241179e-006, 4.47023922e-007, -4.92275558e-006, 0.999994397, 5.18727006e-011, -1.34108632e-006, -6.88231694e-011, 0.999982119))
  643. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 0.850579739))
  644. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.263679713, 0.680464089, 0.200000003))
  645. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.000255584717, 1.23079586, 0.679197311, 0.999982119, 2.09204348e-010, 4.47023922e-007, -6.14797824e-010, 0.999994397, 7.37476746e-012, -1.34108632e-006, -2.21242469e-011, 0.999982119))
  646. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 0.850579739))
  647. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.200000003, 0.255169868))
  648. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-6.86645508e-005, -0.424460649, 0.127323151, 0.999991059, 2.60244997e-006, 5.95537131e-008, -2.60263118e-006, 0.999997079, 2.07900612e-007, -5.06588549e-007, -2.07909366e-007, 0.999991059))
  649. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425283134, 0.425283283, 1))
  650. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(2.04139137, 0.340232015, 0.255173892))
  651. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.466564178, -0.424417496, -0.00016784668, -2.27435266e-005, -0.999994159, 1.75410797e-011, 7.063058e-005, -1.58892144e-009, -0.999982119, 0.999982119, -2.27441906e-005, 6.97365176e-005))
  652. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  653. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.200000003, 0.255169958))
  654. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-5.7220459e-005, -0.0845518112, 0.127305984, 0.999982119, 1.79009203e-006, 4.76829882e-007, -1.79047493e-006, 0.999994397, 7.47768514e-012, -1.37088864e-006, -2.3080815e-011, 0.999982119))
  655. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.425290078, 1))
  656. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.425283313, 0.200000003))
  657. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.14440918e-005, -0.254490614, -0.0425262451, 0.999982119, 4.47815211e-007, 5.0665767e-007, -4.48213513e-007, 0.999994397, 9.08723097e-012, -1.40071279e-006, -2.40636955e-011, 0.999982119))
  658. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425283134, 1, 0.425283164))
  659. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.255173951, 1.44598627, 0.595405817))
  660. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.000183105469, 1.35827327, 0.551862717, 0.999982119, 2.09204348e-010, 4.47023922e-007, -6.14797824e-010, 0.999994397, 7.37476746e-012, -1.34108632e-006, -2.21242469e-011, 0.999982119))
  661. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(1.61610174, 0.255173981, 0.255173892))
  662. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.254119873, -0.721702576, -0.000198364258, -2.27435994e-005, -0.999994636, -3.5085157e-011, 7.10776076e-005, -1.54646851e-009, -0.999982119, 0.999982119, -2.27442943e-005, 7.01835525e-005))
  663. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  664. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Light stone grey","Part",Vector3.new(0.263679713, 0.200000003, 0.425289869))
  665. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00115585327, -0.551612258, 0.636695862, 0.999982119, 4.92261825e-006, 8.94047844e-007, -4.92297022e-006, 0.999994636, 6.63678834e-011, -1.78811024e-006, -8.55193139e-011, 0.999982119))
  666. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.850580096, 1))
  667. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.680463791, 0.200000003, 0.200000003))
  668. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.976444304, -0.294725418, -0.00431060791, -2.27435994e-005, -0.999994636, -3.5085157e-011, 7.10776076e-005, -1.54646851e-009, -0.999982119, 0.999982119, -2.27442943e-005, 7.01835525e-005))
  669. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.425290078, 0.850579798))
  670. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"White","Part",Vector3.new(0.42528984, 0.200000003, 0.255173892))
  671. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.27387559, -0.636722565, -0.00016784668, -2.49764744e-005, -0.999994636, -3.70836695e-011, 7.10776076e-005, -1.7011863e-009, -0.999982119, 0.999982119, -2.49771983e-005, 7.01835525e-005))
  672. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.425290078, 1))
  673. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"White","Part",Vector3.new(0.200000003, 0.200000003, 0.255173892))
  674. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.10395718, -0.764104843, -0.000137329102, -2.49764744e-005, -0.999994636, -3.70836695e-011, 7.10776076e-005, -1.7011863e-009, -0.999982119, 0.999982119, -2.49771983e-005, 7.01835525e-005))
  675. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 1))
  676. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.425289929, 0.340231895))
  677. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0043182373, 1.2733295, 0.0848426819, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  678. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 1))
  679. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Light stone grey","Part",Vector3.new(0.200000003, 0.200000003, 0.340231895))
  680. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00423049927, 1.01876116, 0.0848426819, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  681. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 1))
  682. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.255173951, 0.200000003, 0.255173892))
  683. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.81469727e-006, 0.0424911976, 0.97628212, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  684. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.850580096, 1))
  685. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Cyan","Part",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  686. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-6.48498535e-005, 0.084962368, 1.18850517, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  687. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.212644935, 0.212645039, 0.425289869))
  688. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0.5,"Cyan","Part",Vector3.new(0.255173951, 0.200000003, 0.200000003))
  689. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-6.48498535e-005, 0.084962368, 1.18850517, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  690. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.425290078, 0.850579798))
  691. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.680464029, 0.200000003))
  692. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00429153442, -0.976130962, 0.297080994, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  693. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 0.425289869))
  694. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.255173951, 0.200000003, 0.595405877))
  695. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-6.10351563e-005, 0.594237328, 0.551851273, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  696. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.425290078, 1))
  697. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.200000003, 0.425289869))
  698. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.169742584, 0.0849318504, 1.06118011, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  699. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.425290078, 1))
  700. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Light stone grey","Part",Vector3.new(0.200000003, 0.510348022, 0.200000003))
  701. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00430297852, 1.23086357, -0.127353668, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  702. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 0.425289869))
  703. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.255173951, 0.200000003, 0.850579739))
  704. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-5.34057617e-005, 2.1647141, 0.424444199, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  705. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.850580096, 1))
  706. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.255173951, 0.595406055, 0.200000003))
  707. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-4.57763672e-005, -0.339458823, 1.0612278, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  708. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 1, 0.425289869))
  709. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.425289899, 0.200000003, 0.200000003))
  710. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-9.91821289e-005, 0.084962368, 1.3158741, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  711. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.425290078, 0.425289869))
  712. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.200000003, 0.510347903))
  713. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0848655701, 0.551791668, -5.91278076e-005, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  714. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 1))
  715. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Part",Vector3.new(0.200000003, 0.200000003, 0.425289869))
  716. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.169647217, 0.0849175453, 1.06118774, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  717. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.425290078, 1))
  718. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.425290108, 0.200000003))
  719. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0.254673719, -0.212312698, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  720. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 0.425289869))
  721. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Light stone grey","Part",Vector3.new(0.200000003, 0.200000003, 0.425289869))
  722. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.00430297852, 1.52808881, 0.0424671173, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  723. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 1))
  724. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  725. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.21206665, -0.933796644, 0.679149628, -0.999982119, -5.58144457e-005, -8.9405512e-007, 5.58141619e-005, -0.999994636, 3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  726. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 0.850579798))
  727. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  728. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.127262115, 0.933843374, 0.679164886, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  729. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 0.850579739))
  730. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.255173951, 0.200000003, 0.340231895))
  731. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.14440918e-005, -2.1647017, -2.0980835e-005, -0.999982119, -5.58144457e-005, -8.9405512e-007, 5.58141619e-005, -0.999994636, 3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  732. mesh("CylinderMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(1, 0.850580096, 1))
  733. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Part",Vector3.new(0.200000003, 0.200000003, 0.510347903))
  734. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0848960876, 0.551814079, -1.90734863e-005, 0.999982119, 5.58144457e-005, 8.9405512e-007, -5.58141619e-005, 0.999994636, -3.51525475e-011, -1.78811752e-006, -2.94989588e-011, 0.999982119))
  735. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 1))
  736. Part=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"White","Part",Vector3.new(0.200000003, 0.200000003, 0.255173892))
  737. Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.44389164, -0.764112473, -0.000137329102, -2.53405306e-005, -0.999997318, -2.07920962e-007, 7.14656417e-005, 2.06129954e-007, -0.999991059, 0.999991059, -2.53409107e-005, 7.10185996e-005))
  738. mesh("BlockMesh",Part,"","",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 1))
  739. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  740. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.551600099, -0.891397476, 0.0849647522, -1.96261317e-005, -0.999994636, -7.89959209e-011, 7.10781751e-005, -1.28376709e-009, -0.999982119, 0.999982119, -1.96267902e-005, 7.018412e-005))
  741. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 0.425289869))
  742. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.255173862, 0.255174011, 0.595405817))
  743. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.000217437744, -1.61367238, -0.551843643, -0.999982119, -3.15852139e-006, -8.79772415e-007, -3.15889542e-006, 0.999994636, -2.42164191e-007, 1.77383481e-006, -2.42149667e-007, -0.999982119))
  744. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  745. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.34022662, 0.200000003))
  746. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(5.7220459e-005, 0.0848674774, 0.509426713, 0.999991059, 2.60264824e-006, 5.06588549e-007, -9.53623385e-007, 2.06911025e-007, 0.999991059, 2.60283809e-006, -0.999997318, 2.06918429e-007))
  747. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425283134, 1, 0.425283164))
  748. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  749. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.551610351, -0.891412735, 0.0848731995, 2.05404231e-005, 0.999994636, 3.72684752e-007, 7.10960012e-005, 3.71262161e-007, -0.999982119, -0.999982119, 2.05411197e-005, -7.02019315e-005))
  750. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 0.425289869))
  751. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  752. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.551705599, 0.933855057, 0.0848388672, -2.27403962e-005, -0.999994636, -5.9601156e-008, -7.10774912e-005, -5.80205715e-008, 0.999982119, -0.999982119, 2.27410965e-005, -7.0183436e-005))
  753. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.850580096, 0.425289869))
  754. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  755. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.551692009, 0.933879852, 0.0849609375, 2.27179899e-005, 0.999994636, -5.9531132e-008, -7.10859167e-005, 6.11118125e-008, 0.999982119, 0.999982119, -2.27186792e-005, 7.0191847e-005))
  756. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.850580096, 0.425289869))
  757. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.255168587, 0.200000003))
  758. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.000110626221, 0.127298355, 0.169516325, 0.999982119, 2.23781717e-006, 9.2386108e-007, -1.81791984e-006, -1.01918163e-009, 0.999982119, 2.2382028e-006, -0.999994636, -1.0023522e-009))
  759. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 1, 0.425289869))
  760. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"White","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  761. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.00854873657, -1.57516098, 0.185529709, -0.999982119, -7.21350352e-006, -8.5031279e-006, -3.48015419e-006, 0.937103271, -0.349032491, 1.13240894e-005, -0.349036932, -0.937091589))
  762. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 0.425290078, 0.425289869))
  763. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.200000003, 0.425284624, 0.200000003))
  764. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.000102996826, -0.0424919128, 0.0849627256, 0.999991059, 5.58147876e-005, 8.0466998e-007, 1.25170482e-006, -2.72474687e-009, -0.999991059, -5.58146457e-005, 0.999997318, -2.77701706e-009))
  765. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 0.425289869))
  766. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"White","Wedge",Vector3.new(0.200000003, 0.255174011, 0.255173892))
  767. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.00849533081, -1.76611137, 0.0303249359, -0.999982119, -7.41118401e-006, -9.01437488e-006, -3.18791808e-006, 0.928048849, -0.372439235, 1.19559481e-005, -0.372443885, -0.928037345))
  768. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 1))
  769. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.200000003, 0.425284624, 0.200000003))
  770. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.000106811523, 0.0424900055, 0.0849499702, -0.999982119, -4.47962549e-007, -6.40648068e-007, -1.53471046e-006, -1.13678156e-009, 0.999982119, -4.48370002e-007, 0.999994636, 1.12173104e-009))
  771. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.850579858, 1, 0.425289869))
  772. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.255168587, 0.200000003))
  773. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.000118255615, -0.12729454, 0.169492006, -0.999982119, -5.62619716e-005, -9.83487553e-007, 1.87754631e-006, -2.7208622e-009, -0.999982119, 5.62616806e-005, -0.999994636, 2.79091061e-009))
  774. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 1, 0.425289869))
  775. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  776. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0847396851, 0.933885574, 0.0847232342, 0.999982119, 5.58591455e-005, 8.98660801e-007, -1.7927232e-006, -2.00105266e-008, 0.999982119, 5.58588581e-005, -0.999994636, -1.99453289e-008))
  777. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 0.425289869))
  778. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.200000003, 0.2551741, 0.200000003))
  779. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0849990845, 0.339661598, -0.212226868, -0.999982119, -5.5915436e-005, -7.77094101e-007, -5.59151522e-005, 0.999994636, 1.02350157e-006, 1.67109829e-006, 1.02357262e-006, -0.999982119))
  780. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 1, 0.425289869))
  781. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  782. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0849323273, 0.806465149, 0.169761658, 2.44998719e-005, 0.999994636, 1.26530392e-006, -7.12289184e-005, -1.2636109e-006, 0.999982119, 0.999982119, -2.45006886e-005, 7.03348342e-005))
  783. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.425290078, 0.425289869))
  784. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.255173951, 0.425290108, 0.255173951))
  785. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(3.81469727e-006, 1.86757088, -0.127286911, -0.999982119, -5.5915436e-005, -7.77094101e-007, -5.59151522e-005, 0.999994636, 1.02350157e-006, 1.67109829e-006, 1.02357262e-006, -0.999982119))
  786. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  787. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.200000003, 0.2551741, 0.200000003))
  788. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0.0848350525, 0.339640617, -0.212226868, -0.999982119, -5.5915436e-005, -7.77094101e-007, -5.59151522e-005, 0.999994636, 1.02350157e-006, 1.67109829e-006, 1.02357262e-006, -0.999982119))
  789. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 1, 0.425289869))
  790. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Really black","Wedge",Vector3.new(0.255173951, 0.340232044, 0.510347784))
  791. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-3.05175781e-005, -0.8064816, 1.14440918e-005, 0.999982119, 5.58740467e-005, 1.35518712e-006, 5.58737629e-005, -0.999994636, -1.12400812e-006, 2.2491804e-006, 1.12411249e-006, -0.999982119))
  792. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(1, 1, 1))
  793. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  794. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0848121643, 0.933847427, 0.0847399235, 0.999982119, 5.58591455e-005, 8.98660801e-007, -1.7927232e-006, -2.00105266e-008, 0.999982119, 5.58588581e-005, -0.999994636, -1.99453289e-008))
  795. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.850580096, 0.425289869))
  796. Wedge=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,0,"Mid gray","Wedge",Vector3.new(0.200000003, 0.200000003, 0.200000003))
  797. Wedgeweld=weld(m,handle,Wedge,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-0.0849186182, 0.806528091, 0.169620514, -2.46491363e-005, -0.999994636, -5.97645396e-007, -7.32047774e-005, -5.95885183e-007, 0.999982119, -0.999982119, 2.46499039e-005, -7.23107005e-005))
  798. mesh("SpecialMesh",Wedge,Enum.MeshType.Wedge,"",Vector3.new(0, 0, 0),Vector3.new(0.425289869, 0.425290078, 0.425289869))
  799.  
  800. function effect(Color,Ref,LP,P1,returnn)
  801. if LP==nil or P1==nil then return end
  802. local effectsmsh=Instance.new("CylinderMesh")
  803. effectsmsh.Scale=Vector3.new(0.2,1,0.2)
  804. effectsmsh.Name="Mesh"
  805. local effectsg=Instance.new("Part")
  806. NoOutline(effectsg)
  807. effectsg.formFactor=3
  808. effectsg.CanCollide=false
  809. effectsg.Name="Eff"
  810. effectsg.Locked=true
  811. effectsg.Anchored=true
  812. effectsg.Size=Vector3.new(0.5,1,0.5)
  813. effectsg.Parent=workspace
  814. effectsmsh.Parent=effectsg
  815. effectsg.BrickColor=BrickColor.new(Color)
  816. effectsg.Reflectance=Ref
  817. local point1=P1
  818. local mg=(LP.p - point1.p).magnitude
  819. effectsg.Size=Vector3.new(0.5,mg,0.5)
  820. effectsg.CFrame=cf((LP.p+point1.p)/2,point1.p) * CFrame.Angles(math.rad(90),0,0)
  821. effectsmsh.Scale=Vector3.new(0.2,1,0.2)
  822. game:GetService("Debris"):AddItem(effectsg,2)
  823. if returnn then return effectsg end
  824. if not returnn then
  825. table.insert(Effects,{effectsg,"Cylinder",0.2,0.01,0,0.01,effectsmsh})
  826. end
  827. end
  828.  
  829. function MagicCircle(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  830. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  831. prt.Anchored=true
  832. prt.CFrame=cframe
  833. local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
  834. game:GetService("Debris"):AddItem(prt,2)
  835. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  836. end
  837.  
  838. function MagicCylinder(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  839. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  840. prt.Anchored=true
  841. prt.CFrame=cframe
  842. local msh=mesh("CylinderMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
  843. game:GetService("Debris"):AddItem(prt,2)
  844. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  845. end
  846.  
  847. function MagicHead(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  848. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  849. prt.Anchored=true
  850. prt.CFrame=cframe
  851. local msh=mesh("SpecialMesh",prt,"Head","",vt(0,0,0),vt(x1,y1,z1))
  852. game:GetService("Debris"):AddItem(prt,2)
  853. table.insert(Effects,{prt,"Cylinder",delay,x3,y3,z3,msh})
  854. end
  855.  
  856.  
  857. function MagicCylinder(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay)
  858. local prt=part(3,workspace,"SmoothPlastic",0,0,brickcolor,"Effect",vt())
  859. prt.Anchored=true
  860. prt.CFrame=cframe
  861. msh=mesh("SpecialMesh",prt,"Head","",vt(0,0,0),vt(x1,y1,z1))
  862. game:GetService("Debris"):AddItem(prt,2)
  863. coroutine.resume(coroutine.create(function(Part,Mesh)
  864. for i=0,1,delay do
  865. swait()
  866. Part.CFrame=Part.CFrame
  867. Part.Transparency=i
  868. Mesh.Scale=Mesh.Scale+vt(x3,y3,z3)
  869. end
  870. Part.Parent=nil
  871. end),prt,msh)
  872. end
  873.  
  874. function LaserBarrage(Prt,Parent)
  875. attack=true
  876. --so("BeamLockon",Prt,1,1)
  877. local efprt=part(3,Parent,"SmoothPlastic",0,0.5,BrickColor.new("Cyan"),"Effect",vt(0.2,0.2,0.2))
  878. efprt.Anchored=true
  879. local efmsh=mesh("CylinderMesh",efprt,"","",vt(0,0,0),vt(1,1,1))
  880. spread=vt(0,0,0)*(Prt.Position-Mouse.Hit.p).magnitude/100
  881. --spread=vt(0,0,0)
  882. coroutine.resume(coroutine.create(function(Part,Mesh,Spreaded)
  883. game:GetService("Debris"):AddItem(Part,6)
  884. local TheHit=Mouse.Hit.p
  885. local MouseLook=cf((Prt.Position+TheHit)/2,TheHit+Spreaded)
  886. local hit,pos = rayCast(Prt.Position,MouseLook.lookVector,1000,Parent)
  887. so("Elec",Prt,0.2,1)
  888. local tefprt=part(3,workspace,"SmoothPlastic",0,1,BrickColor.new("Black"),"Effect",vt(0.2,0.2,0.2))
  889. tefprt.CFrame=cf(pos)
  890. MagicCircle(BrickColor.new("Cyan"),cf(pos),0.5,0.5,0.5,0.5,0.5,0.5,0.04)
  891. so("Elec",tefprt,0.3,1)
  892. game:GetService("Debris"):AddItem(tefprt,3)
  893. Part.CFrame=CFrame.new((Prt.Position+pos)/2,pos)*angles(1.57,0,0)
  894. if(hit.Parent:findFirstChild("Humanoid")~= nil)then
  895. if hit.Parent:FindFirstChild("Humanoid") ~= nil and hit.Name ~= "Base" and hit.Parent.Name ~= Player.Name then
  896. hit.Parent.Humanoid:TakeDamage(15)
  897. end
  898. end
  899. local mag=(Prt.Position-pos).magnitude
  900. MagicCylinder(BrickColor.new("Cyan"),Part.CFrame,1,mag*5,1,0.5,0,0.5,0.05)
  901. Part.Parent=nil
  902. end),efprt,efmsh,spread)
  903. end
  904.  
  905. function Laser(Part,Dmg)
  906. sp = Part.Position
  907. dirr = Part.CFrame * CFrame.fromEulerAnglesXYZ(0,0,0)
  908. local hit,pos = rayCast(sp,dirr.lookVector,100,Character)
  909. local las=Instance.new("Part",Character)
  910. las.Material = "SmoothPlastic"
  911. las.Anchored=true
  912. las.Locked=true
  913. las.CanCollide=false
  914. las.TopSurface=0
  915. las.BottomSurface=0
  916. las.FormFactor = "Custom"
  917. las.BrickColor=BrickColor.new("Cyan")
  918. las.Size=Vector3.new(1,1,1)
  919. las.CFrame=CFrame.new((Part.Position+pos)/2,pos) *CFrame.Angles(math.rad(90),0,0)
  920. local msh=Instance.new("SpecialMesh",las)
  921. mag = (Part.Position-pos).magnitude
  922. msh.Scale=Vector3.new(0.1,mag,0.1)
  923. coroutine.resume(coroutine.create(function(Part,Mesh)
  924. for i = 0,1,0.1 do
  925. wait()
  926. Part.Transparency = Part.Transparency + 0.1
  927. Mesh.Scale = Mesh.Scale + Vector3.new(0.15,0.7,0.15)
  928. end
  929. Part.Parent = nil
  930. end),las,msh)
  931. if pos ~= nil then
  932. local las2=Instance.new("Part",Character)
  933. las2.Material = "SmoothPlastic"
  934. las2.Anchored=true
  935. las2.Locked=true
  936. las2.CanCollide=false
  937. las2.TopSurface=0
  938. las2.BottomSurface=0
  939. las2.FormFactor = "Custom"
  940. las2.BrickColor=BrickColor.new("Cyan")
  941. las2.Size=Vector3.new(1,1,1)
  942. --las2.CFrame=CFrame.new((Part.Position+pos)/2,pos) *CFrame.Angles(math.rad(90),0,0)
  943. las2.CFrame=CFrame.new(pos) *CFrame.Angles(math.rad(90),0,0)
  944. local msh=Instance.new("SpecialMesh",las2)
  945. msh.MeshType = "Sphere"
  946. mag = (Part.Position-pos).magnitude
  947. msh.Scale=Vector3.new(0.1,0.1,0.1)
  948. coroutine.resume(coroutine.create(function(Part,Mesh)
  949. --wait(10)
  950. for i = 0,1,0.1 do
  951. wait()
  952. Part.Transparency = Part.Transparency + 0.1
  953. Mesh.Scale = Mesh.Scale + Vector3.new(0.5,0,0.5)
  954. end
  955. Part.Parent = nil
  956. end),las2,msh)
  957. end
  958. if hit ~= nil and pos ~= nil then
  959. if hit.Parent.className == "Hat" then
  960. hit:BreakJoints()
  961. hit.Velocity = Vector3.new(math.random(-5,5),20,math.random(-5,5))
  962. end
  963. if(hit.Parent:findFirstChild("Humanoid")~= nil)then
  964. if hit.Parent:FindFirstChild("Humanoid") ~= nil and hit.Name ~= "Base" and hit.Parent.Name ~= Player.Name then
  965. hit.Parent.Humanoid:TakeDamage(Dmg)
  966. end
  967. end
  968. --[[if hit.className == "Part" and hit.Parent:findFirstChild("Humanoid") == nil then
  969. end ]]
  970. end
  971. end
  972.  
  973. ShootSounds = {233370753,233370772}
  974.  
  975. function PlaySound(id, pitch, parent, volume)
  976. if volume == nil then volume=tonumber(1) end
  977. local Sound = Instance.new("Sound")
  978. Sound.Name = "Epicosound"
  979. Sound.SoundId = "rbxassetid://"..id
  980. Sound.Volume = volume
  981. Sound.Pitch = pitch
  982. Sound.Looped = false
  983. Sound.Parent = parent
  984. wait()
  985. Sound:Play()
  986. game:service'Debris':AddItem(Sound, 8)
  987. end
  988.  
  989. ShootSounds = {233370753,233370772}
  990.  
  991. ShootSound = function(part)
  992. local shot=math.random(1, #ShootSounds)
  993. PlaySound(ShootSounds[shot], 1, part)
  994. end
  995.  
  996. function Shoot1()
  997. attack = true
  998. for i = 0,1,0.2 do
  999. swait()
  1000. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-30)),.3)
  1001. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(30)),.3)
  1002. RW.C0 = clerp(RW.C0, CFrame.new(1, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(-30)),.3)
  1003. LW.C0 = clerp(LW.C0, CFrame.new(-0.7, 0.5, -1) * angles(math.rad(0), math.rad(80), math.rad(100)),.3)
  1004. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),.3)
  1005. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(-5)),.3)
  1006. end
  1007. ShootSound(Barrel)
  1008. LaserBarrage(Barrel,m)
  1009. MagicCircle(BrickColor.new("Cyan"),Barrel.CFrame,.5,.5,.5,.5,.5,.5,0.06)
  1010. for i = 0,1,0.1 do
  1011. swait()
  1012. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(-5),math.rad(0),math.rad(-30)),.2)
  1013. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-5),math.rad(0),math.rad(30)),.2)
  1014. RW.C0 = clerp(RW.C0, CFrame.new(1, 0.5, 0) * angles(math.rad(120), math.rad(0), math.rad(-20)),.3)
  1015. LW.C0 = clerp(LW.C0, CFrame.new(-0.7, 0.5, -1) * angles(math.rad(0), math.rad(50), math.rad(130)),.3)
  1016. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-10)),.2)
  1017. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(5)),.2)
  1018. end
  1019. attack = false
  1020. end
  1021.  
  1022. function Shoot2()
  1023. attack = true
  1024. for i = 0,1,0.07 do
  1025. swait()
  1026. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(90)),.2)
  1027. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-80)),.2)
  1028. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(90)),.2)
  1029. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)),.2)
  1030. RH.C0=clerp(RH.C0,cf(.6,-1,.5)*angles(math.rad(0),math.rad(20),math.rad(0)),.2)
  1031. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(-5)),.2)
  1032. end
  1033. ShootSound(Barrel)
  1034. LaserBarrage(Barrel,m)
  1035. MagicCircle(BrickColor.new("Cyan"),Barrel.CFrame,.5,.5,.5,.5,.5,.5,0.06)
  1036. for i = 0,1,0.1 do
  1037. swait()
  1038. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(90)),.2)
  1039. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(-80)),.2)
  1040. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 1, 0) * angles(math.rad(0), math.rad(50), math.rad(140)),.2)
  1041. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)),.2)
  1042. RH.C0=clerp(RH.C0,cf(.6,-1,.5)*angles(math.rad(0),math.rad(20),math.rad(0)),.2)
  1043. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(-5)),.2)
  1044. end
  1045. attack = false
  1046. end
  1047.  
  1048. function Shoot3()
  1049. attack = true
  1050. for i = 0,1,0.07 do
  1051. swait()
  1052. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,2)* angles(math.rad(30),math.rad(0),-5*i),.2)
  1053. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-30)),.2)
  1054. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(90)),.2)
  1055. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-80)),.2)
  1056. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(60)),.2)
  1057. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(70)),.2)
  1058. end
  1059. for i = 0,1,0.1 do
  1060. swait()
  1061. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(90)),.2)
  1062. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-80)),.2)
  1063. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(90)),.2)
  1064. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)),.2)
  1065. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(30)),.2)
  1066. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-80),math.rad(30)),.2)
  1067. end
  1068. ShootSound(Barrel)
  1069. LaserBarrage(Barrel,m)
  1070. MagicCircle(BrickColor.new("Cyan"),Barrel.CFrame,.5,.5,.5,.5,.5,.5,0.06)
  1071. for i = 0,1,0.1 do
  1072. swait()
  1073. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(90)),.2)
  1074. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-80)),.2)
  1075. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(50), math.rad(90)),.2)
  1076. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-50)),.2)
  1077. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(20)),.2)
  1078. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-80),math.rad(20)),.2)
  1079. end
  1080. attack = false
  1081. end
  1082.  
  1083. function SpinShot()
  1084. attack = true
  1085. for i=0,1,0.9 do
  1086. swait()
  1087. for i = 0,1,0.1 do
  1088. swait()
  1089. ShootSound(Barrel)
  1090. Laser(Barrel,20)
  1091. MagicCircle(BrickColor.new("Cyan"),Barrel.CFrame,.5,.5,.5,.5,.5,.5,0.06)
  1092. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,2)* angles(math.rad(20),math.rad(0),-5*i),.3)
  1093. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(-30)),.3)
  1094. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(90)),.3)
  1095. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(-80)),.3)
  1096. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(60)),.3)
  1097. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(70)),.3)
  1098. end
  1099. end
  1100. attack = false
  1101. end
  1102.  
  1103. mouse.Button1Down:connect(function()
  1104. if attack==false then
  1105. if attacktype == 1 then
  1106. attack = true
  1107. attacktype = 2
  1108. Shoot1()
  1109. elseif attacktype == 2 then
  1110. attack = true
  1111. attacktype = 3
  1112. Shoot2()
  1113. elseif attacktype == 3 then
  1114. attack = true
  1115. attacktype = 1
  1116. Shoot3()
  1117. end
  1118. end
  1119. end)
  1120.  
  1121. mouse.KeyDown:connect(function(k)
  1122. k=k:lower()
  1123. if k=='q' then
  1124. if attack==false then
  1125. SpinShot()
  1126. end
  1127. end
  1128. end)
  1129.  
  1130.  
  1131. local sine = 0
  1132. local change = 1
  1133. local val = 0
  1134.  
  1135. while true do
  1136. swait()
  1137. sine = sine + change
  1138. local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
  1139. local velderp=RootPart.Velocity.y
  1140. hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
  1141. if equipped==true or equipped==false then
  1142. if attack==false then
  1143. idle=idle+1
  1144. else
  1145. idle=0
  1146. end
  1147. if idle>=500 then
  1148. if attack==false then
  1149. --Sheath()
  1150. end
  1151. end
  1152. if RootPart.Velocity.y > 1 and hitfloor==nil then
  1153. Anim="Jump"
  1154. if attack==false then
  1155. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.2)
  1156. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-10),math.rad(0),math.rad(0)),.2)
  1157. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(20)),.2)
  1158. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-20)),.2)
  1159. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(10)),.2)
  1160. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(20)),.2)
  1161. end
  1162. elseif RootPart.Velocity.y < -1 and hitfloor==nil then
  1163. Anim="Fall"
  1164. if attack==false then
  1165. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(10),math.rad(0),math.rad(0)),.2)
  1166. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(10),math.rad(0),math.rad(0)),.2)
  1167. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(30)),.2)
  1168. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(-10), math.rad(0), math.rad(-30)),.2)
  1169. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(20)),.2)
  1170. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(10)),.2)
  1171. end
  1172. elseif torvel<1 and hitfloor~=nil then
  1173. Anim="Idle"
  1174. if attack==false then
  1175. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-30)),.2)
  1176. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(30)),.2)
  1177. RW.C0 = clerp(RW.C0, CFrame.new(1, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(-30)),.2)
  1178. LW.C0 = clerp(LW.C0, CFrame.new(-0.7, 0.5, -1) * angles(math.rad(0), math.rad(80), math.rad(100)),.2)
  1179. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),.2)
  1180. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-70),math.rad(-5)),.2)
  1181. end
  1182. elseif torvel>2 and torvel<22 and hitfloor~=nil then
  1183. Anim="Walk"
  1184. if attack==false then
  1185. change=3
  1186. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(10),math.rad(0),math.rad(-30)),.2)
  1187. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-5),math.rad(-5),math.rad(30)),.2)
  1188. RW.C0 = clerp(RW.C0, CFrame.new(1, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(-30)),.2)
  1189. LW.C0 = clerp(LW.C0, CFrame.new(-0.7, 0.5, -1) * angles(math.rad(0), math.rad(80), math.rad(100)),.2)
  1190. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(-10)),.2)
  1191. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-80),math.rad(10)),.2)
  1192. end
  1193. elseif torvel>=22 and hitfloor~=nil then
  1194. Anim="Run"
  1195. if attack==false then
  1196. RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),.2)
  1197. Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(0),math.rad(0),math.rad(0)),.2)
  1198. RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(0)),.2)
  1199. LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(0), math.rad(0), math.rad(0)),.2)
  1200. RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0)),.2)
  1201. LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0)),.2)
  1202. end
  1203. end
  1204. end
  1205. if #Effects>0 then
  1206. --table.insert(Effects,{prt,"Block1",delay})
  1207. for e=1,#Effects do
  1208. if Effects[e]~=nil then
  1209. --for j=1,#Effects[e] do
  1210. local Thing=Effects[e]
  1211. if Thing~=nil then
  1212. local Part=Thing[1]
  1213. local Mode=Thing[2]
  1214. local Delay=Thing[3]
  1215. local IncX=Thing[4]
  1216. local IncY=Thing[5]
  1217. local IncZ=Thing[6]
  1218. if Thing[2]=="DecreaseStat" then
  1219. Thing[5]=Thing[5]-1
  1220. if Thing[5]<=0 then
  1221. if Thing[1]:findFirstChild("Stats")~=nil then
  1222. Thing[1].Stats[Thing[3]].Value=Thing[1].Stats[Thing[3]].Value+Thing[4]
  1223. end
  1224. table.remove(Effects,e)
  1225. end
  1226. end
  1227. if Thing[2]=="Shoot" then
  1228. local Look=Thing[1]
  1229. local hit,pos = rayCast(Thing[4],Look,20,m)
  1230. local mag=(Thing[4]-pos).magnitude
  1231. MagicHead(BrickColor.new("Cyan"),CFrame.new((Thing[4]+pos)/2,pos)*angles(1.57,0,0),1,mag*5,1,.5,0,.5,0.1)
  1232. Thing[4]=Thing[4]+(Look*20)
  1233. Thing[3]=Thing[3]-1
  1234. if hit~=nil then
  1235. Thing[3]=0
  1236. if Thing[8]==1 then
  1237. Damagefunc(hit,Thing[5],Thing[6],Thing[7],"Normal",RootPart,10,20,math.random(1,5),nil,nil,true)
  1238. elseif Thing[8]==2 then
  1239. Damagefunc(hit,Thing[5],Thing[6],Thing[7],"NormalDecreaseMvmt1",RootPart,10,20,math.random(1,5),nil,nil,true)
  1240. end
  1241. ref=part(3,workspace,"SmoothPlastic",0,1,BrickColor.new("Cyan"),"Reference",vt())
  1242. ref.Anchored=true
  1243. ref.CFrame=cf(pos)
  1244. MagicCircle(BrickColor.new("Cyan"),cf(pos),5,5,5,1,1,1,0.03)
  1245. game:GetService("Debris"):AddItem(ref,1)
  1246. end
  1247. if Thing[3]<=0 then
  1248. table.remove(Effects,e)
  1249. end
  1250. end
  1251. if Thing[2]=="CylinderClang" then
  1252. if Thing[3]<=1 then
  1253. Thing[1].CFrame=Thing[1].CFrame*CFrame.new(0,2.5*Thing[5],0)*CFrame.fromEulerAnglesXYZ(Thing[6],0,0)
  1254. Thing[7]=Thing[1].CFrame
  1255. effect("Cyan",0,Thing[8],Thing[7])
  1256. Thing[8]=Thing[7]
  1257. Thing[3]=Thing[3]+Thing[4]
  1258. else
  1259. Part.Parent=nil
  1260. table.remove(Effects,e)
  1261. end
  1262. --[[Mesh=Thing[7]
  1263. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1264. Thing[1].Transparency=Thing[1].Transparency+Thing[3]]
  1265. end
  1266. if Thing[2]~="Shoot" and Thing[2]~="DecreaseStat" then
  1267. if Thing[1].Transparency<=1 then
  1268. if Thing[2]=="Block1" then
  1269. Thing[1].CFrame=Thing[1].CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))
  1270. Mesh=Thing[7]
  1271. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1272. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1273. elseif Thing[2]=="Block2" then
  1274. Thing[1].CFrame=Thing[1].CFrame
  1275. Mesh=Thing[7]
  1276. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1277. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1278. elseif Thing[2]=="Cylinder" then
  1279. Mesh=Thing[7]
  1280. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1281. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1282. elseif Thing[2]=="Blood" then
  1283. Mesh=Thing[7]
  1284. Thing[1].CFrame=Thing[1].CFrame*cf(0,.5,0)
  1285. Mesh.Scale=Mesh.Scale+vt(Thing[4],Thing[5],Thing[6])
  1286. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1287. elseif Thing[2]=="Elec" then
  1288. Mesh=Thing[1].Mesh
  1289. Mesh.Scale=Mesh.Scale+vt(Thing[7],Thing[8],Thing[9])
  1290. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1291. elseif Thing[2]=="Disappear" then
  1292. Thing[1].Transparency=Thing[1].Transparency+Thing[3]
  1293. end
  1294. else
  1295. Part.Parent=nil
  1296. table.remove(Effects,e)
  1297. end
  1298. end
  1299. end
  1300. --end
  1301. end
  1302. end
  1303. end
  1304. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement