Advertisement
Zebula_The_Scripter

Radioactive Warden

Sep 20th, 2018
430
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 67.88 KB | None | 0 0
  1. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  2. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  3. do
  4. print("FE Compatibility code by Mokiros")
  5. script.Parent = Player.Character
  6.  
  7. --RemoteEvent for communicating
  8. local Event = Instance.new("RemoteEvent")
  9. Event.Name = "UserInput_Event"
  10.  
  11. --Fake event to make stuff like Mouse.KeyDown work
  12. local function fakeEvent()
  13. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  14. t.connect = t.Connect
  15. return t
  16. end
  17.  
  18. --Creating fake input objects with fake variables
  19. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  20. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  21. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  22. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  23. end}
  24. --Merged 2 functions into one by checking amount of arguments
  25. CAS.UnbindAction = CAS.BindAction
  26.  
  27. --This function will trigger the events that have been :Connect()'ed
  28. local function te(self,ev,...)
  29. local t = m[ev]
  30. if t and t._fakeEvent and t.Function then
  31. t.Function(...)
  32. end
  33. end
  34. m.TrigEvent = te
  35. UIS.TrigEvent = te
  36.  
  37. Event.OnServerEvent:Connect(function(plr,io)
  38. if plr~=Player then return end
  39. if io.isMouse then
  40. m.Target = io.Target
  41. m.Hit = io.Hit
  42. else
  43. local b = io.UserInputState == Enum.UserInputState.Begin
  44. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  45. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  46. end
  47. for _,t in pairs(CAS.Actions) do
  48. for _,k in pairs(t.Keys) do
  49. if k==io.KeyCode then
  50. t.Function(t.Name,io.UserInputState,io)
  51. end
  52. end
  53. end
  54. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  55. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  56. end
  57. end)
  58. Event.Parent = NLS([==[
  59. local Player = game:GetService("Players").LocalPlayer
  60. local Event = script:WaitForChild("UserInput_Event")
  61.  
  62. local UIS = game:GetService("UserInputService")
  63. local input = function(io,a)
  64. if a then return end
  65. --Since InputObject is a client-side instance, we create and pass table instead
  66. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  67. end
  68. UIS.InputBegan:Connect(input)
  69. UIS.InputEnded:Connect(input)
  70.  
  71. local h,t
  72. --Give the server mouse data 30 times every second, but only if the values changed
  73. --If player is not moving their mouse, client won't fire events
  74. while wait(1/30) do
  75. if h~=Mouse.Hit or t~=Mouse.Target then
  76. h,t=Mouse.Hit,Mouse.Target
  77. Event:FireServer({isMouse=true,Target=t,Hit=h})
  78. end
  79. end]==],Player.Character)
  80. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  81.  
  82. end
  83.  
  84. --//====================================================\\--
  85. --|| Edited By BeeESwarm_Simulator
  86. --\\====================================================//--
  87.  
  88. Player = owner
  89. PlayerGui = Player.PlayerGui
  90. Cam = workspace.CurrentCamera
  91. Backpack = Player.Backpack
  92. Character = Player.Character
  93. Humanoid = Character.Humanoid
  94. RootPart = Character["HumanoidRootPart"]
  95. Torso = Character["Torso"]
  96. Head = Character["Head"]
  97. RightArm = Character["Right Arm"]
  98. LeftArm = Character["Left Arm"]
  99. RightLeg = Character["Right Leg"]
  100. LeftLeg = Character["Left Leg"]
  101. RootJoint = RootPart["RootJoint"]
  102. Neck = Torso["Neck"]
  103. RightShoulder = Torso["Right Shoulder"]
  104. LeftShoulder = Torso["Left Shoulder"]
  105. RightHip = Torso["Right Hip"]
  106. LeftHip = Torso["Left Hip"]
  107. local sick = Instance.new("Sound",Character)
  108. sick.SoundId = "rbxassetid://262067268"
  109. sick.Looped = true
  110. sick.Volume = 1.0
  111. sick:Play()
  112.  
  113. IT = Instance.new
  114. CF = CFrame.new
  115. VT = Vector3.new
  116. RAD = math.rad
  117. C3 = Color3.new
  118. UD2 = UDim2.new
  119. BRICKC = BrickColor.new
  120. ANGLES = CFrame.Angles
  121. EULER = CFrame.fromEulerAnglesXYZ
  122. COS = math.cos
  123. ACOS = math.acos
  124. SIN = math.sin
  125. ASIN = math.asin
  126. ABS = math.abs
  127. MRANDOM = math.random
  128. FLOOR = math.floor
  129.  
  130. --//=================================\\
  131. --|| USEFUL VALUES
  132. --\\=================================//
  133.  
  134. Animation_Speed = 3
  135. Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60)
  136. local Speed = 25
  137. local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  138. local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180))
  139. local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0))
  140. local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0))
  141. local DAMAGEMULTIPLIER = 1
  142. local ANIM = "Idle"
  143. local ATTACK = false
  144. local EQUIPPED = false
  145. local HOLD = false
  146. local COMBO = 1
  147. local Rooted = false
  148. local SINE = 0
  149. local KEYHOLD = false
  150. local CHANGE = 2 / Animation_Speed
  151. local WALKINGANIM = false
  152. local VALUE1 = false
  153. local VALUE2 = false
  154. local ROBLOXIDLEANIMATION = IT("Animation")
  155. ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation"
  156. ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=265082452"
  157. --ROBLOXIDLEANIMATION.Parent = Humanoid
  158. local WEAPONGUI = IT("ScreenGui", PlayerGui)
  159. WEAPONGUI.Name = "Weapon GUI"
  160. local Effects = IT("Folder", Character)
  161. Effects.Name = "Effects"
  162. local ANIMATOR = Humanoid.Animator
  163. local ANIMATE = Character.Animate
  164. local UNANCHOR = true
  165. local PLAYMAINANIM = true
  166. local BOLTSOUNDS = {168586621,168586586,178452241}
  167.  
  168. --//=================================\\
  169. --\\=================================//
  170.  
  171.  
  172. --//=================================\\
  173. --|| SAZERENOS' ARTIFICIAL HEARTBEAT
  174. --\\=================================//
  175.  
  176. ArtificialHB = Instance.new("BindableEvent", script)
  177. ArtificialHB.Name = "ArtificialHB"
  178.  
  179. script:WaitForChild("ArtificialHB")
  180.  
  181. frame = Frame_Speed
  182. tf = 0
  183. allowframeloss = false
  184. tossremainder = false
  185. lastframe = tick()
  186. script.ArtificialHB:Fire()
  187.  
  188. game:GetService("RunService").Heartbeat:connect(function(s, p)
  189. tf = tf + s
  190. if tf >= frame then
  191. if allowframeloss then
  192. script.ArtificialHB:Fire()
  193. lastframe = tick()
  194. else
  195. for i = 1, math.floor(tf / frame) do
  196. script.ArtificialHB:Fire()
  197. end
  198. lastframe = tick()
  199. end
  200. if tossremainder then
  201. tf = 0
  202. else
  203. tf = tf - frame * math.floor(tf / frame)
  204. end
  205. end
  206. end)
  207.  
  208. --//=================================\\
  209. --\\=================================//
  210.  
  211. --//=================================\\
  212. --|| SOME FUNCTIONS
  213. --\\=================================//
  214.  
  215. function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS)
  216. return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS)
  217. end
  218.  
  219. function PositiveAngle(NUMBER)
  220. if NUMBER >= 0 then
  221. NUMBER = 0
  222. end
  223. return NUMBER
  224. end
  225.  
  226. function NegativeAngle(NUMBER)
  227. if NUMBER <= 0 then
  228. NUMBER = 0
  229. end
  230. return NUMBER
  231. end
  232.  
  233. function Swait(NUMBER)
  234. if NUMBER == 0 or NUMBER == nil then
  235. ArtificialHB.Event:wait()
  236. else
  237. for i = 1, NUMBER do
  238. ArtificialHB.Event:wait()
  239. end
  240. end
  241. end
  242.  
  243. function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET)
  244. local NEWMESH = IT(MESH)
  245. if MESH == "SpecialMesh" then
  246. NEWMESH.MeshType = MESHTYPE
  247. if MESHID ~= "nil" and MESHID ~= "" then
  248. NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID
  249. end
  250. if TEXTUREID ~= "nil" and TEXTUREID ~= "" then
  251. NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID
  252. end
  253. end
  254. NEWMESH.Offset = OFFSET or VT(0, 0, 0)
  255. NEWMESH.Scale = SCALE
  256. NEWMESH.Parent = PARENT
  257. return NEWMESH
  258. end
  259.  
  260. function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR)
  261. local NEWPART = IT("Part")
  262. NEWPART.formFactor = FORMFACTOR
  263. NEWPART.Reflectance = REFLECTANCE
  264. NEWPART.Transparency = TRANSPARENCY
  265. NEWPART.CanCollide = false
  266. NEWPART.Locked = true
  267. NEWPART.Anchored = true
  268. if ANCHOR == false then
  269. NEWPART.Anchored = false
  270. end
  271. NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR))
  272. NEWPART.Name = NAME
  273. NEWPART.Size = SIZE
  274. NEWPART.Position = Torso.Position
  275. NEWPART.Material = MATERIAL
  276. NEWPART:BreakJoints()
  277. NEWPART.Parent = PARENT
  278. return NEWPART
  279. end
  280.  
  281. local function weldBetween(a, b)
  282. local weldd = Instance.new("ManualWeld")
  283. weldd.Part0 = a
  284. weldd.Part1 = b
  285. weldd.C0 = CFrame.new()
  286. weldd.C1 = b.CFrame:inverse() * a.CFrame
  287. weldd.Parent = a
  288. return weldd
  289. end
  290.  
  291.  
  292. function QuaternionFromCFrame(cf)
  293. local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
  294. local trace = m00 + m11 + m22
  295. if trace > 0 then
  296. local s = math.sqrt(1 + trace)
  297. local recip = 0.5 / s
  298. return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5
  299. else
  300. local i = 0
  301. if m11 > m00 then
  302. i = 1
  303. end
  304. if m22 > (i == 0 and m00 or m11) then
  305. i = 2
  306. end
  307. if i == 0 then
  308. local s = math.sqrt(m00 - m11 - m22 + 1)
  309. local recip = 0.5 / s
  310. return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip
  311. elseif i == 1 then
  312. local s = math.sqrt(m11 - m22 - m00 + 1)
  313. local recip = 0.5 / s
  314. return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip
  315. elseif i == 2 then
  316. local s = math.sqrt(m22 - m00 - m11 + 1)
  317. local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip
  318. end
  319. end
  320. end
  321.  
  322. function QuaternionToCFrame(px, py, pz, x, y, z, w)
  323. local xs, ys, zs = x + x, y + y, z + z
  324. local wx, wy, wz = w * xs, w * ys, w * zs
  325. local xx = x * xs
  326. local xy = x * ys
  327. local xz = x * zs
  328. local yy = y * ys
  329. local yz = y * zs
  330. local zz = z * zs
  331. 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))
  332. end
  333.  
  334. function QuaternionSlerp(a, b, t)
  335. local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4]
  336. local startInterp, finishInterp;
  337. if cosTheta >= 0.0001 then
  338. if (1 - cosTheta) > 0.0001 then
  339. local theta = ACOS(cosTheta)
  340. local invSinTheta = 1 / SIN(theta)
  341. startInterp = SIN((1 - t) * theta) * invSinTheta
  342. finishInterp = SIN(t * theta) * invSinTheta
  343. else
  344. startInterp = 1 - t
  345. finishInterp = t
  346. end
  347. else
  348. if (1 + cosTheta) > 0.0001 then
  349. local theta = ACOS(-cosTheta)
  350. local invSinTheta = 1 / SIN(theta)
  351. startInterp = SIN((t - 1) * theta) * invSinTheta
  352. finishInterp = SIN(t * theta) * invSinTheta
  353. else
  354. startInterp = t - 1
  355. finishInterp = t
  356. end
  357. end
  358. 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
  359. end
  360.  
  361. function Clerp(a, b, t)
  362. local qa = {QuaternionFromCFrame(a)}
  363. local qb = {QuaternionFromCFrame(b)}
  364. local ax, ay, az = a.x, a.y, a.z
  365. local bx, by, bz = b.x, b.y, b.z
  366. local _t = 1 - t
  367. return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t))
  368. end
  369.  
  370. function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME)
  371. local frame = IT("Frame")
  372. frame.BackgroundTransparency = TRANSPARENCY
  373. frame.BorderSizePixel = BORDERSIZEPIXEL
  374. frame.Position = POSITION
  375. frame.Size = SIZE
  376. frame.BackgroundColor3 = COLOR
  377. frame.BorderColor3 = BORDERCOLOR
  378. frame.Name = NAME
  379. frame.Parent = PARENT
  380. return frame
  381. end
  382.  
  383. function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME)
  384. local label = IT("TextLabel")
  385. label.BackgroundTransparency = 1
  386. label.Size = UD2(1, 0, 1, 0)
  387. label.Position = UD2(0, 0, 0, 0)
  388. label.TextColor3 = TEXTCOLOR
  389. label.TextStrokeTransparency = STROKETRANSPARENCY
  390. label.TextTransparency = TRANSPARENCY
  391. label.FontSize = TEXTFONTSIZE
  392. label.Font = TEXTFONT
  393. label.BorderSizePixel = BORDERSIZEPIXEL
  394. label.TextScaled = false
  395. label.Text = TEXT
  396. label.Name = NAME
  397. label.Parent = PARENT
  398. return label
  399. end
  400.  
  401. function NoOutlines(PART)
  402. PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10
  403. end
  404.  
  405. function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1)
  406. local NEWWELD = IT(TYPE)
  407. NEWWELD.Part0 = PART0
  408. NEWWELD.Part1 = PART1
  409. NEWWELD.C0 = C0
  410. NEWWELD.C1 = C1
  411. NEWWELD.Parent = PARENT
  412. return NEWWELD
  413. end
  414.  
  415. local S = IT("Sound")
  416. function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP)
  417. local NEWSOUND = nil
  418. coroutine.resume(coroutine.create(function()
  419. NEWSOUND = S:Clone()
  420. NEWSOUND.Parent = PARENT
  421. NEWSOUND.Volume = VOLUME
  422. NEWSOUND.Pitch = PITCH
  423. NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID
  424. NEWSOUND:play()
  425. if DOESLOOP == true then
  426. NEWSOUND.Looped = true
  427. else
  428. repeat wait(1) until NEWSOUND.Playing == false
  429. NEWSOUND:remove()
  430. end
  431. end))
  432. return NEWSOUND
  433. end
  434.  
  435. local EyeSizes={
  436. NumberSequenceKeypoint.new(0,2,0),
  437. NumberSequenceKeypoint.new(1,0,0)
  438. }
  439. local EyeTrans={
  440. NumberSequenceKeypoint.new(0,0.5,0),
  441. NumberSequenceKeypoint.new(1,1,0)
  442. }
  443. local PE=Instance.new("ParticleEmitter",nil)
  444. PE.LightEmission=.8
  445. PE.Color = ColorSequence.new(BRICKC("Crimson").Color,BRICKC("Lime green").Color)
  446. PE.Size=NumberSequence.new(EyeSizes)
  447. PE.Transparency=NumberSequence.new(EyeTrans)
  448. PE.Lifetime=NumberRange.new(0.35,1)
  449. PE.Rotation=NumberRange.new(0,360)
  450. PE.Rate=100
  451. PE.VelocitySpread = 10000
  452. PE.Acceleration = Vector3.new(0,85,0)
  453. PE.Drag = 5
  454. PE.Speed = NumberRange.new(0.1,5)
  455. PE.Texture="http://www.roblox.com/asset/?id=1460745664"
  456. PE.ZOffset = 0.5
  457. PE.Name = "PE"
  458. PE.Enabled = false
  459.  
  460. function Fire(art)
  461. local PARTICLES = PE:Clone()
  462. PARTICLES.Parent = art
  463. PARTICLES.Enabled = true
  464. return PARTICLES
  465. end
  466.  
  467. function CFrameFromTopBack(at, top, back)
  468. local right = top:Cross(back)
  469. return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z)
  470. end
  471.  
  472. --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  473. function WACKYEFFECT(Table)
  474. local TYPE = (Table.EffectType or "Sphere")
  475. local SIZE = (Table.Size or VT(1,1,1))
  476. local ENDSIZE = (Table.Size2 or VT(0,0,0))
  477. local TRANSPARENCY = (Table.Transparency or 0)
  478. local ENDTRANSPARENCY = (Table.Transparency2 or 1)
  479. local CFRAME = (Table.CFrame or Torso.CFrame)
  480. local MOVEDIRECTION = (Table.MoveToPos or nil)
  481. local ROTATION1 = (Table.RotationX or 0)
  482. local ROTATION2 = (Table.RotationY or 0)
  483. local ROTATION3 = (Table.RotationZ or 0)
  484. local MATERIAL = (Table.Material or "Neon")
  485. local COLOR = (Table.Color or C3(1,1,1))
  486. local TIME = (Table.Time or 45)
  487. local SOUNDID = (Table.SoundID or nil)
  488. local SOUNDPITCH = (Table.SoundPitch or nil)
  489. local SOUNDVOLUME = (Table.SoundVolume or nil)
  490. coroutine.resume(coroutine.create(function()
  491. local PLAYSSOUND = false
  492. local SOUND = nil
  493. local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Really green"), "Effect", VT(1,1,1), true)
  494. if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then
  495. PLAYSSOUND = true
  496. SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false)
  497. end
  498. EFFECT.Color = COLOR
  499. local MSH = nil
  500. if TYPE == "Sphere" then
  501. MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0))
  502. elseif TYPE == "Block" or TYPE == "Box" then
  503. MSH = IT("BlockMesh",EFFECT)
  504. MSH.Scale = SIZE
  505. elseif TYPE == "Wave" then
  506. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8))
  507. elseif TYPE == "Ring" then
  508. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0))
  509. elseif TYPE == "Slash" then
  510. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
  511. elseif TYPE == "Round Slash" then
  512. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
  513. elseif TYPE == "Swirl" then
  514. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0))
  515. elseif TYPE == "Skull" then
  516. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0))
  517. elseif TYPE == "Crystal" then
  518. MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0))
  519. end
  520. if MSH ~= nil then
  521. local MOVESPEED = nil
  522. if MOVEDIRECTION ~= nil then
  523. MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME
  524. end
  525. local GROWTH = SIZE - ENDSIZE
  526. local TRANS = TRANSPARENCY - ENDTRANSPARENCY
  527. if TYPE == "Block" then
  528. EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
  529. else
  530. EFFECT.CFrame = CFRAME
  531. end
  532. for LOOP = 1, TIME+1 do
  533. Swait()
  534. MSH.Scale = MSH.Scale - GROWTH/TIME
  535. if TYPE == "Wave" then
  536. MSH.Offset = VT(0,0,-MSH.Scale.X/8)
  537. end
  538. EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME
  539. if TYPE == "Block" then
  540. EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))
  541. else
  542. EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3))
  543. end
  544. if MOVEDIRECTION ~= nil then
  545. local ORI = EFFECT.Orientation
  546. EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED)
  547. EFFECT.Orientation = ORI
  548. end
  549. end
  550. if PLAYSSOUND == false then
  551. EFFECT:remove()
  552. else
  553. repeat wait(1) until SOUND.Playing == false
  554. EFFECT:remove()
  555. end
  556. else
  557. if PLAYSSOUND == false then
  558. EFFECT:remove()
  559. else
  560. repeat Swait() until SOUND.Playing == false
  561. EFFECT:remove()
  562. end
  563. end
  564. end))
  565. end
  566.  
  567. function MakeForm(PART,TYPE)
  568. if TYPE == "Cyl" then
  569. local MSH = IT("CylinderMesh",PART)
  570. elseif TYPE == "Ball" then
  571. local MSH = IT("SpecialMesh",PART)
  572. MSH.MeshType = "Sphere"
  573. elseif TYPE == "Wedge" then
  574. local MSH = IT("SpecialMesh",PART)
  575. MSH.MeshType = "Wedge"
  576. end
  577. end
  578.  
  579. Debris = game:GetService("Debris")
  580.  
  581. function CastProperRay(StartPos, EndPos, Distance, Ignore)
  582. local DIRECTION = CF(StartPos,EndPos).lookVector
  583. return Raycast(StartPos, DIRECTION, Distance, Ignore)
  584. end
  585.  
  586. local HATWELD = nil
  587. function Pose(WhichPose,Speed,Time,Magic,Gyro,Tors)
  588. PLAYMAINANIM = false
  589. if WhichPose == "Cast1" then
  590. for i=0, Time, 0.1 / Animation_Speed do
  591. Swait()
  592. if Magic == true then
  593. WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  594. end
  595. if Gyro ~= nil and Gyro ~= false then
  596. Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
  597. end
  598. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(35)), Speed / Animation_Speed)
  599. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-35)), Speed / Animation_Speed)
  600. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(125), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  601. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  602. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  603. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  604. end
  605. elseif WhichPose == "Cast2" then
  606. for i=0, Time, 0.1 / Animation_Speed do
  607. Swait()
  608. if Magic == true then
  609. WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  610. WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = LeftArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  611. end
  612. if Gyro ~= nil and Gyro ~= false then
  613. Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
  614. end
  615. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
  616. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-15 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
  617. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(15)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  618. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(120), RAD(0), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  619. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  620. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  621. end
  622. elseif WhichPose == "RightArmUp" then
  623. for i=0, Time, 0.1 / Animation_Speed do
  624. Swait()
  625. if Magic == true then
  626. WACKYEFFECT({Time = 15, EffectType = "Crystal", Size = VT(1,1,1)*1.5, Size2 = VT(0,4,0), Transparency = 0, Transparency2 = 1, CFrame = RightArm.CFrame*CF(0,-1,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Glass", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  627. end
  628. if Gyro ~= nil and Gyro ~= false then
  629. Gyro.cframe = CF(RootPart.Position,Mouse.Hit.p)
  630. end
  631. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(15)), Speed / Animation_Speed)
  632. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-15)), Speed / Animation_Speed)
  633. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.65 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.2) * ANGLES(RAD(125), RAD(0), RAD(25)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  634. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  635. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  636. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  637. end
  638. elseif WhichPose == "Taunt" then
  639. for i=0, Time, 0.1 / Animation_Speed do
  640. Swait()
  641. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
  642. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
  643. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  644. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  645. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  646. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  647. end
  648. HATWELD.Part0 = RightArm
  649. HATWELD.C0 = CF(0,-1.1,-0.4) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(-20), RAD(0), RAD(0))
  650. CreateSound(221057812,Torso,10,1,false)
  651. for i=0, Time*2, 0.1 / Animation_Speed do
  652. Swait()
  653. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
  654. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(35 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(0)), Speed / Animation_Speed)
  655. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(145), RAD(0), RAD(45)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  656. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(5), RAD(25), RAD(-15)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  657. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  658. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  659. end
  660. for i=0, Time, 0.1 / Animation_Speed do
  661. Swait()
  662. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), Speed / Animation_Speed)
  663. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5), RAD(0), RAD(0)), Speed / Animation_Speed)
  664. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.35, 0.65, -0.5) * ANGLES(RAD(175), RAD(0), RAD(-35)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  665. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  666. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  667. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  668. HATWELD.C0 = Clerp(HATWELD.C0, CF(-0.5,-1.2,-0.3) * ANGLES(RAD(0), RAD(0), RAD(180)) * ANGLES(RAD(35), RAD(0), RAD(35)), Speed / Animation_Speed)
  669. end
  670. HATWELD.Part0 = Head
  671. HATWELD.C0 = CF(0,0.35,0)
  672. elseif WhichPose == "Prepare key" then
  673. for i=0, Time, 0.1 / Animation_Speed do
  674. Swait()
  675. if Gyro ~= nil and Gyro ~= false then
  676. Gyro.cframe = CF(RootPart.Position,Tors.Position)
  677. end
  678. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(65)), Speed / Animation_Speed)
  679. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-65)), Speed / Animation_Speed)
  680. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(65)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  681. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  682. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  683. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  684. end
  685. elseif WhichPose == "Turn key" then
  686. for i=0, Time, 0.1 / Animation_Speed do
  687. Swait()
  688. if Gyro ~= nil and Gyro ~= false then
  689. Gyro.cframe = CF(RootPart.Position,Tors.Position)
  690. end
  691. RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(75)), Speed / Animation_Speed)
  692. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(5 - 6.5 * SIN(SINE / 12)), RAD(0), RAD(-75)), Speed / Animation_Speed)
  693. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), -0.25) * ANGLES(RAD(90), RAD(0), RAD(75)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * RIGHTSHOULDERC0, Speed / Animation_Speed)
  694. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.25, 0.5 + 0.15 * COS(SINE / 12) - 0.05 * COS(SINE / 12), 0.5) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, Speed / Animation_Speed)
  695. RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(0), RAD(65), RAD(0)) * ANGLES(RAD(-3), RAD(0), RAD(-15)), Speed / Animation_Speed)
  696. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), Speed / Animation_Speed)
  697. end
  698. end
  699. PLAYMAINANIM = true
  700. end
  701.  
  702. --Lightning({Color = C3(1,1,1), Start = Torso.Position, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.1, DoesFade = false, Ignore = Character, MaxDist = 400, Branches = false})
  703. function Lightning(Table)
  704. local Color = Table.Color or C3(1,1,1)
  705. local StartPos = Table.Start or Torso.Position
  706. local EndPos = Table.End or Mouse.Hit.p
  707. local SegmentLength = Table.SegmentL or 2
  708. local Thickness = Table.Thickness or 0.1
  709. local Dissapear = Table.DoesFade or false
  710. local Parent = Table.Ignore or Character
  711. local MaxDist = Table.MaxDist or 400
  712. local Branches = Table.Branches or false
  713. local HIT,HITPOS = CastProperRay(StartPos, EndPos, MaxDist, Parent)
  714. local DISTANCE = math.ceil((StartPos - HITPOS).Magnitude/SegmentLength)
  715. local LIGHTNINGMODEL = IT("Model",Effects)
  716. LIGHTNINGMODEL.Name = "Lightning"
  717. local LastBolt = nil
  718. for E = 1, DISTANCE do
  719. local ExtraSize = (DISTANCE-E)/15
  720. local PART = CreatePart(3, LIGHTNINGMODEL, "Neon", 0, 0, BRICKC("Crimson"), "LightningPart"..E, VT(Thickness+ExtraSize,SegmentLength,Thickness+ExtraSize))
  721. PART.Color = Color
  722. MakeForm(PART,"Cyl")
  723. if LastBolt == nil then
  724. PART.CFrame = CF(StartPos,HITPOS)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
  725. else
  726. PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,CF(HITPOS)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)))*CF(0,0,SegmentLength/3+(DISTANCE-E)).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
  727. end
  728. LastBolt = PART
  729. if Branches == true then
  730. local CHOICE = MRANDOM(1,7+((DISTANCE-E)*2))
  731. if CHOICE == 1 then
  732. local LASTBRANCH = nil
  733. for i = 1, MRANDOM(2,5) do
  734. local ExtraSize2 = ((DISTANCE-E)/25)/i
  735. local PART = CreatePart(3, LIGHTNINGMODEL, "Neon", 0, 0, BRICKC("Crimson"), "Branch"..E.."-"..i, VT(Thickness+ExtraSize2,SegmentLength,Thickness+ExtraSize2))
  736. PART.Color = Color
  737. MakeForm(PART,"Cyl")
  738. if LASTBRANCH == nil then
  739. PART.CFrame = CF(LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0).p,LastBolt.CFrame*CF(0,-LastBolt.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*7,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
  740. else
  741. PART.CFrame = CF(LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0).p,LASTBRANCH.CFrame*CF(0,-LASTBRANCH.Size.Y/2,0)*ANGLES(RAD(0),RAD(0),RAD(MRANDOM(0,360)))*CF(0,Thickness*3,0)*CF(0,0,-1).p)*ANGLES(RAD(90),RAD(0),RAD(0))*CF(0,-PART.Size.Y/2,0)
  742. end
  743. LASTBRANCH = PART
  744. end
  745. end
  746. end
  747. end
  748. if Dissapear == true then
  749. coroutine.resume(coroutine.create(function()
  750. for i = 1, 10 do
  751. Swait()
  752. for _, c in pairs(LIGHTNINGMODEL:GetChildren()) do
  753. if c.ClassName == "Part" then
  754. c.Transparency = i/10
  755. end
  756. end
  757. end
  758. LIGHTNINGMODEL:remove()
  759. end))
  760. elseif Dissapear == false then
  761. Debris:AddItem(LIGHTNINGMODEL,0.1)
  762. end
  763. return {End = LastBolt.CFrame*CF(0,0,-LastBolt.Size.Z/2).p,LastBolt = LastBolt,Model = LIGHTNINGMODEL}
  764. end
  765.  
  766. --//=================================\\
  767. --|| WEAPON CREATION
  768. --\\=================================//
  769.  
  770. Void = Instance.new("Model")
  771. Void.Name = "Void"
  772. Angle = 0
  773. for i = 1, 1 do
  774. local VoidPart = Instance.new("Part")
  775. VoidPart.Name = "VoidPart"
  776. VoidPart.Transparency = 1
  777. VoidPart.BrickColor = BrickColor.new("Really black")
  778. VoidPart.Material = Enum.Material.Plastic
  779. VoidPart.Shape = Enum.PartType.Block
  780. VoidPart.FormFactor = Enum.FormFactor.Custom
  781. VoidPart.TopSurface = Enum.SurfaceType.Smooth
  782. VoidPart.BottomSurface = Enum.SurfaceType.Smooth
  783. VoidPart.Anchored = true
  784. VoidPart.CanCollide = false
  785. VoidPart.Locked = true
  786. VoidPart.Size = Vector3.new(18, 0.2, 18)
  787. local BlockMesh = Instance.new("BlockMesh")
  788. BlockMesh.Scale = Vector3.new(1, (1 + (0.005 * i)), 1)
  789. BlockMesh.Parent = VoidPart
  790. VoidPart.Parent = Void
  791. local Star = Instance.new("Decal", VoidPart)
  792. Star.Texture = "rbxassetid://132379770"
  793. end
  794.  
  795. local BC = Character["Body Colors"]
  796. BC.HeadColor = BrickColor.new("Lime green")
  797. BC.LeftArmColor = BrickColor.new("Lime green")
  798. BC.LeftLegColor = BrickColor.new("Really black")
  799. BC.RightArmColor = BrickColor.new("Lime green")
  800. BC.RightLegColor = BrickColor.new("Really black")
  801. BC.TorsoColor = BrickColor.new("Lime green")
  802.  
  803. local PE=Instance.new("ParticleEmitter",nil)
  804. PE.LightEmission=.8
  805. PE.Color = ColorSequence.new(BRICKC("Lime green").Color,BRICKC("Lime green").Color)
  806. PE.Size=NumberSequence.new(EyeSizes)
  807. PE.Transparency=NumberSequence.new(EyeTrans)
  808. PE.Lifetime=NumberRange.new(0.35,1)
  809. PE.Rotation=NumberRange.new(0,360)
  810. PE.Rate=100
  811. PE.VelocitySpread = 10000
  812. PE.Acceleration = Vector3.new(0,85,0)
  813. PE.Drag = 5
  814. PE.Speed = NumberRange.new(0.1,5)
  815. PE.Texture="http://www.roblox.com/asset/?id=1460745664"
  816. PE.ZOffset = 0.5
  817. PE.Name = "PE"
  818. PE.Enabled = false
  819.  
  820. for i = 1, 15 do
  821. local FACE = CreatePart(3, Character, "Neon", 0, 0+(i-1)/15.2, "Dark stone grey", "FaceGradient", VT(1.01,0.58,1.01),false)
  822. FACE.Color = C3(0,0,0)
  823. Head:FindFirstChildOfClass("SpecialMesh"):Clone().Parent = FACE
  824. CreateWeldOrSnapOrMotor("Weld", Head, Head, FACE, CF(0,0.35-(i-1)/35,0), CF(0, 0, 0))
  825. end
  826. local HAT1 = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(2,0.2,2),false)
  827. MakeForm(HAT1,"Cyl")
  828. HATWELD = CreateWeldOrSnapOrMotor("Weld", Head, Head, HAT1, CF(0,0.35,0), CF(0, 0, 0))
  829. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(2.01,0.15,2.01),false)
  830. BELT.Color = C3(15/255,15/255,15/255)
  831. MakeForm(BELT,"Cyl")
  832. CreateWeldOrSnapOrMotor("Weld", HAT1, HAT1, BELT, CF(0,0,0), CF(0, 0, 0))
  833. local HAT2 = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.3,2.2,1.3),false)
  834. MakeForm(HAT2,"Cyl")
  835. CreateWeldOrSnapOrMotor("Weld", HAT1, HAT1, HAT2, CF(0,1.1,0), CF(0, 0, 0))
  836. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.31,0.2,1.31),false)
  837. BELT.Color = C3(15/255,15/255,15/255)
  838. MakeForm(BELT,"Cyl")
  839. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,0,0), CF(0, 0, 0))
  840. local GEM = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Gem", VT(0.25,0.25,0.1),false)
  841. MakeForm(GEM,"Ball")
  842. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(0,0,-BELT.Size.X/2), CF(0, 0, 0))
  843. local GEM = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Gem", VT(0.25,0.25,0.1),false)
  844. MakeForm(GEM,"Ball")
  845. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(0,0,BELT.Size.X/2), CF(0, 0, 0))
  846. local GEM = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Gem", VT(0.1,0.25,0.25),false)
  847. MakeForm(GEM,"Ball")
  848. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(-BELT.Size.X/2,0,0), CF(0, 0, 0))
  849. local GEM = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Gem", VT(0.1,0.25,0.25),false)
  850. MakeForm(GEM,"Ball")
  851. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, GEM, CF(BELT.Size.X/2,0,0), CF(0, 0, 0))
  852. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.31,0.1,1.31),false)
  853. BELT.Color = C3(15/255,15/255,15/255)
  854. MakeForm(BELT,"Cyl")
  855. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,0.7,0), CF(0, 0, 0))
  856. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.31,0.1,1.31),false)
  857. BELT.Color = C3(15/255,15/255,15/255)
  858. MakeForm(BELT,"Cyl")
  859. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,-0.7,0), CF(0, 0, 0))
  860. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.31,0.1,1.31),false)
  861. BELT.Color = C3(15/255,15/255,15/255)
  862. MakeForm(BELT,"Cyl")
  863. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,0.35,0), CF(0, 0, 0))
  864. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.31,0.1,1.31),false)
  865. BELT.Color = C3(15/255,15/255,15/255)
  866. MakeForm(BELT,"Cyl")
  867. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,-0.35,0), CF(0, 0, 0))
  868. local BELT = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "Hat", VT(1.3,0.5,1.3),false)
  869. MakeForm(BELT,"Ball")
  870. CreateWeldOrSnapOrMotor("Weld", HAT2, HAT2, BELT, CF(0,HAT2.Size.Y/2,0), CF(0, 0, 0))
  871. Humanoid.DisplayDistanceType = "None"
  872. local naeeym2 = IT("BillboardGui",Character)
  873. naeeym2.AlwaysOnTop = true
  874. naeeym2.Size = UDim2.new(5,35,2,15)
  875. naeeym2.StudsOffset = Vector3.new(0,3,0)
  876. naeeym2.MaxDistance = 75
  877. naeeym2.Adornee = Character.Head
  878. naeeym2.Name = "Name"
  879. naeeym2.PlayerToHideFrom = Player
  880. local tecks2 = IT("TextLabel",naeeym2)
  881. tecks2.BackgroundTransparency = 1
  882. tecks2.TextScaled = true
  883. tecks2.BorderSizePixel = 0
  884. tecks2.Text = "Radioactive Warden"
  885. tecks2.Font = "Bodoni"
  886. tecks2.TextSize = 30
  887. tecks2.TextStrokeTransparency = 0.5
  888. tecks2.TextColor3 = C3(0,0,0)
  889. tecks2.TextStrokeColor3 = BRICKC"Lime green".Color
  890. tecks2.Size = UDim2.new(1,0,0.5,0)
  891. tecks2.Parent = naeeym2
  892. local EYE = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "FaceGradient", VT(0.6,0.1,1)/2,false)
  893. MakeForm(EYE,"Ball")
  894. CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.2,0) * ANGLES(RAD(0), RAD(-18), RAD(15)), CF(0, 0, 0.4))
  895. local EYE = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "FaceGradient", VT(0.6,0.1,1)/2,false)
  896. MakeForm(EYE,"Ball")
  897. CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.2,0) * ANGLES(RAD(0), RAD(18), RAD(-15)), CF(0, 0, 0.4))
  898. local EYE = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "FaceGradient", VT(0.1,1,1)/2,false)
  899. MakeForm(EYE,"Ball")
  900. CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.15,0) * ANGLES(RAD(0), RAD(-18), RAD(0)), CF(0, 0, 0.4))
  901. local EYE = CreatePart(3, Character, "Neon", 0, 0, "Lime green", "FaceGradient", VT(0.1,1,1)/2,false)
  902. MakeForm(EYE,"Ball")
  903. CreateWeldOrSnapOrMotor("Weld", Head, Head, EYE, CF(0,0.15,0) * ANGLES(RAD(0), RAD(18), RAD(0)), CF(0, 0, 0.4))
  904.  
  905. local top = Instance.new("Shirt")
  906. top.ShirtTemplate = "rbxassetid://2237560778"
  907. top.Parent = Character
  908. top.Name = "Cloth"
  909. local bottom = Instance.new("Pants")
  910. bottom.PantsTemplate = "rbxassetid://1041793155"
  911. bottom.Parent = Character
  912. bottom.Name = "Cloth"
  913. for _, c in pairs(Character:GetChildren()) do
  914. if c.ClassName == "Part" and c.Name ~= "FaceGradient" and c.Name ~= "Hat" and c.Name ~= "Gem" then
  915. c.Material = "Neon"
  916. if c:FindFirstChildOfClass("ParticleEmitter") then
  917. c:FindFirstChildOfClass("ParticleEmitter"):remove()
  918. end
  919. c.Color = C3(1,1,1)
  920. if c == Head then
  921. if c:FindFirstChild("face") then
  922. c.face:remove()
  923. end
  924. end
  925. elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.ClassName == "Hat" or c.Name == "Body Colors" then
  926. c:remove()
  927. elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then
  928. c:remove()
  929. end
  930. end
  931. local BODY = {}
  932. for _, c in pairs(Character:GetDescendants()) do
  933. if c:IsA("BasePart") and c.Name ~= "Handle" then
  934. if c ~= RootPart and c ~= Torso and c ~= Head and c ~= RightArm and c ~= LeftArm and c ~= RightLeg and c ~= LeftLeg then
  935. c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0)
  936. end
  937. table.insert(BODY,{c,c.Parent,c.Material,c.Color,c.Transparency})
  938. elseif c:IsA("JointInstance") then
  939. table.insert(BODY,{c,c.Parent,nil,nil,nil})
  940. end
  941. end
  942. for e = 1, #BODY do
  943. if BODY[e] ~= nil then
  944. local STUFF = BODY[e]
  945. local PART = STUFF[1]
  946. local PARENT = STUFF[2]
  947. local MATERIAL = STUFF[3]
  948. local COLOR = STUFF[4]
  949. local TRANSPARENCY = STUFF[5]
  950. if PART.ClassName == "Part" and PART ~= RootPart then
  951. PART.Material = MATERIAL
  952. PART.Color = COLOR
  953. PART.Transparency = TRANSPARENCY
  954. end
  955. PART.AncestryChanged:Connect(function()
  956. PART.Parent = PARENT
  957. end)
  958. end
  959. end
  960. function refit()
  961. Character.Parent = workspace
  962. for e = 1, #BODY do
  963. if BODY[e] ~= nil then
  964. local STUFF = BODY[e]
  965. local PART = STUFF[1]
  966. local PARENT = STUFF[2]
  967. local MATERIAL = STUFF[3]
  968. local COLOR = STUFF[4]
  969. local TRANSPARENCY = STUFF[5]
  970. if PART.ClassName == "Part" and PART ~= RootPart then
  971. PART.Material = MATERIAL
  972. PART.Color = COLOR
  973. PART.Transparency = TRANSPARENCY
  974. end
  975. if PART.Parent ~= PARENT then
  976. Humanoid:remove()
  977. PART.Parent = PARENT
  978. Humanoid = IT("Humanoid",Character)
  979. end
  980. end
  981. end
  982. end
  983. local SKILLTEXTCOLOR = BRICKC"Lime green".Color
  984. local SKILLFONT = "Bodoni"
  985. local SKILLTEXTSIZE = 7
  986.  
  987. Humanoid.Died:connect(function()
  988. refit()
  989. end)
  990.  
  991. local SKILL1FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 1 Frame")
  992. local SKILL2FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 2 Frame")
  993. local SKILL3FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 3 Frame")
  994. local SKILL4FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 4 Frame")
  995. local SKILL5FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.365, 0, 0.70, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 5 Frame")
  996.  
  997. local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Radioactive Zap", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 1")
  998. local SKILL2TEXT = CreateLabel(SKILL2FRAME, "[B] Radioactive Thunder", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 2")
  999. local SKILL3TEXT = CreateLabel(SKILL3FRAME, "[C] Radioactive Death Circle", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 3")
  1000. local SKILL4TEXT = CreateLabel(SKILL4FRAME, "[V] Radioactive Wall", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 4")
  1001. local SKILL5TEXT = CreateLabel(SKILL5FRAME, "[X] Trap Key", SKILLTEXTCOLOR, SKILLTEXTSIZE, SKILLFONT, 0, 2, 0, "Text 5")
  1002.  
  1003. --//=================================\\
  1004. --|| DAMAGING
  1005. --\\=================================//
  1006.  
  1007. function ApplyAoE(POSITION,RANGE,FLING,BURN)
  1008. local CHILDREN = workspace:GetDescendants()
  1009. for index, CHILD in pairs(CHILDREN) do
  1010. if CHILD.ClassName == "Model" and CHILD ~= Character then
  1011. local HUM = CHILD:FindFirstChildOfClass("Humanoid")
  1012. if HUM then
  1013. local TORSO = CHILD:FindFirstChild("Torso") or CHILD:FindFirstChild("UpperTorso")
  1014. if TORSO then
  1015. if HUM.Health > 0 and (TORSO.Position - POSITION).Magnitude <= RANGE then
  1016. CHILD:BreakJoints()
  1017. if FLING ~= 0 then
  1018. for _, c in pairs(CHILD:GetChildren()) do
  1019. if c:IsA("BasePart") and c.Transparency == 0 then
  1020. if BURN == true then
  1021. Fire(c)
  1022. end
  1023. local bv = Instance.new("BodyVelocity")
  1024. bv.maxForce = Vector3.new(1e9, 1e9, 1e9)
  1025. bv.velocity = CF(POSITION,TORSO.Position).lookVector*FLING
  1026. bv.Parent = c
  1027. Debris:AddItem(bv,0.05)
  1028. end
  1029. end
  1030. end
  1031. end
  1032. end
  1033. end
  1034. end
  1035. end
  1036. end
  1037.  
  1038. --//=================================\\
  1039. --|| ATTACK FUNCTIONS AND STUFF
  1040. --\\=================================//
  1041.  
  1042. function Warden_Zap()
  1043. ATTACK = true
  1044. Rooted = false
  1045. local GYRO = IT("BodyGyro",RootPart)
  1046. GYRO.D = 750
  1047. GYRO.P = 20000
  1048. GYRO.MaxTorque = VT(0,40000000,0)
  1049. CreateSound(348663022,RightArm,1.5,2,false)
  1050. Pose("Cast1",0.8,1,true,GYRO)
  1051. local LightningTable = Lightning({Color = SKILLTEXTCOLOR, Start = RightArm.CFrame*CF(0,-1,0).p, End = Mouse.Hit.p, SegmentL = 2, Thickness = 0.2, DoesFade = true, Ignore = Character, MaxDist = 100, Branches = false})
  1052. local Hitpos = LightningTable.End
  1053. ApplyAoE(Hitpos,10,35)
  1054. WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
  1055. for i = 1, 4 do
  1056. WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,45,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  1057. end
  1058. Pose("Cast1",0.8,1,true)
  1059. GYRO:remove()
  1060. ATTACK = false
  1061. Rooted = false
  1062. end
  1063.  
  1064. function Warden_Thunder()
  1065. ATTACK = true
  1066. Rooted = false
  1067. local GYRO = IT("BodyGyro",RootPart)
  1068. GYRO.D = 750
  1069. GYRO.P = 20000
  1070. GYRO.MaxTorque = VT(0,40000000,0)
  1071. CreateSound(469345336,Torso,3,2,false)
  1072. Pose("Cast2",1.5,2,true,GYRO)
  1073. coroutine.resume(coroutine.create(function()
  1074. local FRAME = RootPart.CFrame
  1075. for i = 1, 25 do
  1076. local POS = FRAME*CF(MRANDOM(-17,17),0,-i*15)
  1077. local LightningTable = Lightning({Color = SKILLTEXTCOLOR, Start = POS*CF(0,85,0).p, End = POS*CF(0,-15,0).p, SegmentL = 3, Thickness = 0.4, DoesFade = true, Ignore = Character, MaxDist = 400, Branches = true})
  1078. local Hitpos = LightningTable.End
  1079. ApplyAoE(Hitpos,20,15)
  1080. WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(1,1,1)*15, Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = BOLTSOUNDS[MRANDOM(1,#BOLTSOUNDS)], SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
  1081. for i = 1, 4 do
  1082. WACKYEFFECT({Time = 15, EffectType = "Sphere", Size = VT(1,1,1), Size2 = VT(0,75,0), Transparency = 0, Transparency2 = 1, CFrame = CF(Hitpos)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  1083. end
  1084. wait(0.05)
  1085. end
  1086. end))
  1087. Pose("Cast2",1.5,0.7,true)
  1088. GYRO:remove()
  1089. ATTACK = false
  1090. Rooted = false
  1091. end
  1092.  
  1093. function Inferno_Ring()
  1094. ATTACK = true
  1095. Rooted = false
  1096. local GYRO = IT("BodyGyro",RootPart)
  1097. GYRO.D = 750
  1098. GYRO.P = 20000
  1099. GYRO.MaxTorque = VT(0,40000000,0)
  1100. local FIRE = IT("Model",Effects)
  1101. FIRE.Name = "Fire"
  1102. local MAIN = CreatePart(3, FIRE, "Neon", 0, 1, "Lime green", "Center", VT(0,0,0))
  1103. FIRE.PrimaryPart = MAIN
  1104. local FIRES = {}
  1105. for i = 1, 45 do
  1106. local PRT = CreatePart(3, FIRE, "Neon", 0, 1, "Lime green", "RingPart", VT(3,3,3))
  1107. PRT.CFrame = MAIN.CFrame*ANGLES(RAD(0),RAD((360/45)*i),RAD(0))*CF(0,0,20)
  1108. local F = Fire(PRT)
  1109. table.insert(FIRES,F)
  1110. end
  1111. repeat
  1112. FIRE:SetPrimaryPartCFrame(CF(Mouse.Hit.p))
  1113. Pose("Cast1",1.5,0.01,false,GYRO)
  1114. until HOLD == true
  1115. coroutine.resume(coroutine.create(function()
  1116. for i = 1, 4 do
  1117. ApplyAoE(MAIN.Position,21,-15,true)
  1118. CreateSound(463598785,MAIN,3,1,false)
  1119. for E = 1, #FIRES do
  1120. if FIRES[E] ~= nil then
  1121. FIRES[E].Acceleration = VT(0,300,0)
  1122. FIRES[E].Lifetime=NumberRange.new(0.35,1.5)
  1123. end
  1124. end
  1125. wait(0.3)
  1126. end
  1127. for E = 1, #FIRES do
  1128. if FIRES[E] ~= nil then
  1129. FIRES[E].Enabled = false
  1130. end
  1131. end
  1132. Debris:AddItem(FIRE,5)
  1133. end))
  1134. CreateSound(215395388,RightArm,3,2,false)
  1135. Pose("RightArmUp",1.5,0.5,true)
  1136. GYRO:remove()
  1137. ATTACK = false
  1138. Rooted = false
  1139. end
  1140.  
  1141. function Warden_Wall()
  1142. local HITFLOOR = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 8, Character)
  1143. if HITFLOOR ~= nil then
  1144. if HITFLOOR.Anchored == true then
  1145. local WALL = HITFLOOR:Clone()
  1146. WALL.Size = VT(45,45,5)
  1147. WALL.Parent = Effects
  1148. WALL.Name = "Wall"
  1149. WALL.CFrame = RootPart.CFrame*CF(0,-65/2.1,-5)*ANGLES(RAD(-15),RAD(0),RAD(0))
  1150. CreateSound(130972023,WALL,5,0.8,false)
  1151. ATTACK = true
  1152. Rooted = true
  1153. local HIT = WALL.Touched:Connect(function(hit)
  1154. if hit.Parent ~= Character then
  1155. hit:BreakJoints()
  1156. end
  1157. end)
  1158. coroutine.resume(coroutine.create(function()
  1159. WACKYEFFECT({Time = 35, EffectType = "Box", Size = WALL.Size, Size2 = WALL.Size*2, Transparency = 0, Transparency2 = 1, CFrame = WALL.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  1160. for i = 1, 90 do
  1161. Swait()
  1162. WALL.CFrame = WALL.CFrame*CF(0,0.5,0)
  1163. end
  1164. HIT:disconnect()
  1165. wait(5)
  1166. for i = 1, 46 do
  1167. Swait()
  1168. WALL.CFrame = WALL.CFrame*CF(0,-1,0)
  1169. end
  1170. WALL:remove()
  1171. end))
  1172. Pose("RightArmUp",1.5,1.2,true)
  1173. ATTACK = false
  1174. Rooted = false
  1175. end
  1176. end
  1177. end
  1178.  
  1179. function Prison_Key()
  1180. if Mouse.Target ~= nil then
  1181. if Mouse.Target.Parent ~= Character and Mouse.Target.Parent.Parent ~= Character and Mouse.Target.Parent:FindFirstChildOfClass("Humanoid") ~= nil then
  1182. local HUM = Mouse.Target.Parent:FindFirstChildOfClass("Humanoid")
  1183. local TORSO = HUM.Parent:FindFirstChild("Torso") or HUM.Parent:FindFirstChild("UpperTorso")
  1184. local GYRO = IT("BodyGyro",RootPart)
  1185. GYRO.D = 750
  1186. GYRO.P = 20000
  1187. GYRO.MaxTorque = VT(0,40000000,0)
  1188. local grav = Instance.new("BodyPosition",TORSO)
  1189. grav.D = 15
  1190. grav.P = 20000
  1191. grav.maxForce = Vector3.new(math.huge,math.huge,math.huge)
  1192. grav.position = TORSO.Position
  1193. local GYRO2 = IT("BodyGyro",TORSO)
  1194. GYRO2.D = 750
  1195. GYRO2.P = 20000
  1196. GYRO2.MaxTorque = VT(0,40000000,0)
  1197. GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
  1198. grav.Name = "Jail"
  1199. local LOCKPARTS = {}
  1200. ATTACK = true
  1201. Rooted = false
  1202. local LOCK = IT("Model",Effects)
  1203. LOCK.Name = "Lock"
  1204. local LOCK2 = IT("Model",LOCK)
  1205. LOCK2.Name = "Metal"
  1206. --CREATE LOCK--
  1207. local BASE = CreatePart(3, LOCK, "Glass", 0, 0, "Gold", "Keylock", VT(3, 2.5, 1))
  1208. LOCK.PrimaryPart = BASE
  1209. BASE.CFrame = CF(TORSO.Position,RootPart.Position)*CF(0,0,-4)
  1210. local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "Gold", "Keylock", VT(3, 1, 3))
  1211. PRT.CFrame = BASE.CFrame*CF(0,-1.25,0)*ANGLES(RAD(90),RAD(0),RAD(0))
  1212. MakeForm(PRT,"Cyl")
  1213. local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "White", "Hole", VT(1, 1, 1))
  1214. PRT.Color = C3(0,0,0)
  1215. PRT.CFrame = BASE.CFrame*CF(0,0.3,-0.01)*ANGLES(RAD(90),RAD(0),RAD(0))
  1216. MakeForm(PRT,"Cyl")
  1217. local PRT = CreatePart(3, LOCK, "Glass", 0, 0, "White", "Hole", VT(0.5, 1, 1))
  1218. PRT.Color = C3(0,0,0)
  1219. PRT.CFrame = BASE.CFrame*CF(0,-0.2,-0.01)
  1220. for i = 1, 45 do
  1221. local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5))
  1222. PRT.CFrame = BASE.CFrame*CF(0,2,0)*ANGLES(RAD(0),RAD(0),RAD(-90+(360/90*i)))*CF(0,1,0)
  1223. end
  1224. local PRT = CreatePart(3, LOCK2, "Glass", 0, 0, "Grey", "Keylock", VT(0.5, 0.5, 0.5))
  1225. PRT.CFrame = BASE.CFrame*CF(0,1.5,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0)
  1226. LOCK2.PrimaryPart = PRT
  1227. ---------------
  1228. local CHILDREN = LOCK:GetDescendants()
  1229. for index, CHILD in pairs(CHILDREN) do
  1230. if CHILD:IsA("BasePart") then
  1231. CHILD.Transparency = 1
  1232. end
  1233. end
  1234. for i = 1, 75 do
  1235. LOCK:SetPrimaryPartCFrame(CF(TORSO.Position,RootPart.Position)*CF(0,0,-4))
  1236. Swait()
  1237. GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
  1238. GYRO.cframe = CF(RootPart.Position,TORSO.Position)
  1239. local CHILDREN = LOCK:GetDescendants()
  1240. for index, CHILD in pairs(CHILDREN) do
  1241. if CHILD:IsA("BasePart") then
  1242. CHILD.Transparency = CHILD.Transparency - 1/75
  1243. end
  1244. end
  1245. end
  1246. HUM.DisplayDistanceType = "None"
  1247. local KEY = IT("Model",Effects)
  1248. KEY.Name = "Key"
  1249. --CREATE KEY--
  1250. local KBASE = CreatePart(3, KEY, "Neon", 0, 0, "Lime green", "KeyBase", VT(0.1, 1, 0.1),false)
  1251. KEY.PrimaryPart = KBASE
  1252. KBASE.CFrame = RightArm.CFrame*CF(0,-2.1,0)*ANGLES(RAD(0),RAD(90),RAD(0))
  1253. local WLD = weldBetween(RightArm,KBASE)
  1254. for i = 1, 45 do
  1255. local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Lime green", "Key", VT(0.1, 0.1, 0.1),false)
  1256. PRT.CFrame = KBASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD((360/45*i)))*CF(0,0.25,0)
  1257. weldBetween(KBASE,PRT)
  1258. end
  1259. local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Lime green", "Key", VT(0.3, 0.1, 0.1),false)
  1260. PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.45,0)
  1261. weldBetween(KBASE,PRT)
  1262. local PRT = CreatePart(3, KEY, "Neon", 0, 0, "Lime green", "Key", VT(0.3, 0.1, 0.1),false)
  1263. PRT.CFrame = KBASE.CFrame*CF(-0.15,-0.25,0)
  1264. weldBetween(KBASE,PRT)
  1265. --------------
  1266. Rooted = true
  1267. Pose("Prepare key",1.5,1.2,false,GYRO,TORSO)
  1268. coroutine.resume(coroutine.create(function()
  1269. for i = 1, 10 do
  1270. Swait()
  1271. GYRO2.cframe = CF(TORSO.Position,RootPart.Position)
  1272. GYRO.cframe = CF(RootPart.Position,TORSO.Position)
  1273. end
  1274. CreateSound(1149318312,BASE,5,1,false)
  1275. CreateSound(160772554,BASE,3,1,false)
  1276. LOCK2:SetPrimaryPartCFrame(BASE.CFrame*CF(0,0.8,0)*ANGLES(RAD(0),RAD(0),RAD(90))*CF(0,1,0))
  1277. for i = 1, 4 do
  1278. WACKYEFFECT({Time = 35, EffectType = "Crystal", Size = VT(1,1,1), Size2 = VT(0,15,0), Transparency = 0, Transparency2 = 1, CFrame = BASE.CFrame*CF(1,1.45,0)*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
  1279. end
  1280. WACKYEFFECT({Time = 35, EffectType = "Sphere", Size = VT(0,0,0), Size2 = VT(1,1,1)*25, Transparency = 0, Transparency2 = 1, CFrame = TORSO.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Lime green".Color, SoundID = nil, SoundPitch = MRANDOM(8,12)/10, SoundVolume = 5})
  1281. wait(1)
  1282. TORSO.Parent.Parent = LOCK
  1283. for i = 1, 75 do
  1284. Swait()
  1285. local CHILDREN = KEY:GetDescendants()
  1286. for index, CHILD in pairs(CHILDREN) do
  1287. if CHILD:IsA("BasePart") then
  1288. CHILD.Transparency = i/25
  1289. end
  1290. end
  1291. local CHILDREN = LOCK:GetDescendants()
  1292. for index, CHILD in pairs(CHILDREN) do
  1293. if CHILD:IsA("BasePart") and CHILD.Name ~= "HumanoidRootPart" then
  1294. CHILD.Transparency = CHILD.Transparency + 1/75
  1295. elseif CHILD.ClassName == "Decal" then
  1296. CHILD.Transparency = CHILD.Transparency + 1/75
  1297. end
  1298. end
  1299. end
  1300. TORSO.Parent:ClearAllChildren()
  1301. KEY:remove()
  1302. LOCK:remove()
  1303. end))
  1304. Pose("Turn key",0.8,1.2,false,GYRO,TORSO)
  1305. GYRO:remove()
  1306. ATTACK = false
  1307. Rooted = false
  1308. end
  1309. end
  1310. end
  1311.  
  1312. function Hat()
  1313. ATTACK = true
  1314. Rooted = false
  1315. Pose("Taunt",0.4,1.2,false)
  1316. ATTACK = false
  1317. Rooted = false
  1318. end
  1319.  
  1320. --//=================================\\
  1321. --|| ASSIGN THINGS TO KEYS
  1322. --\\=================================//
  1323.  
  1324. function MouseDown(Mouse)
  1325. HOLD = true
  1326. if ATTACK == false then
  1327. end
  1328. end
  1329.  
  1330. function MouseUp(Mouse)
  1331. HOLD = false
  1332. end
  1333.  
  1334. function KeyDown(Key)
  1335. KEYHOLD = true
  1336. if Key == "z" and ATTACK == false then
  1337. Warden_Zap()
  1338. end
  1339.  
  1340. if Key == "b" and ATTACK == false then
  1341. Warden_Thunder()
  1342. end
  1343.  
  1344. if Key == "c" and ATTACK == false then
  1345. Inferno_Ring()
  1346. end
  1347.  
  1348. if Key == "v" and ATTACK == false then
  1349. Warden_Wall()
  1350. end
  1351.  
  1352. if Key == "x" and ATTACK == false then
  1353. Prison_Key()
  1354. end
  1355.  
  1356. if Key == "t" and ATTACK == false then
  1357. Hat()
  1358. end
  1359. end
  1360.  
  1361. function KeyUp(Key)
  1362. KEYHOLD = false
  1363. end
  1364.  
  1365. Mouse.Button1Down:connect(function(NEWKEY)
  1366. MouseDown(NEWKEY)
  1367. end)
  1368. Mouse.Button1Up:connect(function(NEWKEY)
  1369. MouseUp(NEWKEY)
  1370. end)
  1371. Mouse.KeyDown:connect(function(NEWKEY)
  1372. KeyDown(NEWKEY)
  1373. end)
  1374. Mouse.KeyUp:connect(function(NEWKEY)
  1375. KeyUp(NEWKEY)
  1376. end)
  1377.  
  1378. --//=================================\\
  1379. --\\=================================//
  1380.  
  1381.  
  1382. function unanchor()
  1383. if UNANCHOR == true then
  1384. g = Character:GetChildren()
  1385. for i = 1, #g do
  1386. if g[i].ClassName == "Part" then
  1387. g[i].Anchored = false
  1388. end
  1389. end
  1390. end
  1391. end
  1392.  
  1393.  
  1394. --//=================================\\
  1395. --|| WRAP THE WHOLE SCRIPT UP
  1396. --\\=================================//
  1397.  
  1398. Humanoid.Changed:connect(function(Jump)
  1399. if Jump == "Jump" and (Disable_Jump == true) then
  1400. Humanoid.Jump = false
  1401. end
  1402. end)
  1403.  
  1404. while true do
  1405. Swait()
  1406. script.Parent = WEAPONGUI
  1407. Humanoid.Parent = Character
  1408. if Humanoid then
  1409. local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION)
  1410. IDLEANIMATION:Play()
  1411. end
  1412. if ANIMATE.Parent == Character then
  1413. ANIMATE:Destroy()
  1414. end
  1415. SINE = SINE + CHANGE
  1416. local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude
  1417. local TORSOVERTICALVELOCITY = RootPart.Velocity.y
  1418. Humanoid.HipHeight = 1
  1419. Humanoid.Name = "Radioactive"
  1420. Humanoid.PlatformStand = false
  1421. if PLAYMAINANIM == true then
  1422. if TORSOVELOCITY < 1 then
  1423. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(35 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1424. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(25 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1425. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.35 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(35), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(5 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1426. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.35 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(35), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-5 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1427. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(25 - 2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1428. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(25 - 2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1429. elseif TORSOVELOCITY > 1 then
  1430. RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(25 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1431. Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(-25 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-5 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed)
  1432. RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.35 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(-25), RAD(0 - 2.5 * SIN(SINE / 12)), RAD(15 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed)
  1433. LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.35 + 0.25 * COS(SINE / 12), 0) * ANGLES(RAD(-25), RAD(0 + 2.5 * SIN(SINE / 12)), RAD(-15 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed)
  1434. RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-25 - 2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 5.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1435. LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed)
  1436. end
  1437. end
  1438. unanchor()
  1439. Humanoid.MaxHealth = "inf"
  1440. Humanoid.Health = "inf"
  1441. if Rooted == false then
  1442. Disable_Jump = false
  1443. Humanoid.WalkSpeed = Speed
  1444. elseif Rooted == true then
  1445. Disable_Jump = true
  1446. Humanoid.WalkSpeed = 0
  1447. end
  1448. for _, c in pairs(Character:GetChildren()) do
  1449. if c.ClassName == "Part" and c.Name ~= "Eye" then
  1450. c.Material = "Neon"
  1451. if c:FindFirstChildOfClass("ParticleEmitter") then
  1452. c:FindFirstChildOfClass("ParticleEmitter"):remove()
  1453. end
  1454. c.Color = C3(1,1,1)
  1455. if c == Head then
  1456. if c:FindFirstChild("face") then
  1457. c.face:remove()
  1458. end
  1459. end
  1460. elseif c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.ClassName == "Hat" or c.Name == "Body Colors" then
  1461. c:remove()
  1462. elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then
  1463. c:remove()
  1464. end
  1465. end
  1466. sick.SoundId = "rbxassetid://262067268"
  1467. sick.Looped = true
  1468. sick.Volume = 1.0
  1469. sick:Resume()
  1470. sick.Parent = Torso
  1471. refit()
  1472. if Head:FindFirstChildOfClass("Sound") then
  1473. Head:FindFirstChildOfClass("Sound"):remove()
  1474. end
  1475. end
  1476.  
  1477. --//=================================\\
  1478. --\\=================================//
  1479.  
  1480.  
  1481.  
  1482.  
  1483.  
  1484. --//====================================================\\--
  1485. --|| END OF SCRIPT
  1486. --\\====================================================//--
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement