Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --https://github.com/Mokiros/roblox-FE-compatibility
- if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
- local Player,Mouse,mouse,UserInputService,ContextActionService = owner
- local RealPlayer = Player
- do print("FE Compatibility code by Mokiros")local a=RealPlayer;script.Parent=a.Character;local b=Instance.new("RemoteEvent")b.Name="UserInput_Event"local function c()local d={_fakeEvent=true,Functions={},Connect=function(self,e)table.insert(self.Functions,e)end}d.connect=d.Connect;return d end;local f={Target=nil,Hit=CFrame.new(),KeyUp=c(),KeyDown=c(),Button1Up=c(),Button1Down=c(),Button2Up=c(),Button2Down=c()}local g={InputBegan=c(),InputEnded=c()}local CAS={Actions={},BindAction=function(self,h,i,j,...)CAS.Actions[h]=i and{Name=h,Function=i,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function k(self,l,...)local d=f[l]if d and d._fakeEvent then for m,e in pairs(d.Functions)do e(...)end end end;f.TrigEvent=k;g.TrigEvent=k;b.OnServerEvent:Connect(function(n,o)if n~=a then return end;f.Target=o.Target;f.Hit=o.Hit;if not o.isMouse then local p=o.UserInputState==Enum.UserInputState.Begin;if o.UserInputType==Enum.UserInputType.MouseButton1 then return f:TrigEvent(p and"Button1Down"or"Button1Up")end;if o.UserInputType==Enum.UserInputType.MouseButton2 then return f:TrigEvent(p and"Button2Down"or"Button2Up")end;for m,d in pairs(CAS.Actions)do for m,q in pairs(d.Keys)do if q==o.KeyCode then d.Function(d.Name,o.UserInputState,o)end end end;f:TrigEvent(p and"KeyDown"or"KeyUp",o.KeyCode.Name:lower())g:TrigEvent(p and"InputBegan"or"InputEnded",o,false)end end)b.Parent=NLS([==[local a=game:GetService("Players").LocalPlayer;local b=script:WaitForChild("UserInput_Event")local c=a:GetMouse()local d=game:GetService("UserInputService")local e=function(f,g)if g then return end;b:FireServer({KeyCode=f.KeyCode,UserInputType=f.UserInputType,UserInputState=f.UserInputState,Hit=c.Hit,Target=c.Target})end;d.InputBegan:Connect(e)d.InputEnded:Connect(e)local h,i;while wait(1/30)do if h~=c.Hit or i~=c.Target then h,i=c.Hit,c.Target;b:FireServer({isMouse=true,Target=i,Hit=h})end end]==],Player.Character)local r=game;local s={__index=function(self,q)local t=rawget(self,"_RealService")if t then return typeof(t[q])=="function"and function(m,...)return t[q](t,...)end or t[q]end end,__newindex=function(self,q,u)local t=rawget(self,"_RealService")if t then t[q]=u end end}local function v(d,w)d._RealService=typeof(w)=="string"and r:GetService(w)or w;return setmetatable(d,s)end;local x={GetService=function(self,t)return rawget(self,t)or r:GetService(t)end,Players=v({LocalPlayer=v({GetMouse=function(self)return f end},Player)},"Players"),UserInputService=v(g,"UserInputService"),ContextActionService=v(CAS,"ContextActionService"),RunService=v({_btrs={},RenderStepped=r:GetService("RunService").Heartbeat,BindToRenderStep=function(self,h,m,i)self._btrs[h]=self.Heartbeat:Connect(i)end,UnbindFromRenderStep=function(self,h)self._btrs[h]:Disconnect()end},"RunService")}rawset(x.Players,"localPlayer",x.Players.LocalPlayer)x.service=x.GetService;v(x,game)game,owner=x,x.Players.LocalPlayer end wait(1)
- player = game.Players.LocalPlayer
- char = player.Character
- head = char.Head
- torso = char.Torso
- t = torso
- hum = char.Humanoid
- newWeld = function(wp0, wp1, wc0x, wc0y, wc0z)
- local wld = Instance.new("Weld", wp0)
- wld.Part0 = wp0
- wld.Part1 = wp1
- wld.C0 = CFrame.new(wc0x, wc0y, wc0z)
- if wp1.Name == "Head" then
- wld.Name="Neck"
- end
- return wld
- end
- for i,v in pairs (char:GetChildren()) do
- if v:IsA("Hat") or v:IsA("Accessory") then
- v:Destroy()
- end
- end
- Horn = Instance.new("Part")
- ParticleEmitter1 = Instance.new("ParticleEmitter")
- ParticleEmitter2 = Instance.new("ParticleEmitter")
- Horn.Name = "Horns"
- Horn.Parent = char
- Horn.Size = Vector3.new(0.0500000007, 0.0500000007, 0.0500000007)
- Horn.BottomSurface = Enum.SurfaceType.Smooth
- Horn.TopSurface = Enum.SurfaceType.Smooth
- Horn.CFrame = head.CFrame
- ParticleEmitter1.Parent = Horn
- ParticleEmitter1.Transparency = NumberSequence.new(1,0.75,1)
- ParticleEmitter1.Rotation = NumberRange.new(-180, 180)
- ParticleEmitter1.Size = NumberSequence.new(0.8,0)
- ParticleEmitter1.LockedToPart=true
- ParticleEmitter2.LockedToPart=true
- ParticleEmitter1.Color = ColorSequence.new(Color3.new(1, 0, 0),Color3.new(1, 0, 0))
- ParticleEmitter1.LightEmission = 0.69999998807907
- ParticleEmitter1.Texture = "rbxassetid://170257522"
- ParticleEmitter1.EmissionDirection = Enum.NormalId.Left
- ParticleEmitter1.ZOffset = 0.5
- ParticleEmitter1.Acceleration = Vector3.new(0, 4, 0)
- ParticleEmitter1.Lifetime = NumberRange.new(1.1)
- ParticleEmitter1.Rate = 100
- ParticleEmitter1.RotSpeed = NumberRange.new(-18, 18)
- ParticleEmitter1.Color = ColorSequence.new(Color3.new(1, 0, 0),Color3.new(1, 0, 0))
- ParticleEmitter2.Parent = Horn
- ParticleEmitter2.Transparency = NumberSequence.new(1,0.75,1)
- ParticleEmitter2.Rotation = NumberRange.new(-180, 180)
- ParticleEmitter2.Size = NumberSequence.new(0.8,0)
- ParticleEmitter2.Color = ColorSequence.new(Color3.new(1, 0, 0),Color3.new(1, 0, 0))
- ParticleEmitter2.LightEmission = 0.69999998807907
- ParticleEmitter2.Texture = "rbxassetid://170257522"
- ParticleEmitter2.EmissionDirection = Enum.NormalId.Right
- ParticleEmitter2.ZOffset = 0.5
- ParticleEmitter2.Acceleration = Vector3.new(0, 4, 0)
- ParticleEmitter2.Lifetime = NumberRange.new(1.1)
- ParticleEmitter2.Rate = 100
- ParticleEmitter2.RotSpeed = NumberRange.new(-18, 18)
- ParticleEmitter2.Color = ColorSequence.new(Color3.new(1, 0, 0),Color3.new(1, 0, 0))
- Hat0 = Instance.new("Accessory")
- Handle = Instance.new("Part")
- SpecialMesh2 = Instance.new("SpecialMesh")
- Hat0.Name = "DarkKnightHood"
- Hat0.AttachmentPos = Vector3.new(0, 1.63999999, -0.00999999978)
- Handle.Name = "Handle"
- Handle.Parent = Hat0
- Handle.Rotation = Vector3.new(-13.3299999, -0.25999999, -0.0799999982)
- Handle.CanCollide = false
- Handle.FormFactor = Enum.FormFactor.Custom
- Handle.Size = Vector3.new(2.20000029, 3.80000067, 1.36999905)
- Handle.CFrame = CFrame.new(-34.6326752, 7.71574116, 8.64290714, 0.999988198, 0.00145675475, -0.00462479144, -0.000351635739, 0.973076522, 0.23047556, 0.0048360303, -0.230471551, 0.973067045)
- Handle.BottomSurface = Enum.SurfaceType.Smooth
- Handle.TopSurface = Enum.SurfaceType.Smooth
- Handle.Position = Vector3.new(-34.6326752, 7.71574116, 8.64290714)
- Handle.Orientation = Vector3.new(-13.3299999, -0.269999981, -0.0199999996)
- SpecialMesh0 = Instance.new("SpecialMesh")
- SpecialMesh0.Parent = Handle
- SpecialMesh0.MeshId = "rbxassetid://391929045"
- SpecialMesh0.Offset = Vector3.new(0, 1, 0.25)
- SpecialMesh0.Scale = Vector3.new(2.0999999, 2.0999999, 2.0999999)
- SpecialMesh0.TextureId = "rbxassetid://391929221"
- SpecialMesh0.MeshType = Enum.MeshType.FileMesh
- SpecialMesh0.Scale = Vector3.new(2.0999999, 2.0999999, 2.0999999)
- Accessory0 = Instance.new("Accessory")
- Part1 = Instance.new("Part")
- SpecialMesh2 = Instance.new("SpecialMesh")
- Attachment3 = Instance.new("Attachment")
- Vector3Value4 = Instance.new("Vector3Value")
- Weld5 = Instance.new("Weld")
- Accessory0.Name = "SilverthornAntlers"
- Accessory0.AttachmentPos = Vector3.new(0, -0.75, 0.200000003)
- H2 = Part1
- Part1.Name = "Handle"
- Part1.Parent = Accessory0
- Part1.Rotation = Vector3.new(-13.3299999, -0.25999999, -0.0799999982)
- Part1.CanCollide = false
- Part1.Locked = true
- Part1.FormFactor = Enum.FormFactor.Plate
- Part1.Size = Vector3.new(1, 2, 1)
- Part1.CFrame = CFrame.new(-34.6282234, 10.763752, 7.88773584, 0.999988198, 0.00145675475, -0.00462479144, -0.000351635739, 0.973076522, 0.23047556, 0.0048360303, -0.230471551, 0.973067045)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Part1.Position = Vector3.new(-34.6282234, 10.763752, 7.88773584)
- Part1.Orientation = Vector3.new(-13.3299999, -0.269999981, -0.0199999996)
- SpecialMesh2.Parent = Part1
- SpecialMesh2.MeshId = "http://www.roblox.com/asset/?id=1271547"
- SpecialMesh2.Scale = Vector3.new(2, 2, 2)
- SpecialMesh2.TextureId = "http://www.roblox.com/asset/?id=9254947"
- SpecialMesh2.MeshType = Enum.MeshType.FileMesh
- SpecialMesh2.Scale = Vector3.new(2, 2, 2)
- Attachment3.Name = "HatAttachment"
- Attachment3.Parent = Part1
- Attachment3.Rotation = Vector3.new(2.37457894e-14, -1.86912034e-22, -4.50996595e-07)
- Attachment3.CFrame = CFrame.new(8.65838956e-09, -0.650000095, 0.199727759, 1, 7.87137555e-09, -3.26223034e-24, -7.87137555e-09, 1, -4.1444221e-16, 0, 4.1444221e-16, 1)
- Attachment3.Position = Vector3.new(8.65838956e-09, -0.650000095, 0.199727759)
- Attachment3.Axis = Vector3.new(1, -7.87137555e-09, 0)
- Attachment3.Orientation = Vector3.new(2.37457894e-14, -1.86912034e-22, -4.50996595e-07)
- Vector3Value4.Name = "OriginalSize"
- Vector3Value4.Parent = Part1
- Vector3Value4.Value = Vector3.new(1, 2, 1)
- spawn(function()
- wait(0.2)
- Hat0.Parent=char
- -- newWeld(head,Handle,0,0,0)
- Accessory0.Parent=char
- -- newWeld(head,H2,0,0,0)
- end)
- shirt = char:FindFirstChild("Shirt")
- pants = char:FindFirstChild("Pants")
- sg = char:FindFirstChild("Shirt Graphic")
- if shirt then shirt:Destroy() end
- if pants then pants:Destroy() end
- if sg then sg:Destroy() end
- shirt = Instance.new("Shirt",char)
- pants = Instance.new("Pants",char)
- shirt.ShirtTemplate = "rbxassetid://767426316"
- pants.PantsTemplate = "rbxassetid://201888161"
- char['Torso'].Size = Vector3.new(4,4,2)
- char['Right Arm'].Size = Vector3.new(2,4,2)
- char['Left Arm'].Size = Vector3.new(2,4,2)
- char['Right Leg'].Size = Vector3.new(2,4,2)
- char['Left Leg'].Size = Vector3.new(2,4,2)
- char['Head'].Size = Vector3.new(4,2,2)
- local we = Instance.new("Weld",Horn)
- we.Part0 = head
- we.Part1 = Horn
- spawn(function()
- local Ang = CFrame.Angles --[Storing these as variables so I dont have to type them out.]
- local aSin = math.asin
- local aTan = math.atan
- --[Constants]:
- local Cam = game.Workspace.CurrentCamera
- local Plr = game.Players.LocalPlayer
- local Mouse = Plr:GetMouse()
- local Body = Plr.Character or Plr.CharacterAdded:wait()
- local Head = Body:WaitForChild("Head")
- local Hum = Body:WaitForChild("Humanoid")
- local Core = Body:WaitForChild("HumanoidRootPart")
- local IsR6 = (Hum.RigType.Value==0) --[Checking if the player is using R15 or R6.]
- local Trso = (IsR6 and Body:WaitForChild("Torso")) or Body:WaitForChild("UpperTorso")
- local Neck = (IsR6 and Trso:WaitForChild("Neck")) or Head:WaitForChild("Neck") --[Once we know the Rig, we know what to find.]
- local Waist = (not IsR6 and Trso:WaitForChild("Waist")) --[R6 doesn't have a waist joint, unfortunately.]
- local MseGuide = false
- local TurnCharacterToMouse = false
- local HeadHorFactor = 1
- local HeadVertFactor = 0.6
- local BodyHorFactor = 0.5
- local BodyVertFactor = 0.4
- local UpdateSpeed = 0.5
- local NeckOrgnC0 = Neck.C0 --[Get the base C0 to manipulate off of.]
- local WaistOrgnC0 = (not IsR6 and Waist.C0) --[Get the base C0 to manipulate off of.]
- --[Setup]:
- -- Activation]:
- if TurnCharacterToMouse == true then
- MseGuide = true
- HeadHorFactor = 0
- BodyHorFactor = 0
- end
- game:GetService("RunService").RenderStepped:Connect(function()
- local CamCF = Cam.CoordinateFrame
- if ((IsR6 and Body["Torso"]) or Body["UpperTorso"])~=nil and Body["Head"]~=nil then --[Check for the Torso and Head...]
- local TrsoLV = Trso.CFrame.lookVector
- local HdPos = Head.CFrame.p
- if IsR6 and Neck or Neck and Waist then --[Make sure the Neck still exists.]
- if Cam.CameraSubject:IsDescendantOf(Body) or Cam.CameraSubject:IsDescendantOf(Plr) then
- local Dist = nil;
- local Diff = nil;
- if not MseGuide then --[If not tracking the Mouse then get the Camera.]
- Dist = (Head.CFrame.p-CamCF.p).magnitude
- Diff = Head.CFrame.Y-CamCF.Y
- if not IsR6 then --[R6 and R15 Neck rotation C0s are different; R15: X axis inverted and Z is now the Y.]
- Neck.C0 = Neck.C0:lerp(NeckOrgnC0*Ang((aSin(Diff/Dist)*HeadVertFactor), -(((HdPos-CamCF.p).Unit):Cross(TrsoLV)).Y*HeadHorFactor, 0), UpdateSpeed/2)
- Waist.C0 = Waist.C0:lerp(WaistOrgnC0*Ang((aSin(Diff/Dist)*BodyVertFactor), -(((HdPos-CamCF.p).Unit):Cross(TrsoLV)).Y*BodyHorFactor, 0), UpdateSpeed/2)
- else --[R15s actually have the properly oriented Neck CFrame.]
- Neck.C0 = Neck.C0:lerp(NeckOrgnC0*Ang(-(aSin(Diff/Dist)*HeadVertFactor), 0, -(((HdPos-CamCF.p).Unit):Cross(TrsoLV)).Y*HeadHorFactor),UpdateSpeed/2)
- end
- else
- local Point = Mouse.Hit.p
- Dist = (Head.CFrame.p-Point).magnitude
- Diff = Head.CFrame.Y-Point.Y
- if not IsR6 then
- Neck.C0 = Neck.C0:lerp(NeckOrgnC0*Ang(-(aTan(Diff/Dist)*HeadVertFactor), (((HdPos-Point).Unit):Cross(TrsoLV)).Y*HeadHorFactor, 0), UpdateSpeed/2)
- Waist.C0 = Waist.C0:lerp(WaistOrgnC0*Ang(-(aTan(Diff/Dist)*BodyVertFactor), (((HdPos-Point).Unit):Cross(TrsoLV)).Y*BodyHorFactor, 0), UpdateSpeed/2)
- else
- Neck.C0 = Neck.C0:lerp(NeckOrgnC0*Ang((aTan(Diff/Dist)*HeadVertFactor), 0, (((HdPos-Point).Unit):Cross(TrsoLV)).Y*HeadHorFactor), UpdateSpeed/2)
- end
- end
- end
- end
- end
- if TurnCharacterToMouse == true then
- Hum.AutoRotate = false
- Core.CFrame = Core.CFrame:lerp(CFrame.new(Core.Position, Vector3.new(Mouse.Hit.p.x, Core.Position.Y, Mouse.Hit.p.z)), UpdateSpeed / 2)
- else
- Hum.AutoRotate = true
- end
- end)
- end)
- larm = char['Left Arm']
- rarm = char['Right Arm']
- lleg = char['Left Leg']
- rleg = char['Right Leg']
- hed = char['Head']
- root = char['HumanoidRootPart']
- LeftArm = newWeld(torso, larm, -1.5, 1, 0)
- RightArm = newWeld(torso, rarm, 1.5, 1, 0)
- Head = newWeld(torso, hed, 0, 3, 0)
- LeftLeg = newWeld(torso, lleg, -1, -2, 0)
- RightLeg = newWeld(torso, rleg, 1, -2, 0)
- Torso = newWeld(root, torso, 0, -2, 0)
- Torso.C0 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
- Torso.C1 = CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
- LeftLeg.C0 = CFrame.new(-1, -1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08)
- LeftLeg.C1 = CFrame.new(-0.5, 1, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08)
- RightLeg.C0 = CFrame.new(1, -1, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08)
- RightLeg.C1 = CFrame.new(0.5, 1, 0, -4.37113883e-08, 0, 1, 0, 0.99999994, 0, -1, 0, -4.37113883e-08)
- LeftArm.C0 = CFrame.new(-1, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08)
- LeftArm.C1 = CFrame.new(0.5, 0.5, 0, -4.37113883e-08, 0, -1, 0, 0.99999994, 0, 1, 0, -4.37113883e-08)
- RightArm.C0 = CFrame.new(1, 0.5, 0, -4.37113883e-08, 0, 1, -0, 0.99999994, 0, -1, 0, -4.37113883e-08)
- RightArm.C1 = CFrame.new(-0.5, 0.5, 0, -4.37113883e-08, 0, 1, 0, 0.99999994, 0, -1, 0, -4.37113883e-08)
- Head.C0 = CFrame.new(0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
- Head.C1 = CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, 0)
- function createSound(id,speed,vol,looped,parent)
- local sound = Instance.new("Sound",head)
- sound.SoundId = id
- sound.PlaybackSpeed = speed
- if parent then sound.Parent = parent end
- if vol then sound.Volume = vol end
- if looped then sound.Looped = looped end
- sound:Play()
- spawn(function()
- if looped == false then
- wait(sound.TimeLength)
- sound:Destroy()
- end
- end)
- end
- --BGM
- createSound('rbxassetid://1337508713',1,1,true)
- --Delete the animator
- humanoid = char:FindFirstChildOfClass("Humanoid")
- do
- char:WaitForChild("Animate"):Destroy()
- humanoid:WaitForChild("Animator"):Destroy()
- end
- pose = "Idle"
- --Pose updater
- spawn(function()
- while wait() do
- local velocity = char.HumanoidRootPart.Velocity
- local X = (char.HumanoidRootPart.Velocity).magnitude
- local vY = velocity.Y
- if vY > 0.8 then
- pose = "Jumping"
- elseif vY<-0.8 then
- pose = "Falling"
- end
- if X > 0.8 then
- pose = "Running"
- end
- if humanoid.MoveDirection == Vector3.new(0,0,0) then
- pose = "Idle"
- end
- if X < 0.3 and vY < 0.3 and X > -0.3 and vY > -0.3 then
- pose = "Idle"
- end
- end
- end)
- --Spell hand
- Spells = Instance.new("Model")
- Part1 = Instance.new("Part")
- SurfaceGui2 = Instance.new("SurfaceGui")
- ImageLabel3 = Instance.new("ImageLabel")
- SurfaceGui4 = Instance.new("SurfaceGui")
- ImageLabel5 = Instance.new("ImageLabel")
- SurfaceGui6 = Instance.new("SurfaceGui")
- ImageLabel7 = Instance.new("ImageLabel")
- SurfaceGui8 = Instance.new("SurfaceGui")
- ImageLabel9 = Instance.new("ImageLabel")
- Weld10 = Instance.new("Weld")
- Part11 = Instance.new("Part")
- SurfaceGui12 = Instance.new("SurfaceGui")
- ImageLabel13 = Instance.new("ImageLabel")
- SurfaceGui14 = Instance.new("SurfaceGui")
- ImageLabel15 = Instance.new("ImageLabel")
- SurfaceGui16 = Instance.new("SurfaceGui")
- ImageLabel17 = Instance.new("ImageLabel")
- SurfaceGui18 = Instance.new("SurfaceGui")
- ImageLabel19 = Instance.new("ImageLabel")
- Weld20 = Instance.new("Weld")
- Part21 = Instance.new("Part")
- SurfaceGui22 = Instance.new("SurfaceGui")
- ImageLabel23 = Instance.new("ImageLabel")
- SurfaceGui24 = Instance.new("SurfaceGui")
- ImageLabel25 = Instance.new("ImageLabel")
- SurfaceGui26 = Instance.new("SurfaceGui")
- ImageLabel27 = Instance.new("ImageLabel")
- SurfaceGui28 = Instance.new("SurfaceGui")
- ImageLabel29 = Instance.new("ImageLabel")
- Weld30 = Instance.new("Weld")
- Part31 = Instance.new("Part")
- Weld32 = Instance.new("Weld")
- Spells.Name = "Spells"
- Spells.Parent = mas
- Spells.PrimaryPart = Part31
- Part1.Name = "Spell3"
- Part1.Parent = Spells
- Part1.Transparency = 1
- Part1.Size = Vector3.new(3, 0.0500000007, 3)
- Part1.CFrame = CFrame.new(-2.00700021, 1.75291348, 1.921, 1, 0, 0, 0, 0.999999642, 0, 0, 0, 1)
- Part1.BottomSurface = Enum.SurfaceType.Smooth
- Part1.TopSurface = Enum.SurfaceType.Smooth
- Part1.Position = Vector3.new(-2.00700021, 1.75291348, 1.921)
- SurfaceGui2.Parent = Part1
- SurfaceGui2.Face = Enum.NormalId.Top
- ImageLabel3.Parent = SurfaceGui2
- ImageLabel3.Transparency = 1
- ImageLabel3.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel3.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel3.BackgroundTransparency = 1
- ImageLabel3.Image = "rbxassetid://3337202"
- SurfaceGui4.Parent = Part1
- SurfaceGui4.Face = Enum.NormalId.Top
- ImageLabel5.Parent = SurfaceGui4
- ImageLabel5.Transparency = 1
- ImageLabel5.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel5.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel5.BackgroundTransparency = 1
- ImageLabel5.Image = "rbxassetid://3337202"
- SurfaceGui6.Parent = Part1
- SurfaceGui6.Face = Enum.NormalId.Bottom
- ImageLabel7.Parent = SurfaceGui6
- ImageLabel7.Transparency = 1
- ImageLabel7.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel7.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel7.BackgroundTransparency = 1
- ImageLabel7.Image = "rbxassetid://3337202"
- SurfaceGui8.Parent = Part1
- SurfaceGui8.Face = Enum.NormalId.Bottom
- ImageLabel9.Parent = SurfaceGui8
- ImageLabel9.Transparency = 1
- ImageLabel9.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel9.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel9.BackgroundTransparency = 1
- ImageLabel9.Image = "rbxassetid://3337202"
- Weld10.Name = "SpellWeld"
- Weld10.Parent = Part1
- Weld10.C1 = CFrame.new(0.000245000236, 1.24710596, -0.00010599941, 1, 0, 0, 0, 0.999999762, 0, 0, 0, 1)
- Weld10.Part0 = Part31
- Weld10.Part1 = Part1
- Part11.Name = "Spell1"
- Part11.Parent = Spells
- Part11.Transparency = 1
- Part11.Shape = Enum.PartType.Cylinder
- Part11.Size = Vector3.new(3.5, 0.0500000007, 3.5)
- Part11.CFrame = CFrame.new(-2.00700021, 3.00000024, 1.921, 1, 0, 0, 0, 0.999999404, 0, 0, 0, 1)
- Part11.BottomSurface = Enum.SurfaceType.Smooth
- Part11.TopSurface = Enum.SurfaceType.Smooth
- Part11.Position = Vector3.new(-2.00700021, 3.00000024, 1.921)
- SurfaceGui12.Parent = Part11
- SurfaceGui12.Face = Enum.NormalId.Top
- ImageLabel13.Parent = SurfaceGui12
- ImageLabel13.Transparency = 1
- ImageLabel13.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel13.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel13.BackgroundTransparency = 1
- ImageLabel13.Image = "rbxassetid://3337202"
- SurfaceGui14.Parent = Part11
- SurfaceGui14.Face = Enum.NormalId.Top
- ImageLabel15.Parent = SurfaceGui14
- ImageLabel15.Transparency = 1
- ImageLabel15.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel15.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel15.BackgroundTransparency = 1
- ImageLabel15.Image = "rbxassetid://3337202"
- SurfaceGui16.Parent = Part11
- SurfaceGui16.Face = Enum.NormalId.Bottom
- ImageLabel17.Parent = SurfaceGui16
- ImageLabel17.Transparency = 1
- ImageLabel17.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel17.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel17.BackgroundTransparency = 1
- ImageLabel17.Image = "rbxassetid://3337202"
- SurfaceGui18.Parent = Part11
- SurfaceGui18.Face = Enum.NormalId.Bottom
- ImageLabel19.Parent = SurfaceGui18
- ImageLabel19.Transparency = 1
- ImageLabel19.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel19.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel19.BackgroundTransparency = 1
- ImageLabel19.Image = "rbxassetid://3337202"
- Weld20.Name = "SpellWeld"
- Weld20.Parent = Part11
- Weld20.C1 = CFrame.new(0.000245000236, 1.88350677e-05, -0.00010599941, 1, 0, 0, 0, 0.999999523, 0, 0, 0, 1)
- Weld20.Part0 = Part31
- Weld20.Part1 = Part11
- Part21.Name = "Spell2"
- Part21.Parent = Spells
- Part21.Transparency = 1
- Part21.Size = Vector3.new(3.25, 0.0500000007, 3.25)
- Part21.CFrame = CFrame.new(-2.00700021, 2.32607484, 1.921, 1, 0, 0, 0, 0.999999166, 0, 0, 0, 1)
- Part21.BottomSurface = Enum.SurfaceType.Smooth
- Part21.TopSurface = Enum.SurfaceType.Smooth
- Part21.Position = Vector3.new(-2.00700021, 2.32607484, 1.921)
- SurfaceGui22.Parent = Part21
- SurfaceGui22.Face = Enum.NormalId.Top
- ImageLabel23.Parent = SurfaceGui22
- ImageLabel23.Transparency = 1
- ImageLabel23.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel23.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel23.BackgroundTransparency = 1
- ImageLabel23.Image = "rbxassetid://3337202"
- SurfaceGui24.Parent = Part21
- SurfaceGui24.Face = Enum.NormalId.Top
- ImageLabel25.Parent = SurfaceGui24
- ImageLabel25.Transparency = 1
- ImageLabel25.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel25.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel25.BackgroundTransparency = 1
- ImageLabel25.Image = "rbxassetid://3337202"
- SurfaceGui26.Parent = Part21
- SurfaceGui26.Face = Enum.NormalId.Bottom
- ImageLabel27.Parent = SurfaceGui26
- ImageLabel27.Transparency = 1
- ImageLabel27.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel27.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel27.BackgroundTransparency = 1
- ImageLabel27.Image = "rbxassetid://3337202"
- SurfaceGui28.Parent = Part21
- SurfaceGui28.Face = Enum.NormalId.Bottom
- ImageLabel29.Parent = SurfaceGui28
- ImageLabel29.Transparency = 1
- ImageLabel29.Size = UDim2.new(1, 0, 1, 0)
- ImageLabel29.BackgroundColor3 = Color3.new(1, 1, 1)
- ImageLabel29.BackgroundTransparency = 1
- ImageLabel29.Image = "rbxassetid://3337202"
- Weld30.Name = "SpellWeld"
- Weld30.Parent = Part21
- Weld30.C1 = CFrame.new(0.000245000236, 0.673944712, -0.00010599941, 1, 0, 0, 0, 0.999999285, 0, 0, 0, 1)
- Weld30.Part0 = Part31
- Weld30.Part1 = Part21
- Part31.Name = "Handle"
- Part31.Parent = Spells
- Part31.Transparency = 1
- Part31.Size = Vector3.new(2, 4, 2)
- Part31.CFrame = CFrame.new(-2.00675511, 3.00001907, 1.92089403, 1, 0, 0, 0, 0.999999881, 0, 0, 0, 1)
- Part31.BottomSurface = Enum.SurfaceType.Smooth
- Part31.TopSurface = Enum.SurfaceType.Smooth
- Part31.Position = Vector3.new(-2.00675511, 3.00001907, 1.92089403)
- Weld32.Parent = Part31
- Weld32.Part0 = Part31
- Weld32.Part1 = char['Right Arm']
- Spells.Parent = char
- spawn(function()
- while wait() do
- Spells.Spell1.SpellWeld.C0 = Spells.Spell1.SpellWeld.C0*CFrame.Angles(0,math.rad(2),0)
- Spells.Spell2.SpellWeld.C0 = Spells.Spell2.SpellWeld.C0*CFrame.Angles(0,math.rad(-1.5),0)
- Spells.Spell3.SpellWeld.C0 = Spells.Spell3.SpellWeld.C0*CFrame.Angles(0,math.rad(1),0)
- end
- end)
- for i,v in pairs (Spells:GetChildren()) do
- v.Anchored=false
- end
- function swait()
- game:GetService("RunService").RenderStepped:Wait(0)
- end
- --Animator
- movearms = true
- movebody = true
- movelegs = true
- spawn(function()
- --Other
- while wait() do
- if pose == "Idle" and movebody==true and movearms==true then
- for i=0,0.1, 0.001333 do
- if pose~="Idle" or movebody~=true or movearms~=true then break end
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92139721, 0.609127104, 0.197871476, -0.13787961, -0.0786464438, -0.987321615, -3.47089579e-09, 0.996842444, -0.0794048384, 0.990449011, -0.010948305, -0.137444243),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.20093918, 0.755841017, -0.380287111, 0.168671146, 0.18313548, 0.968509912, 0.148882583, 0.966580868, -0.20869942, -0.974363387, 0.179395825, 0.135768622),i)
- end
- for i=0,0.1, 0.001333 do
- if pose~="Idle" or movebody~=true or movearms~=true then break end
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.93793058, 0.525867939, 0.0558444038, -0.0389509574, -0.0212362912, -0.99901545, 0.00805827603, 0.999734938, -0.0215657726, 0.999208629, -0.00889034942, -0.0387694985),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.12205648, 0.581189692, -0.428195477, 0.182427317, 0.100968368, 0.978021324, 0.136899486, 0.982415557, -0.126957461, -0.973642051, 0.157051116, 0.165396914),i)
- end
- end
- if pose == "Running" and movebody==true and movelegs==true then
- for i=0,0.07, 0.0006 do
- if pose~="Running" or movebody~=true or movelegs~=true then break end
- swait()
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.15999198, 2.24705672, 0.864792287, -0.025055496, -0.0938593671, -0.995270133, -0.146920413, 0.985117793, -0.0892032757, 0.988830924, 0.143990457, -0.0384724736),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.113590628, 2.78344774, 0.198696569, -4.3675584e-08, 0.0404659845, 0.999180913, 0.199607119, 0.979073405, -0.0396516435, -0.979876041, 0.199443609, -0.00807734113),i)
- end
- for i=0,0.07, 0.0006 do
- if pose~="Running" or movebody~=true or movelegs~=true then break end
- swait()
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.217573136, 2.06966305, 0.864792287, -0.0282963123, -0.0720653757, -0.996998429, -0.146330804, 0.98695153, -0.067186065, 0.988830924, 0.143990457, -0.0384724736),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.113590628, 2.79427099, 0.02752655, -4.3675584e-08, 0.0404659845, 0.999180913, 0.105148442, 0.993641973, -0.0402416587, -0.99445653, 0.105062313, -0.00425497862),i)
- end
- end
- end
- end)
- spawn(function()
- --Other
- while wait() do
- if pose == "Idle" and movebody==true and movelegs==true then
- for i=0,0.08, 0.0005677 do
- if pose~="Idle" or movebody~=true or movelegs~=true then break end
- swait()
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.208144277, 1.99190795, 0.413949221, -0.0282963067, -0.0720653683, -0.996998429, 0.117742933, 0.990214169, -0.0749167055, 0.992640853, -0.119509391, -0.0195342172),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.0902807415, 2.19053221, 0.0564393736, 0.00101210177, 0.0393193997, 0.999226153, 0.116191842, 0.992454112, -0.0391706079, -0.99322629, 0.116141573, -0.00356412865),i)
- end
- for i=0,0.08, 0.0005677 do
- if pose~="Idle" or movebody~=true or movelegs~=true then break end
- swait()
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.208144277, 2.21289301, 0.413949221, -0.0282963067, -0.0720653683, -0.996998429, 0.117742933, 0.990214169, -0.0749167055, 0.992640853, -0.119509391, -0.0195342172),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.0902807415, 2.26938629, 0.0564393736, 0.00101210177, 0.0393193997, 0.999226153, 0.116191842, 0.992454112, -0.0391706079, -0.99322629, 0.116141573, -0.00356412865),i)
- end
- end
- if pose == "Running" and movearms==true and movebody==true then
- for i=0,0.063, 0.0006 do
- if pose~="Running" or movebody~=true or movearms~=true then break end
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.9257164, 0.677200794, -0.159240723, -0.144065306, -0.151931494, -0.977835357, -0.256799757, 0.960030913, -0.111330599, 0.95566684, 0.235069022, -0.177323118),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.01159811, 0.541409969, -0.189548492, -0.114454262, 0.11331255, 0.986945033, 0.151508436, 0.98384279, -0.0953862146, -0.981807232, 0.138613135, -0.129772812),i)
- end
- for i=0,0.063, 0.0006 do
- if pose~="Running" or movebody~=true or movearms~=true then break end
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92266786, 0.692670405, -0.0514299348, -0.133117691, -0.157718673, -0.978470564, -0.06509877, 0.986516297, -0.150159091, 0.988959908, 0.0437084138, -0.141590059),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.01004601, 0.580142736, 0.045785062, -0.10774301, 0.123860687, 0.986433089, 0.0519879125, 0.991553247, -0.118825234, -0.992818654, 0.0384800434, -0.113272227),i)
- end
- end
- end
- end)
- spawn(function()
- while wait() do
- --MAINBODY
- if pose == "Idle" and movebody==true then
- for i=0,0.08, 0.0008 do
- if pose~="Idle" or movebody~=true then break end
- swait()
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.0568120815, -1.76807761, -0.325204164, -0.993514419, -0.109230503, 0.0315862447, 0.0506483465, -0.176418021, 0.983011425, -0.101802446, 0.978235841, 0.180806205),i)
- Head.C1 = Head.C1:lerp(CFrame.new(0.0760571063, -1.96275795, -0.0808709711, -0.992963433, 0.106468454, -0.0518465824, -0.0573577061, -0.0493686944, 0.997132301, 0.103603534, 0.993089736, 0.0551280938),i)
- end
- for i=0,0.08, 0.0008 do
- if pose~="Idle" or movebody~=true then break end
- swait()
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.050637722, -1.57592607, -0.289861679, -0.993514478, -0.109230503, 0.0315862447, 0.0506483503, -0.176418021, 0.983011425, -0.101802453, 0.978235841, 0.180806205),i)
- Head.C1 = Head.C1:lerp(CFrame.new(0.0760571063, -1.96275795, -0.0808709711, -0.992963433, 0.106468454, -0.0518465824, -0.0573577061, -0.0493686944, 0.997132301, 0.103603534, 0.993089736, 0.0551280938),i)
- end
- end
- if pose == "Running" and movebody == true then
- for i=0,0.08, 0.0008 do
- if pose~="Running" or movebody~=true then break end
- swait()
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.00214004517, -1.89437246, -0.72511673, -0.998660922, 0.0516983718, 0.0019045159, -0.0175054725, -0.372338474, 0.927931905, 0.0486816913, 0.926656008, 0.372744888),i)
- Head.C1 = Head.C1:lerp(CFrame.new(-0.0691558272, -1.96407938, 0.0606224984, -0.99810046, -0.0396612808, 0.0471421182, 0.0454219505, 0.043208681, 0.998033047, -0.0416202173, 0.998278499, -0.0413251184),i)
- end
- for i=0,0.08, 0.0008 do
- if pose~="Running" or movebody~=true then break end
- swait()
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.00342551619, -1.66900969, -0.670431733, -0.998660862, 0.0516983755, 0.00190451648, -0.0175054707, -0.372338533, 0.927931905, 0.0486816876, 0.926655948, 0.372744948),i)
- Head.C1 = Head.C1:lerp(CFrame.new(-0.0691558272, -1.96407938, 0.0606224984, -0.99810046, -0.0396612808, 0.0471421182, 0.0454219505, 0.043208681, 0.998033047, -0.0416202173, 0.998278499, -0.0413251184),i)
- end
- end
- end
- end)
- --Attack
- mouse = player:GetMouse()
- attacking = false
- righthand = false
- righting = false
- lefting = false
- function lazor()
- attacking = true
- movebody = false
- for i=0,0.13, 0.0013 do
- Torso.C1 = Torso.C1:lerp(CFrame.new(0.15688242, -1.76807761, -0.290470749, -0.716801167, -0.691800654, -0.0872230977, 0.0506483465, -0.176418021, 0.983011425, -0.695435643, 0.700206041, 0.161495224),i)
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.0380690396, 2.68862104, 0.427225471, -0.0158015247, 0.0321018472, -0.999359608, 0.120059952, 0.992313921, 0.029977167, 0.992640913, -0.119509406, -0.0195342209),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.113590628, 2.79427099, 0.02752655, -4.3675584e-08, 0.0404659845, 0.999180913, 0.105148442, 0.993641973, -0.0402416587, -0.99445653, 0.105062313, -0.00425497862),i)
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92139709, 0.609127104, 0.197871447, -0.13787961, -0.0786464438, -0.987321615, -3.47089579e-09, 0.996842444, -0.0794048384, 0.990449011, -0.010948305, -0.137444243),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.06380701, 2.25257301, 0.536181211, -0.580544651, -0.0107682496, 0.814157248, -0.806997001, -0.125359416, -0.577096999, 0.108276591, -0.992052972, 0.0640868023),i)
- Head.C1 = Head.C1:lerp(CFrame.new(0.0249363557, -1.96275795, -0.108180299, -0.805434704, 0.592440784, -0.0169986095, -0.0573577061, -0.0493686944, 0.997132301, 0.589902639, 0.804099858, 0.0737443045),i)
- swait()
- end
- createSound("rbxassetid://1354419179",0.7,8)
- for i=1,30 do
- wait()
- pcall(function() createSound("rbxassetid://1354419179",0.8,5) end)
- local beam = Instance.new("Part",char)
- beam.Size = Vector3.new(6,6,100)
- beam.BrickColor = BrickColor.new("Really red")
- beam.Material = "Neon"
- beam.CanCollide=false
- beam.Transparency = 1
- beam.Anchored=true
- local position = mouse.Hit.p
- local distance = (rarm.CFrame.p - position).magnitude
- beam.Size = Vector3.new(6, 6, distance)
- beam.CFrame = CFrame.new(rarm.CFrame.p, position) * CFrame.new(0, 0, -distance / 2 + -2)
- if mouse.Target then
- if mouse.Target.Parent:FindFirstChildOfClass("Humanoid") then
- local h = mouse.Target.Parent:FindFirstChildOfClass("Humanoid")
- if h ~= hum then
- h.Health = h.Health - h.MaxHealth / 6
- end
- end
- end
- if mouse.Target then
- if mouse.Target.Parent.Parent:FindFirstChildOfClass("Humanoid") then
- local h = mouse.Target.Parent.Parent:FindFirstChildOfClass("Humanoid")
- if h ~= hum then
- h.Health = h.Health - h.MaxHealth / 6
- end
- end
- end
- spawn(function()
- for i=1,10, 0.4 do
- swait()
- beam.Size = Vector3.new(i,i,beam.Size.Z)
- beam.Transparency = i/10
- end
- beam:Destroy()
- end)
- end
- wait(0.1)
- attacking=false
- movebody = true
- end
- pressingF = false
- mouse.KeyDown:connect(function(key)
- local k = key:lower()
- if k == "f" then
- pressingF = true
- whip()
- end
- end)
- mouse.KeyUp:connect(function(key)
- local k = key:lower()
- if k == "f" then
- pressingF = false
- end
- end)
- function whip()
- attacking = true
- movebody = false
- local punched=false
- spawn(function()
- for i=0,0.13, 0.0013 do
- if movebody == true or attacking == false or punched == true then break end
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.0127004497, -1.79210389, 0.152598143, -0.9826141, 0.18552509, 0.00706116855, 0.0226545036, 0.0820649117, 0.996369541, 0.184272051, 0.979206741, -0.0848411322),i)
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.217573136, 1.44256806, 0.982333004, -0.0282963123, -0.0720653757, -0.996998429, -0.413804471, 0.90876627, -0.0539433509, 0.909925938, 0.411036015, -0.0555357076),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.113590628, 2.79427099, 0.02752655, -4.3675584e-08, 0.0404659845, 0.999180913, 0.105148442, 0.993641973, -0.0402416587, -0.99445653, 0.105062313, -0.00425497862),i)
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.06116152, 0.197792649, 0.554134071, 0.283914477, 0.347440004, -0.893687844, 0.914802015, 0.181097761, 0.361027747, 0.287280321, -0.920048416, -0.26642254),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.77309728, 0.576332927, 0.445536077, -0.348231971, -0.0812811628, 0.933877885, -0.936926842, 0.062104363, -0.343963623, -0.030040117, -0.994754493, -0.097781226),i)
- Head.C1 = Head.C1:lerp(CFrame.new(-0.0374811105, -1.96583605, -0.0436500385, -0.952512562, -0.303425491, 0.0255501121, 0.0333683975, -0.0206092, 0.999230623, -0.302665472, 0.952632308, 0.0297553428),i)
- swait()
- end
- end)
- createSound("rbxassetid://876800936",0.7,8)
- wait(0.1)
- local power = 3
- repeat
- wait()
- Spells.Spell3.Size = Vector3.new(power,0.05,power)
- Spells.Spell3.CanCollide=false
- Weld10 = Instance.new("Weld")
- Weld10.Name = "SpellWeld"
- Weld10.Parent = Part1
- Weld10.C1 = CFrame.new(0.000245000236, 1.24710596, -0.00010599941, 1, 0, 0, 0, 0.999999762, 0, 0, 0, 1)
- Weld10.Part0 = Part31
- Weld10.Part1 = Part1
- power = power + 0.05
- until pressingF == false or power > 7.5
- punched = true
- Spells.Spell3.Size = Vector3.new(3,0.05,3)
- Spells.Spell3.CanCollide=false
- Weld10 = Instance.new("Weld")
- Weld10.Name = "SpellWeld"
- Weld10.Parent = Part1
- Weld10.C1 = CFrame.new(0.000245000236, 1.24710596, -0.00010599941, 1, 0, 0, 0, 0.999999762, 0, 0, 0, 1)
- Weld10.Part0 = Part31
- Weld10.Part1 = Part1
- for i=0.1,0.2, 0.0013 do
- Torso.C1 = Torso.C1:lerp(CFrame.new(-0.050637722, -1.57592618, -0.289861709, -0.993514478, -0.109230503, 0.0315862447, 0.0506483503, -0.176418021, 0.983011425, -0.101802453, 0.978235841, 0.180806205),i)
- LeftLeg.C1 = LeftLeg.C1:lerp(CFrame.new(-0.208144277, 2.86795282, 0.434457392, -0.0282963067, -0.0720653683, -0.996998429, 0.117742933, 0.990214169, -0.0749167055, 0.992640853, -0.119509391, -0.0195342172),i)
- RightLeg.C1 = RightLeg.C1:lerp(CFrame.new(0.0902807415, 2.59190893, 0.0564393736, 0.00101210177, 0.0393193997, 0.999226153, 0.116191842, 0.992454112, -0.0391706079, -0.99322629, 0.116141573, -0.00356412865),i)
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.93793046, 0.514535785, -0.13876757, -0.0389509574, -0.0212362912, -0.99901545, -0.186055884, 0.982444644, -0.0136298463, 0.98176682, 0.185341805, -0.0422182903),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.68404174, 1.85182118, 0.334121138, 0.163626835, -0.0516487658, 0.985169411, -0.984848678, -0.0666964352, 0.160076901, 0.0574395247, -0.996435642, -0.0617795624),i)
- Head.C1 = Head.C1:lerp(CFrame.new(-0.0374811105, -1.92743921, -0.336152017, -0.952512562, -0.303425491, 0.0255501121, 0.0932713151, -0.210860342, 0.973056197, -0.289862543, 0.929231405, 0.229148),i)
- swait()
- end
- wait(1)
- attacking=false
- movebody = true
- end
- function throwsmallball()
- print'domini'
- movearms = false
- attacking = true
- righthand = not righthand
- if righting == true then return end
- if lefting == true then return end
- if righthand == true then
- if righting == true then return end
- righting=true
- else
- if lefting == true then return end
- lefting=true
- end
- local Ball = Instance.new("Part")
- local ParticleEmitter1 = Instance.new("ParticleEmitter")
- local BodyThrust2 = Instance.new("BodyThrust")
- local Attachment3 = Instance.new("Attachment")
- local Attachment4 = Instance.new("Attachment")
- Ball.Name = "Ball"
- Ball.Parent = nil
- Ball.Material = Enum.Material.Neon
- Ball.BrickColor = BrickColor.new("Lime green")
- Ball.Transparency = 0.6
- Ball.Anchored = false
- Ball.CanCollide = false
- Ball.Shape = Enum.PartType.Ball
- Ball.Size = Vector3.new(2,2,2)
- Ball.CFrame = CFrame.new(-14.2000122, 1.5, -29.5, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Ball.BottomSurface = Enum.SurfaceType.Smooth
- Ball.TopSurface = Enum.SurfaceType.Smooth
- Ball.Position = Vector3.new(0,1000,0)
- local t = Instance.new("Trail",Ball)
- t.Attachment0 = Attachment3
- t.Attachment1 = Attachment4
- t.Texture = 'http://www.roblox.com/asset/?id=55054494'
- t.Color = ColorSequence.new(Color3.new(0,255,0))
- t.LightEmission=1
- t.LightInfluence=0
- t.FaceCamera=false
- t.Lifetime = 0.5
- t.Enabled=false
- ParticleEmitter1.Parent = Ball
- ParticleEmitter1.Transparency = NumberSequence.new(0.5,0.45625001192093,0.0625,1)
- ParticleEmitter1.Size = NumberSequence.new(1.2021857500076,0)
- ParticleEmitter1.LightEmission = 1
- ParticleEmitter1.Lifetime = NumberRange.new(1, 1)
- ParticleEmitter1.Rate = 100
- ParticleEmitter1.LockedToPart=true
- ParticleEmitter1.Speed = NumberRange.new(0, 0)
- ParticleEmitter1.Color = ColorSequence.new(Color3.new(0,255,0))
- BodyThrust2.Parent = Ball
- Attachment3.Parent = Ball
- Attachment3.CFrame = CFrame.new(0, 0.8, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment3.Position = Vector3.new(0, 0.8, 0)
- Attachment4.Parent = Ball
- Attachment4.CFrame = CFrame.new(0, -0.8, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment4.Position = Vector3.new(0, -0.8, 0)
- local ball = Ball
- local w = nil
- ball.Parent=char
- ball.Anchored=false
- if righthand == true then
- w = Instance.new("Weld")
- w.Parent = ball
- w.Part0 = ball
- w.Part1 = rarm
- w.C0 = CFrame.new(0,4,0)
- else
- w = Instance.new("Weld")
- w.Parent = ball
- w.Part0 = ball
- w.Part1 = larm
- w.C0 = CFrame.new(0,4,0)
- end
- --createSound("rbxassetid://360129736",0.1,2,false,ball)
- if righthand == true then
- for i=0.1,0.13, 0.0013 do
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92139721, 0.609127104, 0.197871476, -0.13787961, -0.0786464438, -0.987321615, -3.47089579e-09, 0.996842444, -0.0794048384, 0.990449011, -0.010948305, -0.137444243),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.68974829, 2.40598106, 0.472159296, 0.0454996675, -0.116993919, 0.992089808, -0.292355925, -0.951196074, -0.0987632796, 0.955226541, -0.285549641, -0.0774829611),i)
- end
- elseif righthand == false then
- for i=0.1,0.13, 0.0013 do
- swait()
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.12205648, 0.581189692, -0.428195477, 0.182427317, 0.100968368, 0.978021324, 0.136899486, 0.982415557, -0.126957461, -0.973642051, 0.157051116, 0.165396914),i)
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.93507421, 2.44304132, 0.185819805, 0.00639864849, -0.0794032067, -0.996822, 0.13311252, -0.987903535, 0.0795472413, -0.991080344, -0.1331985, 0.00424831593),i)
- end
- end
- wait(0.01)
- local point = mouse.Hit.p
- w:Destroy()
- ball.CFrame = CFrame.new(ball.CFrame.p,point)
- ball.Anchored=true
- local hit=false
- spawn(function()
- repeat
- if w then w:Destroy() end
- swait()
- ball.CFrame = ball.CFrame*CFrame.new(0,0,-2)
- until ball == nil or hit == true
- end)
- createSound("rbxassetid://551051176",1,4,false,ball)
- createSound("rbxassetid://679372486",1,2,false,ball)
- t.Enabled = true
- spawn(function()
- local numb = 0
- while wait(0.03) do
- numb = numb + 1
- if w then w:Destroy() end
- for i,c in pairs (workspace:GetChildren()) do
- if c:IsA("Model") and c:FindFirstChildOfClass("Humanoid") then
- local v = c:FindFirstChild("Torso")
- if v == nil then v = c:FindFirstChild("HumanoidRootPart") end
- if v and v ~= char.HumanoidRootPart and v ~= torso then
- if (v.Position-ball.Position).magnitude < (v.Size).magnitude*2 then
- if hit == false then
- hit=true
- createSound("rbxassetid://142070127",1,4,false,v)
- local h = c:FindFirstChildOfClass("Humanoid")
- if h then
- h.Health = h.Health - math.random(h.MaxHealth/10,h.MaxHealth/3)
- end
- for i=1,5, 0.25 do
- swait()
- ball.Size = ball.Size+Vector3.new(i/5,i/5,i/5)
- ball.Transparency = i/5
- end
- ball:Destroy()
- break
- else
- break
- end
- end
- end
- end
- end
- if ball == nil then break end
- if ball.Parent == nil then break end
- if hit == true then break end
- if numb > 40 then ball:Destroy() break end
- end
- end)
- if righthand == true then
- for i=0.1,0.13, 0.001 do
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92139721, 0.609127104, 0.197871476, -0.13787961, -0.0786464438, -0.987321615, -3.47089579e-09, 0.996842444, -0.0794048384, 0.990449011, -0.010948305, -0.137444243),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.80503547, 1.5968492, 0.649080038, 0.0553190857, -0.0553134792, 0.996935487, -0.992296994, 0.107798807, 0.0610427633, -0.11084494, -0.992632806, -0.0489240773),i)
- end
- elseif righthand == false then
- for i=0.1,0.13, 0.001 do
- swait()
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.12205648, 0.581189692, -0.428195477, 0.182427317, 0.100968368, 0.978021324, 0.136899486, 0.982415557, -0.126957461, -0.973642051, 0.157051116, 0.165396914),i)
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(2.04465604, 1.06834006, 0.579983354, 0.115892708, -0.00910150446, -0.993220031, 0.990238369, 0.0790203959, 0.114820689, 0.0774396211, -0.996831417, 0.0181705467),i)
- end
- end
- movearms = true
- attacking=false
- if righthand == true then
- righting=false
- else
- lefting=false
- end
- end
- function throwball()
- print'do'
- movearms = false
- attacking = true
- local Ball = Instance.new("Part")
- local ParticleEmitter1 = Instance.new("ParticleEmitter")
- local BodyThrust2 = Instance.new("BodyThrust")
- local Attachment3 = Instance.new("Attachment")
- local Attachment4 = Instance.new("Attachment")
- Ball.Name = "Ball"
- Ball.Parent = nil
- Ball.Material = Enum.Material.Neon
- Ball.Color = Color3.new(1, 81/255, 0)
- print(Ball.Color)
- Ball.Transparency = 0.5
- Ball.Anchored = true
- Ball.CanCollide = false
- Ball.Shape = Enum.PartType.Ball
- Ball.Size = Vector3.new(3, 3, 3)
- Ball.CFrame = CFrame.new(-14.2000122, 1.5, -29.5, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Ball.BottomSurface = Enum.SurfaceType.Smooth
- Ball.TopSurface = Enum.SurfaceType.Smooth
- Ball.Position = Vector3.new(-14.2000122, 1.5, -29.5)
- local t = Instance.new("Trail",Ball)
- t.Attachment0 = Attachment3
- t.Attachment1 = Attachment4
- t.Texture = 'http://www.roblox.com/asset/?id=55054494'
- t.Color = ColorSequence.new(Color3.new(255,51,0))
- t.LightEmission=1
- t.LightInfluence=0
- t.FaceCamera=false
- t.Lifetime = 0.5
- ParticleEmitter1.Parent = Ball
- ParticleEmitter1.Transparency = NumberSequence.new(0.5,0.45625001192093,0.0625,1)
- ParticleEmitter1.Size = NumberSequence.new(1.2021857500076,0)
- ParticleEmitter1.Color = ColorSequence.new(Color3.new(1, 0.14902, 0),Color3.new(1, 0.14902, 0))
- ParticleEmitter1.LightEmission = 1
- ParticleEmitter1.Lifetime = NumberRange.new(1, 1)
- ParticleEmitter1.Rate = 100
- ParticleEmitter1.LockedToPart=true
- ParticleEmitter1.Speed = NumberRange.new(0, 0)
- ParticleEmitter1.Color = ColorSequence.new(Color3.new(1, 0.14902, 0),Color3.new(1, 0.14902, 0))
- BodyThrust2.Parent = Ball
- Attachment3.Parent = Ball
- Attachment3.CFrame = CFrame.new(0, 1.29023409, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment3.Position = Vector3.new(0, 1.29023409, 0)
- Attachment4.Parent = Ball
- Attachment4.CFrame = CFrame.new(0, -1.24282432, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)
- Attachment4.Position = Vector3.new(0, -1.24282432, 0)
- local ball = Ball
- local w = Instance.new("Weld")
- w.Parent = ball
- w.Part0 = ball
- w.Part1 = rarm
- w.C0 = CFrame.new(0,4,0)
- ball.Parent=char
- ball.Anchored=false
- spawn(function()
- for i=0,5, 0.05 do
- ball.Size = Vector3.new(i,i,i)
- if w ~= nil then w:Destroy() end
- w = Instance.new("Weld")
- w.Parent = ball
- w.Part0 = ball
- w.Part1 = rarm
- w.C0 = CFrame.new(0,4,0)
- swait()
- end
- end)
- createSound("rbxassetid://876800936",0.3,4,false,ball)
- for i=0,0.13, 0.0013 do
- swait()
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.92139709, 0.609127164, 0.197871447, -0.13787961, -0.0786464438, -0.987321615, -3.47089579e-09, 0.996842444, -0.0794048384, 0.990449011, -0.0109483041, -0.137444243),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-1.93205297, 1.92837679, -0.249813452, -0.0421406105, 0.0412775576, 0.99825865, 0.24969551, -0.967005312, 0.0505259223, 0.967406988, 0.251389891, 0.0304433741),i)
- end
- wait(0.01)
- local point = mouse.Hit.p
- w:Destroy()
- ball.CFrame = CFrame.new(ball.CFrame.p,point)
- ball.Anchored=true
- local hit=false
- spawn(function()
- repeat
- if w then w:Destroy() end
- swait()
- ball.CFrame = ball.CFrame*CFrame.new(0,0,-2)
- until ball == nil or hit == true
- end)
- createSound("rbxassetid://551051176",1,4,false,ball)
- createSound("rbxassetid://679372486",0.5,4,false,ball)
- spawn(function()
- local numb = 0
- while wait(0.03) do
- numb = numb + 0.1
- if w then w:Destroy() end
- for i,c in pairs (workspace:GetChildren()) do
- if c:IsA("Model") and c:FindFirstChildOfClass("Humanoid") then
- local v = c:FindFirstChild("Torso")
- if v == nil then v = c:FindFirstChild("HumanoidRootPart") end
- if v and v ~= char.HumanoidRootPart and v ~= torso then
- if (v.Position-ball.Position).magnitude < (v.Size).magnitude*2 then
- if hit == false then
- hit=true
- createSound("rbxassetid://142070127",0.8,4,false,v)
- local h = c:FindFirstChildOfClass("Humanoid")
- if h then
- h.Health = h.Health - math.random(h.MaxHealth/3,h.MaxHealth/1.5)
- end
- for i=1,10, 0.25 do
- swait()
- ball.Size = ball.Size+Vector3.new(i/5,i/5,i/5)
- ball.Transparency = i/10
- end
- ball:Destroy()
- break
- else
- break
- end
- end
- end
- end
- end
- if ball == nil then break end
- if ball.Parent == nil then break end
- if hit == true then break end
- if numb > 100 then ball:Destroy() break end
- end
- end)
- for i=0.1,0.13, 0.001 do
- swait()
- local point = mouse.Hit.p
- LeftArm.C1 = LeftArm.C1:lerp(CFrame.new(1.93793035, 0.525868058, 0.0558443964, -0.0389509574, -0.0212362912, -0.99901545, 0.00805827603, 0.999734938, -0.0215657726, 0.999208629, -0.00889034942, -0.0387694985),i)
- RightArm.C1 = RightArm.C1:lerp(CFrame.new(-2.12205672, 1.05030358, 0.322834671, 0.182427317, 0.100968368, 0.978021324, -0.969601631, 0.183454365, 0.161917478, -0.163073719, -0.977829218, 0.131366178),i)
- end
- movearms = true
- attacking=false
- wait(10)
- ball:Destroy()
- end
- mouse.KeyDown:connect(function(k)
- local key = k:lower()
- if attacking == true then return end
- if key == "q" then
- throwball()
- end
- if key == "e" then
- throwsmallball()
- end
- if key == "g" then
- lazor()
- end
- end)
- local mouse = game.Players.LocalPlayer:GetMouse()
- repeat wait() until mouse
- local plr = game.Players.LocalPlayer
- local torso = plr.Character.Torso
- local flying = true
- local deb = true
- local ctrl = {f = 0, b = 0, l = 0, r = 0}
- local lastctrl = {f = 0, b = 0, l = 0, r = 0}
- local maxspeed = 90
- local speed = 0
- function Fly()
- local bg = Instance.new("BodyGyro", torso)
- bg.P = 9e4
- bg.maxTorque = Vector3.new(9e9, 9e9, 9e9)
- bg.cframe = torso.CFrame
- local bv = Instance.new("BodyVelocity", torso)
- bv.velocity = Vector3.new(0,0.1,0)
- bv.maxForce = Vector3.new(9e9, 9e9, 9e9)
- repeat wait()
- plr.Character.Humanoid.PlatformStand = true
- if ctrl.l + ctrl.r ~= 0 or ctrl.f + ctrl.b ~= 0 then
- speed = speed+.5+(speed/maxspeed)
- if speed > maxspeed then
- speed = maxspeed
- end
- elseif not (ctrl.l + ctrl.r ~= 0 or ctrl.f + ctrl.b ~= 0) and speed ~= 0 then
- speed = speed-1
- if speed < 0 then
- speed = 0
- end
- end
- if (ctrl.l + ctrl.r) ~= 0 or (ctrl.f + ctrl.b) ~= 0 then
- bv.velocity = ((game.Workspace.CurrentCamera.CoordinateFrame.lookVector * (ctrl.f+ctrl.b)) + ((game.Workspace.CurrentCamera.CoordinateFrame * CFrame.new(ctrl.l+ctrl.r,(ctrl.f+ctrl.b)*.2,0).p) - game.Workspace.CurrentCamera.CoordinateFrame.p))*speed
- lastctrl = {f = ctrl.f, b = ctrl.b, l = ctrl.l, r = ctrl.r}
- elseif (ctrl.l + ctrl.r) == 0 and (ctrl.f + ctrl.b) == 0 and speed ~= 0 then
- bv.velocity = ((game.Workspace.CurrentCamera.CoordinateFrame.lookVector * (lastctrl.f+lastctrl.b)) + ((game.Workspace.CurrentCamera.CoordinateFrame * CFrame.new(lastctrl.l+lastctrl.r,(lastctrl.f+lastctrl.b)*.2,0).p) - game.Workspace.CurrentCamera.CoordinateFrame.p))*speed
- else
- bv.velocity = Vector3.new(0,0.1,0)
- end
- bg.cframe = bg.cframe:lerp(game.Workspace.CurrentCamera.CoordinateFrame * CFrame.Angles(-math.rad((ctrl.f+ctrl.b)*50*speed/maxspeed),0,0), 0.2)
- until not flying
- ctrl = {f = 0, b = 0, l = 0, r = 0}
- lastctrl = {f = 0, b = 0, l = 0, r = 0}
- speed = 0
- bg:Destroy()
- bv:Destroy()
- plr.Character.Humanoid.PlatformStand = false
- end
- mouse.KeyDown:connect(function(key)
- if key:lower() == "e" then
- elseif key:lower() == "w" then
- ctrl.f = 1
- elseif key:lower() == "s" then
- ctrl.b = -1
- elseif key:lower() == "a" then
- ctrl.l = -1
- elseif key:lower() == "d" then
- ctrl.r = 1
- end
- end)
- mouse.KeyUp:connect(function(key)
- if key:lower() == "w" then
- ctrl.f = 0
- elseif key:lower() == "s" then
- ctrl.b = 0
- elseif key:lower() == "a" then
- ctrl.l = 0
- elseif key:lower() == "d" then
- ctrl.r = 0
- end
- end)
- UIS = game:GetService("UserInputService")
- UIS.InputBegan:connect(function(keyCode,Should)
- if Should == false then
- local KC = keyCode.KeyCode
- if KC == Enum.KeyCode.LeftShift then
- flying = true
- Fly()
- end
- end
- end)
- UIS.InputEnded:connect(function(keyCode,Should)
- if Should == false then
- local KC = keyCode.KeyCode
- if KC == Enum.KeyCode.LeftShift then
- flying = false
- end
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement