Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- This script has been converted to FE by iPxter
- 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
- do
- print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
- script.Parent = Player.Character
- --RemoteEvent for communicating
- local Event = Instance.new("RemoteEvent")
- Event.Name = "UserInput_Event"
- --Fake event to make stuff like Mouse.KeyDown work
- local function fakeEvent()
- local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
- t.connect = t.Connect
- return t
- end
- --Creating fake input objects with fake variables
- local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
- local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
- local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
- CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
- end}
- --Merged 2 functions into one by checking amount of arguments
- CAS.UnbindAction = CAS.BindAction
- --This function will trigger the events that have been :Connect()'ed
- local function te(self,ev,...)
- local t = m[ev]
- if t and t._fakeEvent and t.Function then
- t.Function(...)
- end
- end
- m.TrigEvent = te
- UIS.TrigEvent = te
- Event.OnServerEvent:Connect(function(plr,io)
- if plr~=Player then return end
- if io.isMouse then
- m.Target = io.Target
- m.Hit = io.Hit
- else
- local b = io.UserInputState == Enum.UserInputState.Begin
- if io.UserInputType == Enum.UserInputType.MouseButton1 then
- return m:TrigEvent(b and "Button1Down" or "Button1Up")
- end
- for _,t in pairs(CAS.Actions) do
- for _,k in pairs(t.Keys) do
- if k==io.KeyCode then
- t.Function(t.Name,io.UserInputState,io)
- end
- end
- end
- m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
- UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
- end
- end)
- Event.Parent = NLS([==[
- local Player = game:GetService("Players").LocalPlayer
- local Event = script:WaitForChild("UserInput_Event")
- local UIS = game:GetService("UserInputService")
- local input = function(io,a)
- if a then return end
- --Since InputObject is a client-side instance, we create and pass table instead
- Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
- end
- UIS.InputBegan:Connect(input)
- UIS.InputEnded:Connect(input)
- local Mouse = Player:GetMouse()
- local h,t
- --Give the server mouse data 30 times every second, but only if the values changed
- --If player is not moving their mouse, client won't fire events
- while wait(1/30) do
- if h~=Mouse.Hit or t~=Mouse.Target then
- h,t=Mouse.Hit,Mouse.Target
- Event:FireServer({isMouse=true,Target=t,Hit=h})
- end
- end]==],Player.Character)
- Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
- end
- -- the scripty part
- Player=owner
- Character=Player.Character
- Backpack=Player.Backpack
- Torso=Character.Torso
- Head=Character.Head
- Humanoid=Character.Humanoid
- m=Instance.new('Model',Character)
- LeftArm=Character["Left Arm"]
- LeftLeg=Character["Left Leg"]
- RightArm=Character["Right Arm"]
- RightLeg=Character["Right Leg"]
- LS=Torso["Left Shoulder"]
- LH=Torso["Left Hip"]
- RS=Torso["Right Shoulder"]
- RH=Torso["Right Hip"]
- local p = owner
- local char = p.Character
- local hum = char.Humanoid
- local root = char.HumanoidRootPart
- hum.WalkSpeed = 9
- Face = Head.face
- Neck=Torso.Neck
- it=Instance.new
- attacktype=1
- vt=Vector3.new
- cf=CFrame.new
- euler=CFrame.fromEulerAnglesXYZ
- angles=CFrame.Angles
- cloaked=false
- necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0)
- LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0)
- LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0)
- RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0)
- RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0)
- RootPart=Character.HumanoidRootPart
- RootJoint=RootPart.RootJoint
- RootCF=euler(-1.57,0,3.14)
- attack = false
- attackdebounce = false
- deb=false
- equipped=true
- hand=false
- CanJoke = true;
- MMouse=nil
- combo=0
- mana=0
- trispeed=.2
- attackmode='none'
- local idle=0
- local Anim="Idle"
- local Effects={}
- local gun=false
- local shoot=false
- player=nil
- mana=0
- print("From the depths of hell")
- wait(2)
- print("Rise")
- wait(1)
- print("Rise, Almighty Phammer")
- function onKeyPress2(inputObject, gameProcessedEvent)
- if inputObject.KeyCode == Enum.KeyCode.T then
- Sound2 = Instance.new("Sound", workspace)
- Sound2.SoundId = "rbxassetid://135017755"
- Sound2.Looped = false
- Sound2.Volume = 1
- Sound2:Play()
- wait(10)
- end
- end
- game:GetService("UserInputService").InputBegan:connect(onKeyPress2)
- lite = Instance.new("PointLight")
- lite.Parent = Torso
- lite.Brightness = 10
- lite.Range = 15
- lite.Color = Color3.new(1,0,0)
- z = Instance.new("Sound", Neck)
- z.SoundId = "rbxassetid://279530667"--282572614 -- 157060424 -- 303570180
- z.Looped = true
- z.Pitch = 1
- z.Volume = 0.3
- wait(.1)
- z:Play()
- --save shoulders
- RSH, LSH=nil, nil
- --welds
- RW, LW=Instance.new("Weld"), Instance.new("Weld")
- RW.Name="Right Shoulder" LW.Name="Left Shoulder"
- LH=Torso["Left Hip"]
- RH=Torso["Right Hip"]
- TorsoColor=Torso.BrickColor
- function NoOutline(Part)
- Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10
- end
- player=Player
- ch=Character
- RSH=ch.Torso["Right Shoulder"]
- LSH=ch.Torso["Left Shoulder"]
- --
- RSH.Parent=nil
- LSH.Parent=nil
- --
- RW.Name="Right Shoulder"
- RW.Part0=ch.Torso
- RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5)
- RW.C1=cf(0, 0.5, 0)
- RW.Part1=ch["Right Arm"]
- RW.Parent=ch.Torso
- --
- LW.Name="Left Shoulder"
- LW.Part0=ch.Torso
- LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8)
- LW.C1=cf(0, 0.5, 0)
- LW.Part1=ch["Left Arm"]
- LW.Parent=ch.Torso
- Player=owner
- Character=Player.Character
- m=Instance.new('Model',Character)
- local function weldBetween(a, b)
- local weldd = Instance.new("ManualWeld")
- weldd.Part0 = a
- weldd.Part1 = b
- weldd.C0 = CFrame.new()
- weldd.C1 = b.CFrame:inverse() * a.CFrame
- weldd.Parent = a
- return weldd
- end
- it=Instance.new
- function nooutline(part)
- part.TopSurface,part.BottomSurface,part.LeftSurface,part.RightSurface,part.FrontSurface,part.BackSurface = 10,10,10,10,10,10
- end
- function part(formfactor,parent,material,reflectance,transparency,brickcolor,name,size)
- local fp=it("Part")
- fp.formFactor=formfactor
- fp.Parent=parent
- fp.Reflectance=reflectance
- fp.Transparency=transparency
- fp.CanCollide=false
- fp.Locked=true
- fp.BrickColor=BrickColor.new(tostring(brickcolor))
- fp.Name=name
- fp.Size=size
- fp.Position=Character.Torso.Position
- nooutline(fp)
- fp.Material=material
- fp:BreakJoints()
- return fp
- end
- function mesh(Mesh,part,meshtype,meshid,offset,scale)
- local mesh=it(Mesh)
- mesh.Parent=part
- if Mesh=="SpecialMesh" then
- mesh.MeshType=meshtype
- mesh.MeshId=meshid
- end
- mesh.Offset=offset
- mesh.Scale=scale
- return mesh
- end
- function weld(parent,part0,part1,c0,c1)
- local weld=it("Weld")
- weld.Parent=parent
- weld.Part0=part0
- weld.Part1=part1
- weld.C0=c0
- weld.C1=c1
- return weld
- end
- handle=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Handle",Vector3.new(0.504, 4.706, 0.604))
- handleweld=weld(m,Character["Right Arm"],handle,CFrame.new(0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 2),CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 100))
- Hitbox=part(Enum.FormFactor.Custom,m,Enum.Material.SmoothPlastic,0,1,"Really black","Hitbox",Vector3.new(2.057, 2.217, 2.301))
- Hitboxweld=weld(m,handle,Hitbox,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(1.857, 2.017, 2.101))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.6, 2.017, 2.101))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.54, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.6, 2.017, 2.101))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-1.54, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.5, 2.817, 2.801))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-1.04, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.5, 2.817, 2.801))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(2.08, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1)) ------------New Part 1 (Hammer extention)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.5, 2.817, 2.801))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(-2.08, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1)) ------------New Part 2 (Hammer extention)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.514, 0.814, 0.524))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -4.2, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1)) ---------------- New Part 3 (Top)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.814, 0.314, 0.824))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -1.47, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1)) ---------------- New Part 4 (Middle extention)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.814, 0.314, 0.824))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, -2.1, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1)) ---------------- New Part 5 (Middle extention)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.6, 2.017, 2.101))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.54, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1)) -------------- New Part 6 (
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.5, 2.817, 2.801))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(1.14, -3.2, 0, -1, 0, 0, 0, 1, 0, -15, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.514, 0.214, 0.524))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 2.46, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.514, 0.214, 0.534))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 2.67, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(0.514, 0.214, 0.524))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 2.89, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(0.514, 0.214, 0.524))
- Partweld=weld(m,handle,Part,CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1),CFrame.new(0, 3.09, 0, -1, 0, 0, 0, 1, 0, 0, 0, -1))
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really black","Part",Vector3.new(1.104, 1.906, 1.2))
- Partweld=weld(m,Character["Left Arm"],Part,CFrame.new(0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 2),CFrame.new(0, 0.4, 0, 1, 0, 0, 0, 1, 0, 0, 0, 100)) ------------------- New Part 7 (Arm cannon base)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Slate,0,0,"Really red","Part",Vector3.new(0.514, 0.214, 0.524))
- Partweld=weld(m,Character["Left Arm"],Part,CFrame.new(0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 2),CFrame.new(0, 0, 1.3, 1, 0, 0, 0, 1, 0, 0, 90, 100))
- mesh("SpecialMesh",Part,Enum.MeshType.FileMesh,"http://www.roblox.com/asset?id=156292343",Vector3.new(0, 0, 0),Vector3.new(1.28, 1.28, 5)) ------------------- New Part 8 (Blaster Mesh)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(1.204, 0.406, 1.25))
- Partweld=weld(m,Character["Left Arm"],Part,CFrame.new(0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 2),CFrame.new(0, 0.95, 0, 1, 0, 0, 0, 1, 0, 0, 0, 100)) ---------------- New Part 9 (Arm cannon Amplifier 1/3)
- Part=part(Enum.FormFactor.Custom,m,Enum.Material.Neon,0,0,"Really red","Part",Vector3.new(1.204, 0.406, 1.25))
- Partweld=weld(m,Character["Left Arm"],Part,CFrame.new(0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 2),CFrame.new(0, -0.15, 0, 1, 0, 0, 0, 1, 0, 0, 0, 100)) ---------------- New Part 9 (Arm cannon Amplifier 2/3)
- ---------------------------------------------------------------------------------------------------------------------------------------
- Damagefunc=function(hit,minim,maxim,knockback,Type,Property,Delay,KnockbackType,decreaseblock)
- if hit.Parent==nil then
- return
- end
- h=hit.Parent:FindFirstChild("Humanoid")
- for _,v in pairs(hit.Parent:children()) do
- if v:IsA("Humanoid") then
- h=v
- end
- end
- if hit.Parent.Parent:FindFirstChild("Torso")~=nil then
- h=hit.Parent.Parent:FindFirstChild("Humanoid")
- end
- if hit.Parent.className=="Hat" then
- hit=hit.Parent.Parent:findFirstChild("Head")
- end
- if h~=nil and hit.Parent.Name~=Character.Name and hit.Parent:FindFirstChild("Torso")~=nil then
- if hit.Parent:findFirstChild("DebounceHit")~=nil then if hit.Parent.DebounceHit.Value==true then return end end
- --[[ if game.Players:GetPlayerFromCharacter(hit.Parent)~=nil then
- return
- end]]
- -- hs(hit,1.2)
- c=Instance.new("ObjectValue")
- c.Name="creator"
- c.Value=owner
- c.Parent=h
- game:GetService("Debris"):AddItem(c,.5)
- Damage=math.random(minim,maxim)
- -- h:TakeDamage(Damage)
- blocked=false
- block=hit.Parent:findFirstChild("Block")
- if block~=nil then
- print(block.className)
- if block.className=="NumberValue" then
- if block.Value>0 then
- blocked=true
- if decreaseblock==nil then
- block.Value=block.Value-1
- end
- end
- end
- if block.className=="IntValue" then
- if block.Value>0 then
- blocked=true
- if decreaseblock~=nil then
- block.Value=block.Value-1
- end
- end
- end
- end
- if blocked==false then
- -- h:TakeDamage(Damage)
- h.Health=h.Health-Damage
- showDamage(hit.Parent,Damage,.5,BrickColor.new("Really red"))
- else
- h.Health=h.Health-(Damage/2)
- showDamage(hit.Parent,Damage/2,.5,BrickColor.new("Really red"))
- end
- if Type=="Knockdown" then
- hum=hit.Parent.Humanoid
- hum.PlatformStand=true
- coroutine.resume(coroutine.create(function(HHumanoid)
- swait(1)
- HHumanoid.PlatformStand=false
- end),hum)
- local angle=(hit.Position-(Property.Position+Vector3.new(0,0,0))).unit
- --hit.CFrame=CFrame.new(hit.Position,Vector3.new(angle.x,hit.Position.y,angle.z))*CFrame.fromEulerAnglesXYZ(math.pi/4,0,0)
- local bodvol=Instance.new("BodyVelocity")
- bodvol.velocity=angle*knockback
- bodvol.P=5000
- bodvol.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
- bodvol.Parent=hit
- rl=Instance.new("BodyAngularVelocity")
- rl.P=3000
- rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
- rl.angularvelocity=Vector3.new(math.random(-10,10),math.random(-10,10),math.random(-10,10))
- rl.Parent=hit
- game:GetService("Debris"):AddItem(bodvol,.5)
- game:GetService("Debris"):AddItem(rl,.5)
- elseif Type=="Normal" then
- vp=Instance.new("BodyVelocity")
- vp.P=500
- vp.maxForce=Vector3.new(math.huge,0,math.huge)
- -- vp.velocity=Character.Torso.CFrame.lookVector*Knockback
- if KnockbackType==1 then
- vp.velocity=Property.CFrame.lookVector*knockback+Property.Velocity/1.05
- elseif KnockbackType==2 then
- vp.velocity=Property.CFrame.lookVector*knockback
- end
- if knockback>0 then
- vp.Parent=hit.Parent.Torso
- end
- game:GetService("Debris"):AddItem(vp,.5)
- elseif Type=="Up" then
- local bodyVelocity=Instance.new("BodyVelocity")
- bodyVelocity.velocity=vt(0,60,0)
- bodyVelocity.P=5000
- bodyVelocity.maxForce=Vector3.new(8e+003, 8e+003, 8e+003)
- bodyVelocity.Parent=hit
- game:GetService("Debris"):AddItem(bodyVelocity,1)
- rl=Instance.new("BodyAngularVelocity")
- rl.P=3000
- rl.maxTorque=Vector3.new(500000,500000,500000)*50000000000000
- rl.angularvelocity=Vector3.new(math.random(-30,30),math.random(-30,30),math.random(-30,30))
- rl.Parent=hit
- game:GetService("Debris"):AddItem(rl,.5)
- elseif Type=="Snare" then
- bp=Instance.new("BodyPosition")
- bp.P=2000
- bp.D=100
- bp.maxForce=Vector3.new(math.huge,math.huge,math.huge)
- bp.position=hit.Parent.Torso.Position
- bp.Parent=hit.Parent.Torso
- game:GetService("Debris"):AddItem(bp,1)
- elseif Type=="Target" then
- if Targetting==false then
- ZTarget=hit.Parent.Torso
- coroutine.resume(coroutine.create(function(Part)
- so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
- swait(5)
- so("http://www.roblox.com/asset/?id=15666462",Part,1,1.5)
- end),ZTarget)
- TargHum=ZTarget.Parent:findFirstChild("Humanoid")
- targetgui=Instance.new("BillboardGui")
- targetgui.Parent=ZTarget
- targetgui.Size=UDim2.new(10,100,10,100)
- targ=Instance.new("ImageLabel")
- targ.Parent=targetgui
- targ.BackgroundTransparency=1
- targ.Image="rbxassetid://4834067"
- targ.Size=UDim2.new(1,0,1,0)
- cam.CameraType="Scriptable"
- cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
- dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
- workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
- Targetting=true
- RocketTarget=ZTarget
- for i=1,Property do
- --while Targetting==true and Humanoid.Health>0 and Character.Parent~=nil do
- if Humanoid.Health>0 and Character.Parent~=nil and TargHum.Health>0 and TargHum.Parent~=nil and Targetting==true then
- swait()
- end
- --workspace.CurrentCamera.CoordinateFrame=CFrame.new(Head.CFrame.p,Head.CFrame.p+rmdir*100)
- cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)
- dir=Vector3.new(cam.CoordinateFrame.lookVector.x,0,cam.CoordinateFrame.lookVector.z)
- cam.CoordinateFrame=CFrame.new(Head.CFrame.p,ZTarget.Position)*cf(0,5,10)*euler(-0.3,0,0)
- end
- Targetting=false
- RocketTarget=nil
- targetgui.Parent=nil
- cam.CameraType="Custom"
- end
- end
- debounce=Instance.new("BoolValue")
- debounce.Name="DebounceHit"
- debounce.Parent=hit.Parent
- debounce.Value=true
- game:GetService("Debris"):AddItem(debounce,Delay)
- c=Instance.new("ObjectValue")
- c.Name="creator"
- c.Value=Player
- c.Parent=h
- game:GetService("Debris"):AddItem(c,.5)
- CRIT=false
- hitDeb=true
- AttackPos=6
- end
- end
- showDamage=function(Char,Dealt,du,Color)
- m=Instance.new("Model")
- m.Name=tostring(Dealt)
- h=Instance.new("Humanoid")
- h.Health=0
- h.MaxHealth=0
- h.Parent=m
- c=Instance.new("Part")
- c.Transparency=0
- c.BrickColor=Color
- c.Name="Head"
- c.TopSurface=0
- c.BottomSurface=0
- c.formFactor="Plate"
- c.Size=Vector3.new(1,.4,1)
- ms=Instance.new("CylinderMesh")
- ms.Scale=Vector3.new(.8,.8,.8)
- if CRIT==true then
- ms.Scale=Vector3.new(1,1.25,1)
- end
- ms.Parent=c
- c.Reflectance=0
- Instance.new("BodyGyro").Parent=c
- c.Parent=m
- if Char:findFirstChild("Head")~=nil then
- c.CFrame=CFrame.new(Char["Head"].CFrame.p+Vector3.new(0,1.5,0))
- elseif Char.Parent:findFirstChild("Head")~=nil then
- c.CFrame=CFrame.new(Char.Parent["Head"].CFrame.p+Vector3.new(0,1.5,0))
- end
- f=Instance.new("BodyPosition")
- f.P=2000
- f.D=100
- f.maxForce=Vector3.new(math.huge,math.huge,math.huge)
- f.position=c.Position+Vector3.new(0,3,0)
- f.Parent=c
- game:GetService("Debris"):AddItem(m,.5+du)
- c.CanCollide=false
- m.Parent=workspace
- c.CanCollide=false
- end
- function part(formfactor,parent,reflectance,transparency,brickcolor,name,size)
- local fp=it("Part")
- fp.formFactor=formfactor
- fp.Parent=parent
- fp.Reflectance=reflectance
- fp.Transparency=transparency
- fp.CanCollide=false
- fp.Locked=true
- fp.BrickColor=brickcolor
- fp.Name=name
- fp.Size=size
- fp.Position=Torso.Position
- NoOutline(fp)
- fp.Material="SmoothPlastic"
- fp:BreakJoints()
- return fp
- end
- function mesh(Mesh,part,meshtype,meshid,offset,scale)
- local mesh=it(Mesh)
- mesh.Parent=part
- if Mesh=="SpecialMesh" then
- mesh.MeshType=meshtype
- if meshid~="nil" then
- mesh.MeshId="http://www.roblox.com/asset/?id="..meshid
- end
- end
- mesh.Offset=offset
- mesh.Scale=scale
- return mesh
- end
- function weld(parent,part0,part1,c0)
- local weld=it("Weld")
- weld.Parent=parent
- weld.Part0=part0
- weld.Part1=part1
- weld.C0=c0
- return weld
- end
- local Color1=Torso.BrickColor
- local bodvel=Instance.new("BodyVelocity")
- local bg=Instance.new("BodyGyro")
- function swait(num)
- if num==0 or num==nil then
- game:service'RunService'.Stepped:wait(0)
- else
- for i=0,num do
- game:service'RunService'.Stepped:wait(0)
- end
- end
- end
- so = function(id,par,vol,pit)
- coroutine.resume(coroutine.create(function()
- local sou = Instance.new("Sound",par or workspace)
- sou.Volume=vol
- sou.Pitch=pit or 1
- sou.SoundId=id
- swait()
- sou:play()
- game:GetService("Debris"):AddItem(sou,6)
- end))
- end
- function clerp(a,b,t)
- local qa = {QuaternionFromCFrame(a)}
- local qb = {QuaternionFromCFrame(b)}
- local ax, ay, az = a.x, a.y, a.z
- local bx, by, bz = b.x, b.y, b.z
- local _t = 1-t
- return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t))
- end
- function QuaternionFromCFrame(cf)
- local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components()
- local trace = m00 + m11 + m22
- if trace > 0 then
- local s = math.sqrt(1 + trace)
- local recip = 0.5/s
- return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5
- else
- local i = 0
- if m11 > m00 then
- i = 1
- end
- if m22 > (i == 0 and m00 or m11) then
- i = 2
- end
- if i == 0 then
- local s = math.sqrt(m00-m11-m22+1)
- local recip = 0.5/s
- return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip
- elseif i == 1 then
- local s = math.sqrt(m11-m22-m00+1)
- local recip = 0.5/s
- return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip
- elseif i == 2 then
- local s = math.sqrt(m22-m00-m11+1)
- local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip
- end
- end
- end
- function QuaternionToCFrame(px, py, pz, x, y, z, w)
- local xs, ys, zs = x + x, y + y, z + z
- local wx, wy, wz = w*xs, w*ys, w*zs
- local xx = x*xs
- local xy = x*ys
- local xz = x*zs
- local yy = y*ys
- local yz = y*zs
- local zz = z*zs
- 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))
- end
- function QuaternionSlerp(a, b, t)
- local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4]
- local startInterp, finishInterp;
- if cosTheta >= 0.0001 then
- if (1 - cosTheta) > 0.0001 then
- local theta = math.acos(cosTheta)
- local invSinTheta = 1/math.sin(theta)
- startInterp = math.sin((1-t)*theta)*invSinTheta
- finishInterp = math.sin(t*theta)*invSinTheta
- else
- startInterp = 1-t
- finishInterp = t
- end
- else
- if (1+cosTheta) > 0.0001 then
- local theta = math.acos(-cosTheta)
- local invSinTheta = 1/math.sin(theta)
- startInterp = math.sin((t-1)*theta)*invSinTheta
- finishInterp = math.sin(t*theta)*invSinTheta
- else
- startInterp = t-1
- finishInterp = t
- end
- end
- 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
- end
- function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants
- return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
- end
- function onKeyPress(inputObject, gameProcessedEvent) -------------------------- KEYBIND FINALLY WORKED YAY :D
- if inputObject.KeyCode == Enum.KeyCode.R then
- attack = true
- attackdebounce = true
- owner.Character.Humanoid.WalkSpeed = 0
- print("Dodge this! Omega blaster! i ate your moms pussy for dinner, cec2 is boss")
- z = Instance.new("Sound", Torso)
- z.SoundId = "rbxassetid://264358562"--282572614 -- 157060424 -- 303570180
- z.Looped = false
- z.Pitch = 1
- z.Volume = 2
- wait(.1)
- z:Play()
- sp = Instance.new("Part",LeftArm)
- sp.Anchored = true
- sp.CanCollide = false
- sp.Locked = true
- sp.Transparency = 0.1
- sp.Material = "Neon"
- sp.Size = Vector3.new(1,1,1)
- sp.TopSurface = "SmoothNoOutlines"
- sp.BottomSurface = "SmoothNoOutlines"
- sp.BrickColor = BrickColor.new("Crimson")
- sp2 = Instance.new("Part",LeftArm)
- sp2.Anchored = true
- sp2.CanCollide = false
- sp2.Locked = true
- sp2.Transparency = 0.1
- sp2.Material = "Neon"
- sp2.Size = Vector3.new(1,1,1)
- sp2.TopSurface = "SmoothNoOutlines"
- sp2.BottomSurface = "SmoothNoOutlines"
- sp2.BrickColor = BrickColor.new("Crimson")
- sp3 = Instance.new("Part",LeftArm)
- sp3.Anchored = true
- sp3.CanCollide = false
- sp3.Locked = true
- sp3.Transparency = 0.1
- sp3.Material = "Neon"
- sp3.Size = Vector3.new(1,1,1)
- sp3.TopSurface = "SmoothNoOutlines"
- sp3.BottomSurface = "SmoothNoOutlines"
- sp3.BrickColor = BrickColor.new("Crimson")
- sp4 = Instance.new("Part",LeftArm)
- sp4.Anchored = true
- sp4.CanCollide = false
- sp4.Locked = true
- sp4.Transparency = 0.1
- sp4.Material = "Neon"
- sp4.Size = Vector3.new(1,1,1)
- sp4.TopSurface = "SmoothNoOutlines"
- sp4.BottomSurface = "SmoothNoOutlines"
- sp4.BrickColor = BrickColor.new("Crimson")
- local bem = Instance.new("Part", LeftArm)
- bem.Anchored = true
- bem.BrickColor = BrickColor.new("Crimson")
- bem.CanCollide = false
- bem.FormFactor = 3
- bem.Name = "Beam"
- bem.Size = Vector3.new(1, 1, 1)
- bem.Transparency = 0.35
- bem.TopSurface = 0
- bem.BottomSurface = 0
- local bemm = Instance.new("SpecialMesh", bem)
- bemm.MeshType = 4
- bemm.Scale = Vector3.new(1, 4, 4)
- local bem2 = Instance.new("Part", LeftArm)
- bem2.Anchored = true
- bem2.BrickColor = BrickColor.new("Crimson")
- bem2.CanCollide = false
- bem2.FormFactor = 3
- bem2.Name = "Beam2"
- bem2.Size = Vector3.new(1, 1, 1)
- bem2.Transparency = 0.50
- bem2.TopSurface = 0
- bem2.BottomSurface = 0
- local bemm2 = Instance.new("SpecialMesh", bem2)
- bemm2.MeshType = 4
- bemm2.Scale = Vector3.new(1, 4, 4)
- local bem3 = Instance.new("Part", LeftArm)
- bem3.Anchored = true
- bem3.BrickColor = BrickColor.new("Crimson")
- bem3.CanCollide = false
- bem3.FormFactor = 3
- bem3.Name = "Beam2"
- bem3.Size = Vector3.new(1, 1, 1)
- bem3.Transparency = 0.50
- bem3.TopSurface = 0
- bem3.BottomSurface = 0
- local bemm3 = Instance.new("SpecialMesh", bem3)
- bemm3.MeshType = 4
- bemm3.Scale = Vector3.new(1, 4, 4)
- local bem4 = Instance.new("Part", LeftArm)
- bem4.Anchored = true
- bem4.BrickColor = BrickColor.new("Crimson")
- bem4.CanCollide = false
- bem4.FormFactor = 3
- bem4.Name = "Beam2"
- bem4.Size = Vector3.new(1, 1, 1)
- bem4.Transparency = 0.50
- bem4.TopSurface = 0
- bem4.BottomSurface = 0
- local beam4 = Instance.new("Part", LeftArm)
- beam4.Anchored = true
- beam4.BrickColor = BrickColor.new("Crimson")
- beam4.CanCollide = false
- beam4.FormFactor = 3
- beam4.Name = "Beam2"
- beam4.Size = Vector3.new(1, 1, 1)
- beam4.Transparency = 0.50
- beam4.TopSurface = 0
- beam4.BottomSurface = 0
- local beamm4 = Instance.new("SpecialMesh", beam4)
- beamm4.MeshType = "Cylinder"
- beamm4.Scale = Vector3.new(1, 4, 4)
- spm = Instance.new("SpecialMesh",sp)
- spm.MeshType = "Sphere"
- spm.Scale = Vector3.new(21,21,21)
- spm2 = Instance.new("SpecialMesh",sp2)
- spm2.MeshType = "Sphere"
- spm2.Scale = Vector3.new(21,21,21)
- spm3 = Instance.new("SpecialMesh",sp3)
- spm3.MeshType = "Sphere"
- spm3.Scale = Vector3.new(21,21,21)
- spm4 = Instance.new("SpecialMesh",sp4)
- spm4.MeshType = "Sphere"
- spm4.Scale = Vector3.new(22,22,22)
- function onTouchedBeam(part)
- local h = part.Parent:findFirstChild("Humanoid")
- if h~=nil and game.Players:GetPlayerFromCharacter(h.Parent)~=owner then
- h.Health = h.Health -200
- wait(2)
- end
- end
- bem.Touched:connect(onTouchedBeam)
- for i=0,2.0,0.1 do
- swait()
- bem.CFrame = LeftArm.CFrame * CFrame.new(0, -100.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- bem2.CFrame = LeftArm.CFrame * CFrame.new(0, -100.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- bem3.CFrame = LeftArm.CFrame * CFrame.new(0, -100.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- beam4.CFrame = LeftArm.CFrame * CFrame.new(0, -100.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- spm.Scale = spm.Scale - Vector3.new(1,1,1)
- sp.CFrame = root.CFrame*CFrame.new(-1.5,0.5,-2)
- sp2.CFrame = root.CFrame*CFrame.new(-1.5,0.5,-2)
- sp3.CFrame = root.CFrame*CFrame.new(-1.5,0.5,-2)
- sp4.CFrame = root.CFrame*CFrame.new(-1.5,0.5,-2)
- LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(90),math.rad(0),math.rad(0)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(0.2)
- for i=0,2.0,0.1 do
- swait()
- spm2.Scale = spm2.Scale - Vector3.new(1,1,1)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(0.2)
- for i=0,2.0,0.1 do
- swait()
- spm3.Scale = spm3.Scale - Vector3.new(1,1,1)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(0.2)
- for i=0,2.0,0.1 do
- swait()
- spm4.Scale = spm4.Scale - Vector3.new(1,1,1)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(3)
- for i=6,6.0,6.1 do
- swait()
- bem.Size = Vector3.new(1000, 3, 3)
- bem.CFrame = LeftArm.CFrame * CFrame.new(0, -498.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- bem2.Size = Vector3.new(1000, 2, 2)
- bem2.CFrame = LeftArm.CFrame * CFrame.new(0, -498.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- bem3.CFrame = LeftArm.CFrame * CFrame.new(0, -498.2 -(i/2), 0) * CFrame.Angles(0, 0, math.rad(90))
- bem3.Size = Vector3.new(1000, 1, 1)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(3)
- for i=0,2.0,2.1 do
- swait(5)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- wait(2)
- owner.Character.Humanoid.WalkSpeed = 12
- attack = false
- sp:Destroy()
- sp2:Destroy()
- sp3:Destroy()
- spm:Destroy()
- spm2:Destroy()
- spm3:Destroy()
- spm4:Destroy()
- sp4:Destroy()
- bem:Destroy()
- bem2:Destroy()
- bemm:Destroy()
- bemm2:Destroy()
- bemm3:Destroy()
- bem3:Destroy()
- end
- end
- game:GetService("UserInputService").InputBegan:connect(onKeyPress)
- mouse.Button1Down:connect(function()
- if attack==false then
- if attacktype==1 then
- attack=true
- attacktype=2
- attackone()
- elseif attacktype==2 then
- attack=true
- attacktype=3
- attacktwo()
- elseif attacktype==3 then
- attack=true
- attacktype=1
- attackthree()
- end
- end
- end)
- function attackone()
- con1=Hitbox.Touched:connect(function(hit) Damagefunc(hit,30,50,math.random(10,20),"Normal",RootPart,.2,1) end)
- attack = true
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(120),math.rad(0),math.rad(10)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- so("http://roblox.com/asset/?id=189505639",Hitbox,1,1)
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(-60),math.rad(0),math.rad(20)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(35),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,.4)*angles(math.rad(80),math.rad(-20),math.rad(0)),.0)
- end
- attack = false
- con1:disconnect()
- end
- function attacktwo()
- con1=Hitbox.Touched:connect(function(hit) Damagefunc(hit,30,50,math.random(10,20),"Normal",RootPart,.2,1) end)
- attack = true
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(120),math.rad(0),math.rad(10)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- so("http://roblox.com/asset/?id=189505639",Hitbox,1,1)
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(-60),math.rad(0),math.rad(20)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(35),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,.4)*angles(math.rad(80),math.rad(-20),math.rad(0)),.0)
- end
- attack = false
- con1:disconnect()
- end
- function attackthree()
- con1=Hitbox.Touched:connect(function(hit) Damagefunc(hit,30,50,math.random(10,20),"Normal",RootPart,.2,1) end)
- attack=true
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(120),math.rad(0),math.rad(10)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(25),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,-1,-1)*angles(math.rad(-80),math.rad(20),math.rad(0)),.0)
- end
- so("http://roblox.com/asset/?id=189505639",Hitbox,1,1)
- for i=0,2.0,0.1 do
- swait()
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(-60),math.rad(0),math.rad(20)),.3)
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(35),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(1),math.rad(0),math.rad(0)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(20))*angles(math.rad(-5),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(-20))*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,.4)*angles(math.rad(80),math.rad(-20),math.rad(0)),.0)
- end
- attack = false
- con1:disconnect()
- end
- local sine = 0
- local change = 1
- local val = 0
- local mananum=0
- while true do
- swait()
- sine = sine + change
- local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude
- local velderp=RootPart.Velocity.y
- hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character)
- if equipped==true or equipped==false then
- if attack==false then
- idle=idle+1
- else
- idle=0
- end
- if idle>=500 then
- if attack==false then
- --Sheath()
- end
- end
- if RootPart.Velocity.y > 1 and hitfloor==nil then
- Anim="Jump"
- if attack==false then
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(-5),math.rad(0),math.rad(0)),.3)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(5),math.rad(0),math.rad(0)),.3)
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(-60),math.rad(0),math.rad(50)),.3)
- LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(50),math.rad(0),math.rad(-40)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- end
- elseif RootPart.Velocity.y < -1 and hitfloor==nil then
- Anim="Fall"
- if attack==false then
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(5),math.rad(0),math.rad(0)),.3)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-10),math.rad(0),math.rad(0)),.3)
- RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(-50),math.rad(0),math.rad(40)),.3)
- LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(40),math.rad(0),math.rad(-30)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(15)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,0)*angles(math.rad(20),math.rad(0),math.rad(0)),.0)
- end
- elseif torvel<1 and hitfloor~= nil then
- local idleanim=0
- Anim="Idle"
- if attack==false then
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.0)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(13.5),math.rad(0),math.rad(0)),.3)
- RW.C0=clerp(RW.C0,cf(1.5, 0.4, 0)*angles(math.rad(35),math.rad(0),math.rad(0)),.3)
- LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(0),math.rad(0),math.rad(-8)),.3)
- RH.C0=clerp(RH.C0,cf(1,-1,-.25)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(9)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,-0.5)*angles(math.rad(-14),math.rad(0),math.rad(0)),.3)
- end
- elseif torvel>2 and torvel<22 and hitfloor~=nil then
- Anim="Walk"
- if attack==false then
- change=1
- RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0)*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(9.5),math.rad(0),math.rad(0)),.3)
- RW.C0=clerp(RW.C0,cf(1.5, 0.4, 0)*angles(math.rad(35),math.rad(-20),math.rad(0)),.3)
- LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*euler(math.rad(-10),math.rad(-60),math.rad(30)),.3)
- handleweld.C0=clerp(handleweld.C0,cf(0,0,.3)*angles(math.rad(70),math.rad(-20),math.rad(0)),.0)
- RH.C0=clerp(RH.C0,cf(1,-0.8,-.25)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- LH.C0=clerp(LH.C0,cf(-1,-0.8,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0)),.3)
- end
- elseif torvel>=22 and hitfloor~=nil then
- Anim="Run"
- if attack==false then
- end
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement