SHARE
TWEET

Lunatic Warden (FONT DEFINETLY FIXED!)

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