SHOW:
|
|
- or go back to the newest paste.
| 1 | --https://github.com/Mokiros/roblox-FE-compatibility | |
| 2 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
| |
| 3 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
| 4 | local RealPlayer = Player | |
| 5 | 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
| |
| 6 | warn'Corrupt Vectorist II, The Dimensiona.' | |
| 7 | plr = game.Players.LocalPlayer | |
| 8 | char = plr.Character | |
| 9 | hum = char.Humanoid | |
| 10 | local cam = game.Workspace.CurrentCamera | |
| 11 | t = char.Torso | |
| 12 | h = char.Head | |
| 13 | ra = char["Right Arm"] | |
| 14 | la = char["Left Arm"] | |
| 15 | rl = char["Right Leg"] | |
| 16 | ll = char["Left Leg"] | |
| 17 | tors = char.Torso | |
| 18 | lleg = char["Left Leg"] | |
| 19 | root = char.HumanoidRootPart | |
| 20 | hed = char.Head | |
| 21 | rleg = char["Right Leg"] | |
| 22 | rarm = char["Right Arm"] | |
| 23 | larm = char["Left Arm"] | |
| 24 | vt = Vector3.new | |
| 25 | bc = BrickColor.new | |
| 26 | br = BrickColor.random | |
| 27 | it = Instance.new | |
| 28 | cf = CFrame.new | |
| 29 | ||
| 30 | function CameraShake(Times, Power) | |
| 31 | coroutine.resume(coroutine.create(function() | |
| 32 | FV = Instance.new("BoolValue", Character)
| |
| 33 | FV.Name = "CameraShake" | |
| 34 | for ShakeNum=1,Times do | |
| 35 | swait() | |
| 36 | local ef=Power | |
| 37 | if ef>=1 then | |
| 38 | Humanoid.CameraOffset = Vector3.new(math.random(-ef,ef),math.random(-ef,ef),math.random(-ef,ef)) | |
| 39 | else | |
| 40 | ef=Power*10 | |
| 41 | Humanoid.CameraOffset = Vector3.new(math.random(-ef,ef)/10,math.random(-ef,ef)/10,math.random(-ef,ef)/10) | |
| 42 | end | |
| 43 | end | |
| 44 | Humanoid.CameraOffset = Vector3.new(0,0,0) | |
| 45 | FV:Destroy() | |
| 46 | end)) | |
| 47 | end | |
| 48 | ||
| 49 | CamShake=function(Part,Distan,Power,Times) | |
| 50 | local de=Part.Position | |
| 51 | for i,v in pairs(workspace:children()) do | |
| 52 | if v:IsA("Model") and v:findFirstChild("Humanoid") then
| |
| 53 | for _,c in pairs(v:children()) do | |
| 54 | if c.ClassName=="Part" and (c.Position - de).magnitude < Distan then | |
| 55 | local Noob=v.Humanoid | |
| 56 | if Noob~=nil then | |
| 57 | if Noob:FindFirstChild("CamShake")==nil then-- and Noob == Character then
| |
| 58 | --[[local ss=script.CamShake:clone() | |
| 59 | ss.Parent=Noob | |
| 60 | ss.Power.Value=Power | |
| 61 | ss.Times.Value=Times | |
| 62 | ss.Disabled=false]] | |
| 63 | CameraShake(Times, Power) | |
| 64 | end | |
| 65 | end | |
| 66 | end | |
| 67 | end | |
| 68 | end | |
| 69 | end | |
| 70 | end | |
| 71 | ||
| 72 | function chatfunc(text,color) | |
| 73 | local chat = coroutine.wrap(function() | |
| 74 | if Character:FindFirstChild("TalkingBillBoard")~= nil then
| |
| 75 | Character:FindFirstChild("TalkingBillBoard"):destroy()
| |
| 76 | end | |
| 77 | local naeeym2 = Instance.new("BillboardGui",Character)
| |
| 78 | naeeym2.Size = UDim2.new(0,100,0,40) | |
| 79 | naeeym2.StudsOffset = Vector3.new(0,3,0) | |
| 80 | naeeym2.Adornee = Character.Head | |
| 81 | naeeym2.Name = "TalkingBillBoard" | |
| 82 | local tecks2 = Instance.new("TextLabel",naeeym2)
| |
| 83 | tecks2.BackgroundTransparency = 1 | |
| 84 | tecks2.BorderSizePixel = 0 | |
| 85 | tecks2.Text = "" | |
| 86 | tecks2.Font = "SciFi" | |
| 87 | tecks2.TextSize = 30 | |
| 88 | tecks2.TextStrokeTransparency = 0 | |
| 89 | tecks2.TextColor3 = color | |
| 90 | tecks2.TextStrokeColor3 = Color3.new(0,0,0) | |
| 91 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
| 92 | local tecks3 = Instance.new("TextLabel",naeeym2)
| |
| 93 | tecks3.BackgroundTransparency = 1 | |
| 94 | tecks3.BorderSizePixel = 0 | |
| 95 | tecks3.Text = "" | |
| 96 | tecks3.Font = "SciFi" | |
| 97 | tecks3.TextSize = 30 | |
| 98 | tecks3.TextStrokeTransparency = 0 | |
| 99 | tecks3.TextColor3 = Color3.new(0,0,0) | |
| 100 | tecks3.TextStrokeColor3 = color | |
| 101 | tecks3.Size = UDim2.new(1,0,0.5,0) | |
| 102 | for i = 1,string.len(text),1 do | |
| 103 | CFuncs["Sound"].Create("rbxassetid://274118116", char, 0.25, 0.115)
| |
| 104 | tecks2.Text = string.sub(text,1,i) | |
| 105 | tecks3.Text = string.sub(text,1,i) | |
| 106 | wait(0.01) | |
| 107 | end | |
| 108 | wait(1) | |
| 109 | local randomrot = math.random(1,2) | |
| 110 | if randomrot == 1 then | |
| 111 | for i = 1, 50 do | |
| 112 | swait() | |
| 113 | tecks2.Rotation = tecks2.Rotation - .75 | |
| 114 | tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 115 | tecks2.TextTransparency = tecks2.TextTransparency + .04 | |
| 116 | tecks3.Rotation = tecks2.Rotation + .75 | |
| 117 | tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 118 | tecks3.TextTransparency = tecks2.TextTransparency + .04 | |
| 119 | end | |
| 120 | elseif randomrot == 2 then | |
| 121 | for i = 1, 50 do | |
| 122 | swait() | |
| 123 | tecks2.Rotation = tecks2.Rotation + .75 | |
| 124 | tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 125 | tecks2.TextTransparency = tecks2.TextTransparency + .04 | |
| 126 | tecks3.Rotation = tecks2.Rotation - .75 | |
| 127 | tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 128 | tecks3.TextTransparency = tecks2.TextTransparency + .04 | |
| 129 | end | |
| 130 | end | |
| 131 | naeeym2:Destroy() | |
| 132 | end) | |
| 133 | chat() | |
| 134 | end | |
| 135 | ||
| 136 | ||
| 137 | local Create = LoadLibrary("RbxUtility").Create
| |
| 138 | ||
| 139 | CFuncs = {
| |
| 140 | ["Part"] = {
| |
| 141 | Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
| 142 | local Part = Create("Part"){
| |
| 143 | Parent = Parent, | |
| 144 | Reflectance = Reflectance, | |
| 145 | Transparency = Transparency, | |
| 146 | CanCollide = false, | |
| 147 | Locked = true, | |
| 148 | BrickColor = BrickColor.new(tostring(BColor)), | |
| 149 | Name = Name, | |
| 150 | Size = Size, | |
| 151 | Material = Material, | |
| 152 | } | |
| 153 | RemoveOutlines(Part) | |
| 154 | return Part | |
| 155 | end; | |
| 156 | }; | |
| 157 | ||
| 158 | ["Mesh"] = {
| |
| 159 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 160 | local Msh = Create(Mesh){
| |
| 161 | Parent = Part, | |
| 162 | Offset = OffSet, | |
| 163 | Scale = Scale, | |
| 164 | } | |
| 165 | if Mesh == "SpecialMesh" then | |
| 166 | Msh.MeshType = MeshType | |
| 167 | Msh.MeshId = MeshId | |
| 168 | end | |
| 169 | return Msh | |
| 170 | end; | |
| 171 | }; | |
| 172 | ||
| 173 | ["Mesh"] = {
| |
| 174 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 175 | local Msh = Create(Mesh){
| |
| 176 | Parent = Part, | |
| 177 | Offset = OffSet, | |
| 178 | Scale = Scale, | |
| 179 | } | |
| 180 | if Mesh == "SpecialMesh" then | |
| 181 | Msh.MeshType = MeshType | |
| 182 | Msh.MeshId = MeshId | |
| 183 | end | |
| 184 | return Msh | |
| 185 | end; | |
| 186 | }; | |
| 187 | ||
| 188 | ["Weld"] = {
| |
| 189 | Create = function(Parent, Part0, Part1, C0, C1) | |
| 190 | local Weld = Create("Weld"){
| |
| 191 | Parent = Parent, | |
| 192 | Part0 = Part0, | |
| 193 | Part1 = Part1, | |
| 194 | C0 = C0, | |
| 195 | C1 = C1, | |
| 196 | } | |
| 197 | return Weld | |
| 198 | end; | |
| 199 | }; | |
| 200 | ||
| 201 | ["Sound"] = {
| |
| 202 | Create = function(id, par, vol, pit) | |
| 203 | coroutine.resume(coroutine.create(function() | |
| 204 | local S = Create("Sound"){
| |
| 205 | Volume = vol, | |
| 206 | Pitch = pit or 1, | |
| 207 | SoundId = id, | |
| 208 | Parent = par or workspace, | |
| 209 | } | |
| 210 | wait() | |
| 211 | S:play() | |
| 212 | game:GetService("Debris"):AddItem(S, 10)
| |
| 213 | end)) | |
| 214 | end; | |
| 215 | }; | |
| 216 | ||
| 217 | ["LongSound"] = {
| |
| 218 | Create = function(id, par, vol, pit) | |
| 219 | coroutine.resume(coroutine.create(function() | |
| 220 | local S = Create("Sound"){
| |
| 221 | Volume = vol, | |
| 222 | Pitch = pit or 1, | |
| 223 | SoundId = id, | |
| 224 | Parent = par or workspace, | |
| 225 | } | |
| 226 | wait() | |
| 227 | S:play() | |
| 228 | game:GetService("Debris"):AddItem(S, 30)
| |
| 229 | end)) | |
| 230 | end; | |
| 231 | }; | |
| 232 | ||
| 233 | ["ParticleEmitter"] = {
| |
| 234 | Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread) | |
| 235 | local fp = Create("ParticleEmitter"){
| |
| 236 | Parent = Parent, | |
| 237 | Color = ColorSequence.new(Color1, Color2), | |
| 238 | LightEmission = LightEmission, | |
| 239 | Size = Size, | |
| 240 | Texture = Texture, | |
| 241 | Transparency = Transparency, | |
| 242 | ZOffset = ZOffset, | |
| 243 | Acceleration = Accel, | |
| 244 | Drag = Drag, | |
| 245 | LockedToPart = LockedToPart, | |
| 246 | VelocityInheritance = VelocityInheritance, | |
| 247 | EmissionDirection = EmissionDirection, | |
| 248 | Enabled = Enabled, | |
| 249 | Lifetime = LifeTime, | |
| 250 | Rate = Rate, | |
| 251 | Rotation = Rotation, | |
| 252 | RotSpeed = RotSpeed, | |
| 253 | Speed = Speed, | |
| 254 | VelocitySpread = VelocitySpread, | |
| 255 | } | |
| 256 | return fp | |
| 257 | end; | |
| 258 | }; | |
| 259 | ||
| 260 | CreateTemplate = {
| |
| 261 | ||
| 262 | }; | |
| 263 | } | |
| 264 | ||
| 265 | ||
| 266 | ||
| 267 | New = function(Object, Parent, Name, Data) | |
| 268 | local Object = Instance.new(Object) | |
| 269 | for Index, Value in pairs(Data or {}) do
| |
| 270 | Object[Index] = Value | |
| 271 | end | |
| 272 | Object.Parent = Parent | |
| 273 | Object.Name = Name | |
| 274 | return Object | |
| 275 | end | |
| 276 | local halocolor = BrickColor.new("Dark indigo")
| |
| 277 | local wepcolor = BrickColor.new("Really black")
| |
| 278 | local m = Instance.new("Model",char)
| |
| 279 | ||
| 280 | function CreateParta(parent,transparency,reflectance,material,brickcolor) | |
| 281 | local p = Instance.new("Part")
| |
| 282 | p.TopSurface = 0 | |
| 283 | p.BottomSurface = 0 | |
| 284 | p.Parent = parent | |
| 285 | p.Size = Vector3.new(1,1,1) | |
| 286 | p.Transparency = transparency | |
| 287 | p.Reflectance = reflectance | |
| 288 | p.CanCollide = false | |
| 289 | p.Locked = true | |
| 290 | p.BrickColor = brickcolor | |
| 291 | p.Material = material | |
| 292 | return p | |
| 293 | end | |
| 294 | ||
| 295 | function CreateMesh(parent,meshtype,x1,y1,z1) | |
| 296 | local mesh = Instance.new("SpecialMesh",parent)
| |
| 297 | mesh.MeshType = meshtype | |
| 298 | mesh.Scale = Vector3.new(x1,y1,z1) | |
| 299 | return mesh | |
| 300 | end | |
| 301 | ||
| 302 | function CreateSpecialGlowMesh(parent,meshid,x1,y1,z1) | |
| 303 | local mesh = Instance.new("SpecialMesh",parent)
| |
| 304 | mesh.MeshType = "FileMesh" | |
| 305 | mesh.MeshId = meshid | |
| 306 | mesh.TextureId = "http://www.roblox.com/asset/?id=269748808" | |
| 307 | mesh.Scale = Vector3.new(x1,y1,z1) | |
| 308 | mesh.VertexColor = Vector3.new(parent.BrickColor.r, parent.BrickColor.g, parent.BrickColor.b) | |
| 309 | return mesh | |
| 310 | end | |
| 311 | ||
| 312 | function CreateWeld(parent,part0,part1,C1X,C1Y,C1Z,C1Xa,C1Ya,C1Za,C0X,C0Y,C0Z,C0Xa,C0Ya,C0Za) | |
| 313 | local weld = Instance.new("Weld")
| |
| 314 | weld.Parent = parent | |
| 315 | weld.Part0 = part0 | |
| 316 | weld.Part1 = part1 | |
| 317 | weld.C1 = CFrame.new(C1X,C1Y,C1Z)*CFrame.Angles(C1Xa,C1Ya,C1Za) | |
| 318 | weld.C0 = CFrame.new(C0X,C0Y,C0Z)*CFrame.Angles(C0Xa,C0Ya,C0Za) | |
| 319 | return weld | |
| 320 | end | |
| 321 | ||
| 322 | ||
| 323 | local sorb = CreateParta(m,1,1,"SmoothPlastic",BrickColor.random()) | |
| 324 | CreateWeld(sorb,rarm,sorb,0,2,0,math.rad(0),math.rad(0),math.rad(0),0,0,0,math.rad(0),math.rad(0),math.rad(0)) | |
| 325 | local sorb2 = CreateParta(m,1,1,"SmoothPlastic",BrickColor.random()) | |
| 326 | CreateWeld(sorb2,larm,sorb2,0,2,0,math.rad(0),math.rad(0),math.rad(0),0,0,0,math.rad(0),math.rad(0),math.rad(0)) | |
| 327 | ||
| 328 | function RemoveOutlines(part) | |
| 329 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
| 330 | end | |
| 331 | function CreatePart(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
| 332 | local Part = Create("Part")({
| |
| 333 | Parent = Parent, | |
| 334 | Reflectance = Reflectance, | |
| 335 | Transparency = Transparency, | |
| 336 | CanCollide = false, | |
| 337 | Locked = true, | |
| 338 | BrickColor = BrickColor.new(tostring(BColor)), | |
| 339 | Name = Name, | |
| 340 | Size = Size, | |
| 341 | Material = Material | |
| 342 | }) | |
| 343 | Part.CustomPhysicalProperties = PhysicalProperties.new(0.001, 0.001, 0.001, 0.001, 0.001) | |
| 344 | RemoveOutlines(Part) | |
| 345 | return Part | |
| 346 | end | |
| 347 | function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 348 | local Msh = Create(Mesh)({
| |
| 349 | Parent = Part, | |
| 350 | Offset = OffSet, | |
| 351 | Scale = Scale | |
| 352 | }) | |
| 353 | if Mesh == "SpecialMesh" then | |
| 354 | Msh.MeshType = MeshType | |
| 355 | Msh.MeshId = MeshId | |
| 356 | end | |
| 357 | return Msh | |
| 358 | end | |
| 359 | function CreateWeld(Parent, Part0, Part1, C0, C1) | |
| 360 | local Weld = Create("Weld")({
| |
| 361 | Parent = Parent, | |
| 362 | Part0 = Part0, | |
| 363 | Part1 = Part1, | |
| 364 | C0 = C0, | |
| 365 | C1 = C1 | |
| 366 | }) | |
| 367 | return Weld | |
| 368 | end | |
| 369 | ||
| 370 | Player=game:GetService("Players").LocalPlayer
| |
| 371 | Character=Player.Character | |
| 372 | PlayerGui=Player.PlayerGui | |
| 373 | Backpack=Player.Backpack | |
| 374 | Torso=Character.Torso | |
| 375 | Head=Character.Head | |
| 376 | Humanoid=Character.Humanoid | |
| 377 | m=Instance.new('Model',Character)
| |
| 378 | LeftArm=Character["Left Arm"] | |
| 379 | LeftLeg=Character["Left Leg"] | |
| 380 | RightArm=Character["Right Arm"] | |
| 381 | RightLeg=Character["Right Leg"] | |
| 382 | LS=Torso["Left Shoulder"] | |
| 383 | LH=Torso["Left Hip"] | |
| 384 | RS=Torso["Right Shoulder"] | |
| 385 | RH=Torso["Right Hip"] | |
| 386 | Face = Head.face | |
| 387 | Neck=Torso.Neck | |
| 388 | it=Instance.new | |
| 389 | attacktype=1 | |
| 390 | vt=Vector3.new | |
| 391 | cf=CFrame.new | |
| 392 | euler=CFrame.fromEulerAnglesXYZ | |
| 393 | angles=CFrame.Angles | |
| 394 | cloaked=false | |
| 395 | necko=cf(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
| 396 | necko2=cf(0, -0.5, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
| 397 | LHC0=cf(-1,-1,0,-0,-0,-1,0,1,0,1,0,0) | |
| 398 | LHC1=cf(-0.5,1,0,-0,-0,-1,0,1,0,1,0,0) | |
| 399 | RHC0=cf(1,-1,0,0,0,1,0,1,0,-1,-0,-0) | |
| 400 | RHC1=cf(0.5,1,0,0,0,1,0,1,0,-1,-0,-0) | |
| 401 | RootPart=Character.HumanoidRootPart | |
| 402 | RootJoint=RootPart.RootJoint | |
| 403 | RootCF=euler(-1.57,0,3.14) | |
| 404 | attack = false | |
| 405 | attackdebounce = false | |
| 406 | deb=false | |
| 407 | equipped=true | |
| 408 | hand=false | |
| 409 | MMouse=nil | |
| 410 | combo=0 | |
| 411 | mana=0 | |
| 412 | trispeed=.2 | |
| 413 | attackmode='none' | |
| 414 | local idle=0 | |
| 415 | local Anim="Idle" | |
| 416 | local Effects={}
| |
| 417 | local gun=false | |
| 418 | local shoot=false | |
| 419 | local sine = 0 | |
| 420 | local change = 1 | |
| 421 | player=nil | |
| 422 | ||
| 423 | mouse=Player:GetMouse() | |
| 424 | --save shoulders | |
| 425 | RSH, LSH=nil, nil | |
| 426 | --welds | |
| 427 | RW, LW=Instance.new("Weld"), Instance.new("Weld")
| |
| 428 | RW.Name="Right Shoulder" LW.Name="Left Shoulder" | |
| 429 | LH=Torso["Left Hip"] | |
| 430 | RH=Torso["Right Hip"] | |
| 431 | TorsoColor=Torso.BrickColor | |
| 432 | function NoOutline(Part) | |
| 433 | Part.TopSurface,Part.BottomSurface,Part.LeftSurface,Part.RightSurface,Part.FrontSurface,Part.BackSurface = 10,10,10,10,10,10 | |
| 434 | end | |
| 435 | player=Player | |
| 436 | ch=Character | |
| 437 | RSH=ch.Torso["Right Shoulder"] | |
| 438 | LSH=ch.Torso["Left Shoulder"] | |
| 439 | -- | |
| 440 | RSH.Parent=nil | |
| 441 | LSH.Parent=nil | |
| 442 | -- | |
| 443 | RW.Name="Right Shoulder" | |
| 444 | RW.Part0=ch.Torso | |
| 445 | RW.C0=cf(1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.3, 0, -0.5) | |
| 446 | RW.C1=cf(0, 0.5, 0) | |
| 447 | RW.Part1=ch["Right Arm"] | |
| 448 | RW.Parent=ch.Torso | |
| 449 | -- | |
| 450 | LW.Name="Left Shoulder" | |
| 451 | LW.Part0=ch.Torso | |
| 452 | LW.C0=cf(-1.5, 0.5, 0) --* CFrame.fromEulerAnglesXYZ(1.7, 0, 0.8) | |
| 453 | LW.C1=cf(0, 0.5, 0) | |
| 454 | LW.Part1=ch["Left Arm"] | |
| 455 | LW.Parent=ch.Torso | |
| 456 | ||
| 457 | local Stats=Instance.new("BoolValue")
| |
| 458 | Stats.Name="Stats" | |
| 459 | Stats.Parent=Character | |
| 460 | local Atk=Instance.new("NumberValue")
| |
| 461 | Atk.Name="Damage" | |
| 462 | Atk.Parent=Stats | |
| 463 | Atk.Value=1 | |
| 464 | local Def=Instance.new("NumberValue")
| |
| 465 | Def.Name="Defense" | |
| 466 | Def.Parent=Stats | |
| 467 | Def.Value=1 | |
| 468 | local Speed=Instance.new("NumberValue")
| |
| 469 | Speed.Name="Speed" | |
| 470 | Speed.Parent=Stats | |
| 471 | Speed.Value=1 | |
| 472 | local Mvmt=Instance.new("NumberValue")
| |
| 473 | Mvmt.Name="Movement" | |
| 474 | Mvmt.Parent=Stats | |
| 475 | Mvmt.Value=1 | |
| 476 | ||
| 477 | local donum=0 | |
| 478 | ||
| 479 | ||
| 480 | function part(formfactor,parent,reflectance,transparency,brickcolor,name,size) | |
| 481 | local fp=it("Part")
| |
| 482 | fp.formFactor=formfactor | |
| 483 | fp.Parent=parent | |
| 484 | fp.Reflectance=reflectance | |
| 485 | fp.Transparency=transparency | |
| 486 | fp.CanCollide=false | |
| 487 | fp.Locked=true | |
| 488 | fp.BrickColor=brickcolor | |
| 489 | fp.Name=name | |
| 490 | fp.Size=size | |
| 491 | fp.Position=Torso.Position | |
| 492 | NoOutline(fp) | |
| 493 | fp.Material="SmoothPlastic" | |
| 494 | fp:BreakJoints() | |
| 495 | return fp | |
| 496 | end | |
| 497 | ||
| 498 | function mesh(Mesh,part,meshtype,meshid,offset,scale) | |
| 499 | local mesh=it(Mesh) | |
| 500 | mesh.Parent=part | |
| 501 | if Mesh=="SpecialMesh" then | |
| 502 | mesh.MeshType=meshtype | |
| 503 | if meshid~="nil" then | |
| 504 | mesh.MeshId="http://www.roblox.com/asset/?id="..meshid | |
| 505 | end | |
| 506 | end | |
| 507 | mesh.Offset=offset | |
| 508 | mesh.Scale=scale | |
| 509 | return mesh | |
| 510 | end | |
| 511 | ||
| 512 | function weld(parent,part0,part1,c0) | |
| 513 | local weld=it("Weld")
| |
| 514 | weld.Parent=parent | |
| 515 | weld.Part0=part0 | |
| 516 | weld.Part1=part1 | |
| 517 | weld.C0=c0 | |
| 518 | return weld | |
| 519 | end | |
| 520 | ||
| 521 | local Color1=Torso.BrickColor | |
| 522 | ||
| 523 | local bodvel=Instance.new("BodyVelocity")
| |
| 524 | local bg=Instance.new("BodyGyro")
| |
| 525 | ||
| 526 | function swait(num) | |
| 527 | if num==0 or num==nil then | |
| 528 | game:service'RunService'.Stepped:wait(0) | |
| 529 | else | |
| 530 | for i=0,num do | |
| 531 | game:service'RunService'.Stepped:wait(0) | |
| 532 | end | |
| 533 | end | |
| 534 | end | |
| 535 | ||
| 536 | ||
| 537 | so = function(id,par,vol,pit) | |
| 538 | coroutine.resume(coroutine.create(function() | |
| 539 | local sou = Instance.new("Sound",par or workspace)
| |
| 540 | sou.Volume=vol | |
| 541 | sou.Pitch=pit or 1 | |
| 542 | sou.SoundId=id | |
| 543 | swait() | |
| 544 | sou:play() | |
| 545 | game:GetService("Debris"):AddItem(sou,6)
| |
| 546 | end)) | |
| 547 | end | |
| 548 | ||
| 549 | function clerp(a,b,t) | |
| 550 | local qa = {QuaternionFromCFrame(a)}
| |
| 551 | local qb = {QuaternionFromCFrame(b)}
| |
| 552 | local ax, ay, az = a.x, a.y, a.z | |
| 553 | local bx, by, bz = b.x, b.y, b.z | |
| 554 | local _t = 1-t | |
| 555 | return QuaternionToCFrame(_t*ax + t*bx, _t*ay + t*by, _t*az + t*bz,QuaternionSlerp(qa, qb, t)) | |
| 556 | end | |
| 557 | ||
| 558 | function QuaternionFromCFrame(cf) | |
| 559 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 560 | local trace = m00 + m11 + m22 | |
| 561 | if trace > 0 then | |
| 562 | local s = math.sqrt(1 + trace) | |
| 563 | local recip = 0.5/s | |
| 564 | return (m21-m12)*recip, (m02-m20)*recip, (m10-m01)*recip, s*0.5 | |
| 565 | else | |
| 566 | local i = 0 | |
| 567 | if m11 > m00 then | |
| 568 | i = 1 | |
| 569 | end | |
| 570 | if m22 > (i == 0 and m00 or m11) then | |
| 571 | i = 2 | |
| 572 | end | |
| 573 | if i == 0 then | |
| 574 | local s = math.sqrt(m00-m11-m22+1) | |
| 575 | local recip = 0.5/s | |
| 576 | return 0.5*s, (m10+m01)*recip, (m20+m02)*recip, (m21-m12)*recip | |
| 577 | elseif i == 1 then | |
| 578 | local s = math.sqrt(m11-m22-m00+1) | |
| 579 | local recip = 0.5/s | |
| 580 | return (m01+m10)*recip, 0.5*s, (m21+m12)*recip, (m02-m20)*recip | |
| 581 | elseif i == 2 then | |
| 582 | local s = math.sqrt(m22-m00-m11+1) | |
| 583 | local recip = 0.5/s return (m02+m20)*recip, (m12+m21)*recip, 0.5*s, (m10-m01)*recip | |
| 584 | end | |
| 585 | end | |
| 586 | end | |
| 587 | ||
| 588 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 589 | local xs, ys, zs = x + x, y + y, z + z | |
| 590 | local wx, wy, wz = w*xs, w*ys, w*zs | |
| 591 | local xx = x*xs | |
| 592 | local xy = x*ys | |
| 593 | local xz = x*zs | |
| 594 | local yy = y*ys | |
| 595 | local yz = y*zs | |
| 596 | local zz = z*zs | |
| 597 | 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)) | |
| 598 | end | |
| 599 | ||
| 600 | function QuaternionSlerp(a, b, t) | |
| 601 | local cosTheta = a[1]*b[1] + a[2]*b[2] + a[3]*b[3] + a[4]*b[4] | |
| 602 | local startInterp, finishInterp; | |
| 603 | if cosTheta >= 0.0001 then | |
| 604 | if (1 - cosTheta) > 0.0001 then | |
| 605 | local theta = math.acos(cosTheta) | |
| 606 | local invSinTheta = 1/math.sin(theta) | |
| 607 | startInterp = math.sin((1-t)*theta)*invSinTheta | |
| 608 | finishInterp = math.sin(t*theta)*invSinTheta | |
| 609 | else | |
| 610 | startInterp = 1-t | |
| 611 | finishInterp = t | |
| 612 | end | |
| 613 | else | |
| 614 | if (1+cosTheta) > 0.0001 then | |
| 615 | local theta = math.acos(-cosTheta) | |
| 616 | local invSinTheta = 1/math.sin(theta) | |
| 617 | startInterp = math.sin((t-1)*theta)*invSinTheta | |
| 618 | finishInterp = math.sin(t*theta)*invSinTheta | |
| 619 | else | |
| 620 | startInterp = t-1 | |
| 621 | finishInterp = t | |
| 622 | end | |
| 623 | end | |
| 624 | 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 | |
| 625 | end | |
| 626 | ||
| 627 | local function CFrameFromTopBack(at, top, back) | |
| 628 | local right = top:Cross(back) | |
| 629 | return CFrame.new(at.x, at.y, at.z, | |
| 630 | right.x, top.x, back.x, | |
| 631 | right.y, top.y, back.y, | |
| 632 | right.z, top.z, back.z) | |
| 633 | end | |
| 634 | ||
| 635 | function Triangle(a, b, c) | |
| 636 | local edg1 = (c-a):Dot((b-a).unit) | |
| 637 | local edg2 = (a-b):Dot((c-b).unit) | |
| 638 | local edg3 = (b-c):Dot((a-c).unit) | |
| 639 | if edg1 <= (b-a).magnitude and edg1 >= 0 then | |
| 640 | a, b, c = a, b, c | |
| 641 | elseif edg2 <= (c-b).magnitude and edg2 >= 0 then | |
| 642 | a, b, c = b, c, a | |
| 643 | elseif edg3 <= (a-c).magnitude and edg3 >= 0 then | |
| 644 | a, b, c = c, a, b | |
| 645 | else | |
| 646 | assert(false, "unreachable") | |
| 647 | end | |
| 648 | ||
| 649 | local len1 = (c-a):Dot((b-a).unit) | |
| 650 | local len2 = (b-a).magnitude - len1 | |
| 651 | local width = (a + (b-a).unit*len1 - c).magnitude | |
| 652 | ||
| 653 | local maincf = CFrameFromTopBack(a, (b-a):Cross(c-b).unit, -(b-a).unit) | |
| 654 | ||
| 655 | local list = {}
| |
| 656 | ||
| 657 | if len1 > 0.01 then | |
| 658 | local w1 = Instance.new('WedgePart', m)
| |
| 659 | game:GetService("Debris"):AddItem(w1,5)
| |
| 660 | w1.Material = "SmoothPlastic" | |
| 661 | w1.FormFactor = 'Custom' | |
| 662 | w1.BrickColor = BrickColor.new("Really red")
| |
| 663 | w1.Transparency = 0 | |
| 664 | w1.Reflectance = 0 | |
| 665 | w1.Material = "SmoothPlastic" | |
| 666 | w1.CanCollide = false | |
| 667 | local l1 = Instance.new("PointLight",w1)
| |
| 668 | l1.Color = Color3.new(170,0,0) | |
| 669 | NoOutline(w1) | |
| 670 | local sz = Vector3.new(0.2, width, len1) | |
| 671 | w1.Size = sz | |
| 672 | local sp = Instance.new("SpecialMesh",w1)
| |
| 673 | sp.MeshType = "Wedge" | |
| 674 | sp.Scale = Vector3.new(0,1,1) * sz/w1.Size | |
| 675 | w1:BreakJoints() | |
| 676 | w1.Anchored = true | |
| 677 | w1.Parent = workspace | |
| 678 | w1.Transparency = 0.7 | |
| 679 | table.insert(Effects,{w1,"Disappear",.01})
| |
| 680 | w1.CFrame = maincf*CFrame.Angles(math.pi,0,math.pi/2)*CFrame.new(0,width/2,len1/2) | |
| 681 | table.insert(list,w1) | |
| 682 | end | |
| 683 | ||
| 684 | if len2 > 0.01 then | |
| 685 | local w2 = Instance.new('WedgePart', m)
| |
| 686 | game:GetService("Debris"):AddItem(w2,5)
| |
| 687 | w2.Material = "SmoothPlastic" | |
| 688 | w2.FormFactor = 'Custom' | |
| 689 | w2.BrickColor = BrickColor.new("Really red")
| |
| 690 | w2.Transparency = 0 | |
| 691 | w2.Reflectance = 0 | |
| 692 | w2.Material = "SmoothPlastic" | |
| 693 | w2.CanCollide = false | |
| 694 | local l2 = Instance.new("PointLight",w2)
| |
| 695 | l2.Color = Color3.new(170,0,0) | |
| 696 | NoOutline(w2) | |
| 697 | local sz = Vector3.new(0.2, width, len2) | |
| 698 | w2.Size = sz | |
| 699 | local sp = Instance.new("SpecialMesh",w2)
| |
| 700 | sp.MeshType = "Wedge" | |
| 701 | sp.Scale = Vector3.new(0,1,1) * sz/w2.Size | |
| 702 | w2:BreakJoints() | |
| 703 | w2.Anchored = true | |
| 704 | w2.Parent = workspace | |
| 705 | w2.Transparency = 0.7 | |
| 706 | table.insert(Effects,{w2,"Disappear",.01})
| |
| 707 | w2.CFrame = maincf*CFrame.Angles(math.pi,math.pi,-math.pi/2)*CFrame.new(0,width/2,-len1 - len2/2) | |
| 708 | table.insert(list,w2) | |
| 709 | end | |
| 710 | return unpack(list) | |
| 711 | end | |
| 712 | ||
| 713 | ||
| 714 | function Damagefunc(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) | |
| 715 | if hit.Parent == nil then | |
| 716 | return | |
| 717 | end | |
| 718 | local h = hit.Parent:FindFirstChild("Humanoid")
| |
| 719 | for _, v in pairs(hit.Parent:children()) do | |
| 720 | if v:IsA("Humanoid") then
| |
| 721 | h = v | |
| 722 | end | |
| 723 | end | |
| 724 | if h ~= nil and hit.Parent.Name ~= Character.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
| |
| 725 | if hit.Parent:findFirstChild("DebounceHit") ~= nil and hit.Parent.DebounceHit.Value == true then
| |
| 726 | return | |
| 727 | end | |
| 728 | local c = Create("ObjectValue")({
| |
| 729 | Name = "creator", | |
| 730 | Value = game:service("Players").LocalPlayer,
| |
| 731 | Parent = h | |
| 732 | }) | |
| 733 | game:GetService("Debris"):AddItem(c, 0.5)
| |
| 734 | if HitSound ~= nil and HitPitch ~= nil then | |
| 735 | CFuncs.Sound.Create(HitSound, hit, 1, HitPitch) | |
| 736 | end | |
| 737 | local Damage = math.random(minim, maxim) | |
| 738 | local blocked = false | |
| 739 | local block = hit.Parent:findFirstChild("Block")
| |
| 740 | if block ~= nil and block.className == "IntValue" and block.Value > 0 then | |
| 741 | blocked = true | |
| 742 | block.Value = block.Value - 1 | |
| 743 | print(block.Value) | |
| 744 | end | |
| 745 | if blocked == false then | |
| 746 | HitHealth = h.Health | |
| 747 | h.Health = h.Health - Damage | |
| 748 | if HitHealth ~= h.Health and HitHealth ~= 0 and 0 >= h.Health and h.Parent.Name ~= "Hologram" then | |
| 749 | print("gained kill")
| |
| 750 | end | |
| 751 | ShowDamage(Part.CFrame * CFrame.new(0, 0, Part.Size.Z / 2).p + Vector3.new(0, 1.5, 0), -Damage, 1.5, Part.BrickColor.Color) | |
| 752 | else | |
| 753 | h.Health = h.Health - Damage / 2 | |
| 754 | ShowDamage(Part.CFrame * CFrame.new(0, 0, Part.Size.Z / 2).p + Vector3.new(0, 1.5, 0), -Damage, 1.5, Part.BrickColor.Color) | |
| 755 | end | |
| 756 | if Type == "Knockdown" then | |
| 757 | local hum = hit.Parent.Humanoid | |
| 758 | hum.PlatformStand = true | |
| 759 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 760 | swait(1) | |
| 761 | HHumanoid.PlatformStand = false | |
| 762 | end), hum) | |
| 763 | local angle = hit.Position - (Property.Position + Vector3.new(0, 0, 0)).unit | |
| 764 | local bodvol = Create("BodyVelocity")({
| |
| 765 | velocity = angle * knockback, | |
| 766 | P = 5000, | |
| 767 | maxForce = Vector3.new(8000, 8000, 8000), | |
| 768 | Parent = hit | |
| 769 | }) | |
| 770 | local rl = Create("BodyAngularVelocity")({
| |
| 771 | P = 3000, | |
| 772 | maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000, | |
| 773 | angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)), | |
| 774 | Parent = hit | |
| 775 | }) | |
| 776 | game:GetService("Debris"):AddItem(bodvol, 0.5)
| |
| 777 | game:GetService("Debris"):AddItem(rl, 0.5)
| |
| 778 | elseif Type == "Normal" then | |
| 779 | local vp = Create("BodyVelocity")({
| |
| 780 | P = 500, | |
| 781 | maxForce = Vector3.new(math.huge, 0, math.huge), | |
| 782 | velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05 | |
| 783 | }) | |
| 784 | if knockback > 0 then | |
| 785 | vp.Parent = hit.Parent.Torso | |
| 786 | end | |
| 787 | game:GetService("Debris"):AddItem(vp, 0.5)
| |
| 788 | elseif Type == "Up" then | |
| 789 | local bodyVelocity = Create("BodyVelocity")({
| |
| 790 | velocity = Vector3.new(0, 20, 0), | |
| 791 | P = 5000, | |
| 792 | maxForce = Vector3.new(8000, 8000, 8000), | |
| 793 | Parent = hit | |
| 794 | }) | |
| 795 | game:GetService("Debris"):AddItem(bodyVelocity, 0.5)
| |
| 796 | local bodyVelocity = Create("BodyVelocity")({
| |
| 797 | velocity = Vector3.new(0, 20, 0), | |
| 798 | P = 5000, | |
| 799 | maxForce = Vector3.new(8000, 8000, 8000), | |
| 800 | Parent = hit | |
| 801 | }) | |
| 802 | game:GetService("Debris"):AddItem(bodyVelocity, 1)
| |
| 803 | elseif Type == "Leech" then | |
| 804 | local hum = hit.Parent.Humanoid | |
| 805 | if hum ~= nil then | |
| 806 | for i = 0, 2 do | |
| 807 | Effects.Sphere.Create(BrickColor.new("Bright red"), hit.Parent.Torso.CFrame * cn(0, 0, 0) * angles(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)), 1, 15, 1, 0, 5, 0, 0.02)
| |
| 808 | end | |
| 809 | Humanoid.Health = Humanoid.Health + 10 | |
| 810 | end | |
| 811 | elseif Type == "UpKnock" then | |
| 812 | local hum = hit.Parent.Humanoid | |
| 813 | hum.PlatformStand = true | |
| 814 | if hum ~= nil then | |
| 815 | hitr = true | |
| 816 | end | |
| 817 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 818 | swait(5) | |
| 819 | HHumanoid.PlatformStand = false | |
| 820 | hitr = false | |
| 821 | end), hum) | |
| 822 | local bodyVelocity = Create("BodyVelocity")({
| |
| 823 | velocity = Vector3.new(0, 20, 0), | |
| 824 | P = 5000, | |
| 825 | maxForce = Vector3.new(8000, 8000, 8000), | |
| 826 | Parent = hit | |
| 827 | }) | |
| 828 | game:GetService("Debris"):AddItem(bodyVelocity, 0.5)
| |
| 829 | local bodyVelocity = Create("BodyVelocity")({
| |
| 830 | velocity = Vector3.new(0, 20, 0), | |
| 831 | P = 5000, | |
| 832 | maxForce = Vector3.new(8000, 8000, 8000), | |
| 833 | Parent = hit | |
| 834 | }) | |
| 835 | game:GetService("Debris"):AddItem(bodyVelocity, 1)
| |
| 836 | elseif Type == "Snare" then | |
| 837 | local bp = Create("BodyPosition")({
| |
| 838 | P = 2000, | |
| 839 | D = 100, | |
| 840 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 841 | position = hit.Parent.Torso.Position, | |
| 842 | Parent = hit.Parent.Torso | |
| 843 | }) | |
| 844 | game:GetService("Debris"):AddItem(bp, 1)
| |
| 845 | elseif Type == "Slashnare" then | |
| 846 | Effects.Block.Create(BrickColor.new("Pastel Blue"), hit.Parent.Torso.CFrame * cn(0, 0, 0), 15*4, 15*4, 15*4, 3*4, 3*4, 3*4, 0.07)
| |
| 847 | for i = 1, math.random(4, 5) do | |
| 848 | Effects.Sphere.Create(BrickColor.new("Teal"), hit.Parent.Torso.CFrame * cn(math.random(-5, 5), math.random(-5, 5), math.random(-5, 5)) * angles(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)), 1, 15, 1, 0, 5, 0, 0.02)
| |
| 849 | end | |
| 850 | local bp = Create("BodyPosition")({
| |
| 851 | P = 2000, | |
| 852 | D = 100, | |
| 853 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 854 | position = hit.Parent.Torso.Position, | |
| 855 | Parent = hit.Parent.Torso | |
| 856 | }) | |
| 857 | game:GetService("Debris"):AddItem(bp, 1)
| |
| 858 | elseif Type == "Spike" then | |
| 859 | CreateBigIceSword(hit.Parent.Torso.CFrame) | |
| 860 | local bp = Create("BodyPosition")({
| |
| 861 | P = 2000, | |
| 862 | D = 100, | |
| 863 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 864 | position = hit.Parent.Torso.Position, | |
| 865 | Parent = hit.Parent.Torso | |
| 866 | }) | |
| 867 | game:GetService("Debris"):AddItem(bp, 1)
| |
| 868 | elseif Type == "Freeze" then | |
| 869 | local BodPos = Create("BodyPosition")({
| |
| 870 | P = 50000, | |
| 871 | D = 1000, | |
| 872 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 873 | position = hit.Parent.Torso.Position, | |
| 874 | Parent = hit.Parent.Torso | |
| 875 | }) | |
| 876 | local BodGy = Create("BodyGyro")({
| |
| 877 | maxTorque = Vector3.new(400000, 400000, 400000) * math.huge, | |
| 878 | P = 20000, | |
| 879 | Parent = hit.Parent.Torso, | |
| 880 | cframe = hit.Parent.Torso.CFrame | |
| 881 | }) | |
| 882 | hit.Parent.Torso.Anchored = true | |
| 883 | coroutine.resume(coroutine.create(function(Part) | |
| 884 | swait(1.5) | |
| 885 | Part.Anchored = false | |
| 886 | end), hit.Parent.Torso) | |
| 887 | game:GetService("Debris"):AddItem(BodPos, 3)
| |
| 888 | game:GetService("Debris"):AddItem(BodGy, 3)
| |
| 889 | end | |
| 890 | local debounce = Create("BoolValue")({
| |
| 891 | Name = "DebounceHit", | |
| 892 | Parent = hit.Parent, | |
| 893 | Value = true | |
| 894 | }) | |
| 895 | game:GetService("Debris"):AddItem(debounce, Delay)
| |
| 896 | c = Instance.new("ObjectValue")
| |
| 897 | c.Name = "creator" | |
| 898 | c.Value = Player | |
| 899 | c.Parent = h | |
| 900 | game:GetService("Debris"):AddItem(c, 0.5)
| |
| 901 | end | |
| 902 | end | |
| 903 | function ShowDamage(Pos, Text, Time, Color) | |
| 904 | local Rate = 0.1 | |
| 905 | local Pos = Pos or Vector3.new(0, 0, 0) | |
| 906 | local Text = Text or "" | |
| 907 | local Time = Time or 2 | |
| 908 | local Color = Color or Color3.new(1, 0, 1) | |
| 909 | local EffectPart = CreatePart(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0)) | |
| 910 | EffectPart.Anchored = true | |
| 911 | local BillboardGui = Create("BillboardGui")({
| |
| 912 | Size = UDim2.new(3, 0, 3, 0), | |
| 913 | Adornee = EffectPart, | |
| 914 | Parent = EffectPart | |
| 915 | }) | |
| 916 | local TextLabel = Create("TextLabel")({
| |
| 917 | BackgroundTransparency = 1, | |
| 918 | Size = UDim2.new(1, 0, 1, 0), | |
| 919 | Text = Text, | |
| 920 | TextColor3 = Color3.new(1,1,1), | |
| 921 | TextStrokeColor3 = Color3.new(0,0,0), | |
| 922 | TextStrokeTransparency = 0.25, | |
| 923 | TextScaled = true, | |
| 924 | Font = Enum.Font.Fantasy, | |
| 925 | TextSize = 24, | |
| 926 | Parent = BillboardGui | |
| 927 | }) | |
| 928 | game.Debris:AddItem(EffectPart, Time + 0.1) | |
| 929 | EffectPart.Parent = game:GetService("Workspace")
| |
| 930 | delay(0, function() | |
| 931 | local Frames = Time / Rate | |
| 932 | for Frame = 1, Frames do | |
| 933 | swait(Rate) | |
| 934 | local Percent = Frame / Frames | |
| 935 | EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent*2, 0) | |
| 936 | TextLabel.TextTransparency = Percent | |
| 937 | TextLabel.TextStrokeTransparency = Percent | |
| 938 | end | |
| 939 | if EffectPart and EffectPart.Parent then | |
| 940 | EffectPart:Destroy() | |
| 941 | end | |
| 942 | end) | |
| 943 | end | |
| 944 | function MagniDamage(Part, magni, mindam, maxdam, knock, Type) | |
| 945 | for _, c in pairs(workspace:children()) do | |
| 946 | local hum = c:findFirstChild("Humanoid")
| |
| 947 | if hum ~= nil then | |
| 948 | local head = c:findFirstChild("Torso")
| |
| 949 | if head ~= nil then | |
| 950 | local targ = head.Position - Part.Position | |
| 951 | local mag = targ.magnitude | |
| 952 | if magni >= mag and c.Name ~= Player.Name then | |
| 953 | Damagefunc(head, head, mindam, maxdam, knock, Type, RootPart, 0.1, "rbxassetid://231917784", 1) | |
| 954 | end | |
| 955 | end | |
| 956 | end | |
| 957 | end | |
| 958 | end | |
| 959 | ||
| 960 | function MagniDamageWithEffect(Part, magni, mindam, maxdam, knock, Type) | |
| 961 | for _, c in pairs(workspace:children()) do | |
| 962 | local hum = c:findFirstChild("Humanoid")
| |
| 963 | if hum ~= nil then | |
| 964 | local head = c:findFirstChild("Torso")
| |
| 965 | if head ~= nil then | |
| 966 | local targ = head.Position - Part.Position | |
| 967 | local mag = targ.magnitude | |
| 968 | if magni >= mag and c.Name ~= Player.Name then | |
| 969 | MagicBlock(BrickColor.new("Dark indigo"),head.CFrame,5,5,5,1,1,1,0.05)
| |
| 970 | Damagefunc(head, head, mindam, maxdam, knock, Type, RootPart, 0.1, "rbxassetid://231917784", 1) | |
| 971 | end | |
| 972 | end | |
| 973 | end | |
| 974 | end | |
| 975 | end | |
| 976 | ||
| 977 | function rayCast(Pos, Dir, Max, Ignore) -- Origin Position , Direction, MaxDistance , IgnoreDescendants | |
| 978 | return game:service("Workspace"):FindPartOnRay(Ray.new(Pos, Dir.unit * (Max or 999.999)), Ignore)
| |
| 979 | end | |
| 980 | ||
| 981 | function SkullEffect(brickcolor,cframe,x1,y1,z1,delay) | |
| 982 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 983 | prt.Anchored=true | |
| 984 | prt.CFrame=cframe | |
| 985 | local msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=4770583",vt(0,0,0),vt(x1,y1,z1))
| |
| 986 | --http://www.roblox.com/asset/?id=4770560 | |
| 987 | game:GetService("Debris"):AddItem(prt,2)
| |
| 988 | CF=prt.CFrame | |
| 989 | coroutine.resume(coroutine.create(function(Part,Mesh,TehCF) | |
| 990 | for i=0,1,0.2 do | |
| 991 | wait() | |
| 992 | Part.CFrame=CF*cf(0,0,-0.4) | |
| 993 | end | |
| 994 | for i=0,1,delay do | |
| 995 | wait() | |
| 996 | --Part.CFrame=CF*cf((math.random(-1,0)+math.random())/5,(math.random(-1,0)+math.random())/5,(math.random(-1,0)+math.random())/5) | |
| 997 | Mesh.Scale=Mesh.Scale | |
| 998 | end | |
| 999 | for i=0,1,0.1 do | |
| 1000 | wait() | |
| 1001 | Part.Transparency=i | |
| 1002 | end | |
| 1003 | Part.Parent=nil | |
| 1004 | end),prt,msh,CF) | |
| 1005 | end | |
| 1006 | ||
| 1007 | function MagicBlock(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1008 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1009 | prt.Anchored=true | |
| 1010 | prt.Material = "Neon" | |
| 1011 | prt.CFrame=cframe | |
| 1012 | prt.CFrame=prt.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1013 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1014 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1015 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1016 | for i=0,1,delay do | |
| 1017 | swait() | |
| 1018 | Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1019 | Part.Transparency=i | |
| 1020 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1021 | end | |
| 1022 | Part.Parent=nil | |
| 1023 | end),prt,msh) | |
| 1024 | end | |
| 1025 | ||
| 1026 | function MagicBlockSteady(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay,rottype) | |
| 1027 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1028 | prt.Anchored=true | |
| 1029 | prt.Material = "Neon" | |
| 1030 | prt.CFrame=cframe | |
| 1031 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1032 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1033 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1034 | local rtype = rottype | |
| 1035 | for i=0,1,delay do | |
| 1036 | swait() | |
| 1037 | if rtype == 1 then | |
| 1038 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1039 | elseif rtype == 2 then | |
| 1040 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1041 | end | |
| 1042 | Part.Transparency=i | |
| 1043 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1044 | end | |
| 1045 | Part.Parent=nil | |
| 1046 | end),prt,msh) | |
| 1047 | end | |
| 1048 | ||
| 1049 | function MagicSphere(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1050 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1051 | prt.Anchored=true | |
| 1052 | prt.CFrame=cframe | |
| 1053 | prt.CFrame=prt.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1054 | msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1055 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1056 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1057 | for i=0,1,delay do | |
| 1058 | wait() | |
| 1059 | Part.Transparency=i | |
| 1060 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1061 | end | |
| 1062 | Part.Parent=nil | |
| 1063 | end),prt,msh) | |
| 1064 | end | |
| 1065 | ||
| 1066 | function MagicBlockSteady(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay,rottype) | |
| 1067 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1068 | prt.Anchored=true | |
| 1069 | prt.Material = "Neon" | |
| 1070 | prt.CFrame=cframe | |
| 1071 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1072 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1073 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1074 | local rtype = rottype | |
| 1075 | for i=0,1,delay do | |
| 1076 | swait() | |
| 1077 | if rtype == 1 then | |
| 1078 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1079 | elseif rtype == 2 then | |
| 1080 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1081 | end | |
| 1082 | Part.Transparency=i | |
| 1083 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1084 | end | |
| 1085 | Part.Parent=nil | |
| 1086 | end),prt,msh) | |
| 1087 | end | |
| 1088 | ||
| 1089 | function MagicShock(brickcolor,cframe,x1,y1,x3,y3,delay,rottype) | |
| 1090 | local prt=part(3,char,1,1,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1091 | prt.Anchored=true | |
| 1092 | prt.Material = "Neon" | |
| 1093 | prt.CFrame=cframe | |
| 1094 | local dec = decal(prt.Color,"http://www.roblox.com/asset/?id=874580939","Front",prt) | |
| 1095 | local dec2 = decal(prt.Color,"http://www.roblox.com/asset/?id=874580939","Front",prt) | |
| 1096 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,0.01))
| |
| 1097 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1098 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1099 | local rtype = rottype | |
| 1100 | for i=0,1,delay do | |
| 1101 | swait() | |
| 1102 | if rtype == 1 then | |
| 1103 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1104 | elseif rtype == 2 then | |
| 1105 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1106 | end | |
| 1107 | dec.Transparency=i | |
| 1108 | dec2.Transparency=i | |
| 1109 | Mesh.Scale=Mesh.Scale+vt(x3,y3,0) | |
| 1110 | end | |
| 1111 | Part.Parent=nil | |
| 1112 | end),prt,msh) | |
| 1113 | end | |
| 1114 | ||
| 1115 | function MagicShockAlt(brickcolor,cframe,x1,y1,x3,y3,delay,rottype) | |
| 1116 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1117 | prt.Anchored=true | |
| 1118 | prt.Material = "Neon" | |
| 1119 | prt.CFrame=cframe | |
| 1120 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,0.01))
| |
| 1121 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1122 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1123 | local rtype = rottype | |
| 1124 | for i=0,1,delay do | |
| 1125 | swait() | |
| 1126 | if rtype == 1 then | |
| 1127 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1128 | elseif rtype == 2 then | |
| 1129 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1130 | end | |
| 1131 | prt.Transparency=i | |
| 1132 | Mesh.Scale=Mesh.Scale+vt(x3,y3,0) | |
| 1133 | end | |
| 1134 | Part.Parent=nil | |
| 1135 | end),prt,msh) | |
| 1136 | end | |
| 1137 | ||
| 1138 | function MagicShockAltCircle(brickcolor,cframe,x1,z1,x3,z3,delay,rottype) | |
| 1139 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1140 | prt.Anchored=true | |
| 1141 | prt.Material = "Neon" | |
| 1142 | prt.CFrame=cframe | |
| 1143 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,1,z1))
| |
| 1144 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1145 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1146 | local rtype = rottype | |
| 1147 | for i=0,1,delay do | |
| 1148 | swait() | |
| 1149 | if rtype == 1 then | |
| 1150 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0.1,0) | |
| 1151 | elseif rtype == 2 then | |
| 1152 | prt.CFrame = prt.CFrame*CFrame.Angles(0,-0.1,0) | |
| 1153 | end | |
| 1154 | prt.Transparency=i | |
| 1155 | Mesh.Scale=Mesh.Scale+vt(x3,0,z3) | |
| 1156 | end | |
| 1157 | Part.Parent=nil | |
| 1158 | end),prt,msh) | |
| 1159 | end | |
| 1160 | ||
| 1161 | function MagicShockTrailAlt(brickcolor,cframe,x1,y1,z1,x3,y3,delay,rottype) | |
| 1162 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1163 | prt.Anchored=true | |
| 1164 | prt.Material = "Neon" | |
| 1165 | prt.CFrame=cframe | |
| 1166 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1167 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1168 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1169 | local rtype = rottype | |
| 1170 | for i=0,1,delay do | |
| 1171 | swait() | |
| 1172 | if rtype == 1 then | |
| 1173 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1174 | elseif rtype == 2 then | |
| 1175 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1176 | end | |
| 1177 | prt.Transparency=i | |
| 1178 | Mesh.Scale=Mesh.Scale+vt(x3,y3,0) | |
| 1179 | end | |
| 1180 | Part.Parent=nil | |
| 1181 | end),prt,msh) | |
| 1182 | end | |
| 1183 | ||
| 1184 | function MagicShockTrailAlt2(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay,rottype) | |
| 1185 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1186 | prt.Anchored=true | |
| 1187 | prt.Material = "Neon" | |
| 1188 | prt.CFrame=cframe | |
| 1189 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1190 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1191 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1192 | local rtype = rottype | |
| 1193 | for i=0,1,delay do | |
| 1194 | swait() | |
| 1195 | if rtype == 1 then | |
| 1196 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,0.1) | |
| 1197 | elseif rtype == 2 then | |
| 1198 | prt.CFrame = prt.CFrame*CFrame.Angles(0,0,-0.1) | |
| 1199 | end | |
| 1200 | prt.Transparency=i | |
| 1201 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1202 | end | |
| 1203 | Part.Parent=nil | |
| 1204 | end),prt,msh) | |
| 1205 | end | |
| 1206 | ||
| 1207 | function MagicBlock2(brickcolor,cframe,Parent,x1,y1,z1,x3,y3,z3,delay) | |
| 1208 | local prt=part(3,char,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1209 | prt.Anchored=false | |
| 1210 | prt.CFrame=cframe | |
| 1211 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1212 | local wld=weld(prt,prt,Parent,cframe) | |
| 1213 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1214 | coroutine.resume(coroutine.create(function(Part,Mesh,Weld) | |
| 1215 | for i=0,1,delay do | |
| 1216 | wait() | |
| 1217 | Weld.C0=euler(math.random(-50,50),math.random(-50,50),math.random(-50,50))*cframe | |
| 1218 | --Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1219 | Part.Transparency=i | |
| 1220 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1221 | end | |
| 1222 | Part.Parent=nil | |
| 1223 | end),prt,msh,wld) | |
| 1224 | end | |
| 1225 | ||
| 1226 | function MagicBlock3(brickcolor,cframe,Parent,x1,y1,z1,x3,y3,z3,delay) | |
| 1227 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1228 | prt.Anchored=false | |
| 1229 | prt.CFrame=cframe | |
| 1230 | msh=mesh("BlockMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1231 | local wld=weld(prt,prt,Parent,euler(0,0,0)*cf(0,0,0)) | |
| 1232 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1233 | coroutine.resume(coroutine.create(function(Part,Mesh,Weld) | |
| 1234 | for i=0,1,delay do | |
| 1235 | wait() | |
| 1236 | Weld.C0=euler(i*20,0,0) | |
| 1237 | --Part.CFrame=Part.CFrame*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1238 | Part.Transparency=i | |
| 1239 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1240 | end | |
| 1241 | Part.Parent=nil | |
| 1242 | end),prt,msh,wld) | |
| 1243 | end | |
| 1244 | ||
| 1245 | function MagicCircle2(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1246 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1247 | prt.Anchored=true | |
| 1248 | prt.CFrame=cframe | |
| 1249 | local msh=mesh("CylinderMesh",prt,"","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1250 | game:GetService("Debris"):AddItem(prt,2)
| |
| 1251 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1252 | for i=0,1,delay do | |
| 1253 | wait() | |
| 1254 | Part.CFrame=Part.CFrame | |
| 1255 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1256 | local prt2=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1257 | prt2.Anchored=true | |
| 1258 | prt2.CFrame=cframe*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1259 | local msh2=mesh("SpecialMesh",prt2,"Sphere","",vt(0,0,0),vt(0.5,0.5,0.5))
| |
| 1260 | game:GetService("Debris"):AddItem(prt2,2)
| |
| 1261 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1262 | for i=0,1,0.1 do | |
| 1263 | wait() | |
| 1264 | Part.CFrame=Part.CFrame*cf(0,0.5,0) | |
| 1265 | end | |
| 1266 | Part.Parent=nil | |
| 1267 | end),prt2,msh2) | |
| 1268 | end | |
| 1269 | for i=0,1,delay*2 do | |
| 1270 | wait() | |
| 1271 | Part.CFrame=Part.CFrame | |
| 1272 | Mesh.Scale=vt((x1+x3)-(x1+x3)*i,(y1+y3)-(y1+y3)*i,(z1+z3)-(z1+z3)*i) | |
| 1273 | end | |
| 1274 | Part.Parent=nil | |
| 1275 | end),prt,msh) | |
| 1276 | end | |
| 1277 | ||
| 1278 | function MagicCircle(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1279 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1280 | prt.Anchored=true | |
| 1281 | prt.CFrame=cframe | |
| 1282 | local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1283 | game:GetService("Debris"):AddItem(prt,2)
| |
| 1284 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1285 | for i=0,1,delay do | |
| 1286 | wait() | |
| 1287 | Part.CFrame=Part.CFrame | |
| 1288 | Part.Transparency=i | |
| 1289 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1290 | end | |
| 1291 | Part.Parent=nil | |
| 1292 | end),prt,msh) | |
| 1293 | end | |
| 1294 | ||
| 1295 | function BreakEffect(brickcolor,cframe,x1,y1,z1) | |
| 1296 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1297 | prt.Anchored=true | |
| 1298 | prt.CFrame=cframe*euler(math.random(-50,50),math.random(-50,50),math.random(-50,50)) | |
| 1299 | local msh=mesh("SpecialMesh",prt,"Sphere","",vt(0,0,0),vt(x1,y1,z1))
| |
| 1300 | game:GetService("Debris"):AddItem(prt,2)
| |
| 1301 | coroutine.resume(coroutine.create(function(Part,CF,Numbb,randnumb) | |
| 1302 | CF=Part.CFrame | |
| 1303 | Numbb=0 | |
| 1304 | randnumb=math.random()/10 | |
| 1305 | rand1=math.random()/10 | |
| 1306 | for i=0,1,rand1 do | |
| 1307 | wait() | |
| 1308 | CF=CF*cf(0,math.random()/2,0) | |
| 1309 | --Part.CFrame=Part.CFrame*euler(0.5,0,0)*cf(0,1,0) | |
| 1310 | Part.CFrame=CF*euler(Numbb,0,0) | |
| 1311 | Part.Transparency=i | |
| 1312 | Numbb=Numbb+randnumb | |
| 1313 | end | |
| 1314 | Part.Parent=nil | |
| 1315 | end),prt,CF,Numbb,randnumb) | |
| 1316 | end | |
| 1317 | ||
| 1318 | function MagicWaveThing(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1319 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1320 | prt.Anchored=true | |
| 1321 | prt.CFrame=cframe | |
| 1322 | msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=1051557",vt(0,0,0),vt(x1,y1,z1))
| |
| 1323 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1324 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1325 | for i=0,1,delay do | |
| 1326 | wait() | |
| 1327 | Part.CFrame=Part.CFrame*euler(0,0.7,0) | |
| 1328 | Part.Transparency=i | |
| 1329 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1330 | end | |
| 1331 | Part.Parent=nil | |
| 1332 | end),prt,msh) | |
| 1333 | end | |
| 1334 | ||
| 1335 | function WaveEffect(brickcolor,cframe,x1,y1,z1,x3,y3,z3,delay) | |
| 1336 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1337 | prt.Anchored=true | |
| 1338 | prt.CFrame=cframe | |
| 1339 | msh=mesh("SpecialMesh",prt,"FileMesh","http://www.roblox.com/asset/?id=20329976",vt(0,0,0),vt(x1,y1,z1))
| |
| 1340 | game:GetService("Debris"):AddItem(prt,2)
| |
| 1341 | coroutine.resume(coroutine.create(function(Part,Mesh) | |
| 1342 | for i=0,1,delay do | |
| 1343 | wait() | |
| 1344 | Part.CFrame=Part.CFrame*cf(0,y3/2,0) | |
| 1345 | Part.Transparency=i | |
| 1346 | Mesh.Scale=Mesh.Scale+vt(x3,y3,z3) | |
| 1347 | end | |
| 1348 | Part.Parent=nil | |
| 1349 | end),prt,msh) | |
| 1350 | end | |
| 1351 | ||
| 1352 | function StravEffect(brickcolor,cframe,x,y,z,x1,y1,z1,delay) | |
| 1353 | local prt=part(3,workspace,0,0,brickcolor,"Effect",vt(0.5,0.5,0.5)) | |
| 1354 | prt.Anchored=true | |
| 1355 | prt.CFrame=cframe*cf(x,y,z) | |
| 1356 | msh=mesh("SpecialMesh",prt,"FileMesh","rbxassetid://168892363",vt(0,0,0),vt(x1,y1,z1))
| |
| 1357 | game:GetService("Debris"):AddItem(prt,5)
| |
| 1358 | coroutine.resume(coroutine.create(function(Part,Mesh,ex,why,zee) | |
| 1359 | local num=math.random() | |
| 1360 | local num2=math.random(-3,2)+math.random() | |
| 1361 | local numm=0 | |
| 1362 | for i=0,1,delay*2 do | |
| 1363 | swait() | |
| 1364 | Part.CFrame=cframe*euler(0,numm*num*10,0)*cf(ex,why,zee)*cf(-i*10,num2,0) | |
| 1365 | Part.Transparency=i | |
| 1366 | numm=numm+0.01 | |
| 1367 | end | |
| 1368 | Part.Parent=nil | |
| 1369 | Mesh.Parent=nil | |
| 1370 | end),prt,msh,x,y,z) | |
| 1371 | end | |
| 1372 | ||
| 1373 | function dmgstart(dmg,what) | |
| 1374 | hitcon = what.Touched:connect(function(hit) | |
| 1375 | local hum = hit.Parent:FindFirstChild("Humanoid")
| |
| 1376 | if hum and not hum:IsDescendantOf(Character) then | |
| 1377 | hum:TakeDamage(dmg) | |
| 1378 | end | |
| 1379 | end) | |
| 1380 | end | |
| 1381 | ||
| 1382 | function dmgstop() | |
| 1383 | hitcon:disconnect() | |
| 1384 | end | |
| 1385 | ||
| 1386 | function Cloak() | |
| 1387 | Face.Parent=nil | |
| 1388 | cloaked=true | |
| 1389 | for _,v in pairs(Torso.Parent:children()) do | |
| 1390 | if v.className=="Part" and v.Name~="HumanoidRootPart" then | |
| 1391 | coroutine.resume(coroutine.create(function() | |
| 1392 | for i=0,1,0.2 do | |
| 1393 | wait() | |
| 1394 | v.Transparency=i | |
| 1395 | end | |
| 1396 | v.Transparency=1 | |
| 1397 | end)) | |
| 1398 | end | |
| 1399 | if v.className=="Hat" then | |
| 1400 | hatp=v.Handle | |
| 1401 | coroutine.resume(coroutine.create(function(derp) | |
| 1402 | for i=0,1,0.2 do | |
| 1403 | wait() | |
| 1404 | derp.Transparency=i | |
| 1405 | end | |
| 1406 | derp.Transparency=1 | |
| 1407 | end),hatp) | |
| 1408 | end | |
| 1409 | end | |
| 1410 | for _,v in pairs(m:children()) do | |
| 1411 | if v.className=="Part" then | |
| 1412 | coroutine.resume(coroutine.create(function() | |
| 1413 | for i=0,1,0.2 do | |
| 1414 | wait() | |
| 1415 | v.Transparency=i | |
| 1416 | end | |
| 1417 | v.Transparency=1 | |
| 1418 | end)) | |
| 1419 | end | |
| 1420 | end | |
| 1421 | end | |
| 1422 | ||
| 1423 | function UnCloak() | |
| 1424 | so("http://roblox.com/asset/?id=2767090",Torso,1,1.1)
| |
| 1425 | Face.Parent=Head | |
| 1426 | cloaked=false | |
| 1427 | for _,v in pairs(Torso.Parent:children()) do | |
| 1428 | if v.className=="Part" and v.Name~="HumanoidRootPart" then | |
| 1429 | coroutine.resume(coroutine.create(function() | |
| 1430 | for i=0,1,0.1 do | |
| 1431 | wait() | |
| 1432 | v.Transparency=v.Transparency-0.1 | |
| 1433 | end | |
| 1434 | v.Transparency=0 | |
| 1435 | end)) | |
| 1436 | end | |
| 1437 | if v.className=="Hat" then | |
| 1438 | hatp=v.Handle | |
| 1439 | coroutine.resume(coroutine.create(function(derp) | |
| 1440 | for i=0,1,0.1 do | |
| 1441 | wait() | |
| 1442 | derp.Transparency=derp.Transparency-0.1 | |
| 1443 | end | |
| 1444 | derp.Transparency=0 | |
| 1445 | end),hatp) | |
| 1446 | end | |
| 1447 | end | |
| 1448 | for _,v in pairs(m:children()) do | |
| 1449 | if v.className=="Part" and v.Name~="hitbox" and v.Name~='tip' then | |
| 1450 | coroutine.resume(coroutine.create(function() | |
| 1451 | for i=0,1,0.1 do | |
| 1452 | wait() | |
| 1453 | v.Transparency=v.Transparency-0.1 | |
| 1454 | end | |
| 1455 | v.Transparency=0 | |
| 1456 | end)) | |
| 1457 | v.Transparency=0 | |
| 1458 | end | |
| 1459 | end | |
| 1460 | end | |
| 1461 | ||
| 1462 | local origcolor = BrickColor.new("Dark indigo")
| |
| 1463 | ---- This section of explosions. | |
| 1464 | function Explode(rad,par,pitch,vol,mindam,maxdam) | |
| 1465 | local expart = Instance.new("Part",char)
| |
| 1466 | local expart2 = Instance.new("Part",char)
| |
| 1467 | local rin = Instance.new("Part",char)
| |
| 1468 | local rin2 = Instance.new("Part",char)
| |
| 1469 | local partMesh = Instance.new("SpecialMesh",expart)
| |
| 1470 | partMesh.MeshType = "Sphere" | |
| 1471 | local partMesh2 = Instance.new("SpecialMesh",expart2)
| |
| 1472 | partMesh2.MeshType = "Sphere" | |
| 1473 | local partMesh3 = Instance.new("SpecialMesh",rin)
| |
| 1474 | partMesh3.MeshType = "Brick" | |
| 1475 | local partMesh4 = Instance.new("SpecialMesh",rin2)
| |
| 1476 | partMesh4.MeshType = "Brick" | |
| 1477 | CFuncs["Sound"].Create("rbxassetid://165970126", expart,vol, pitch)
| |
| 1478 | partMesh.Scale = vt(rad,rad,rad) | |
| 1479 | expart.Size = vt(1,1,1) | |
| 1480 | expart.Transparency = 1 | |
| 1481 | expart.Anchored = true | |
| 1482 | expart.Material = "Neon" | |
| 1483 | expart.BrickColor = bc("White")
| |
| 1484 | expart.CFrame = par.CFrame | |
| 1485 | partMesh2.Scale = vt(rad,rad,rad) | |
| 1486 | expart2.Size = vt(1.15,1.15,1.15) | |
| 1487 | expart2.Transparency = 0.75 | |
| 1488 | expart2.Anchored = true | |
| 1489 | expart2.Material = "Glass" | |
| 1490 | expart2.BrickColor = par.BrickColor | |
| 1491 | expart2.CFrame = par.CFrame | |
| 1492 | rin.Size = vt(1.15,1.15,1.15) | |
| 1493 | rin.Transparency = 1 | |
| 1494 | rin.Anchored = true | |
| 1495 | rin.Material = "Neon" | |
| 1496 | rin.BrickColor = par.BrickColor | |
| 1497 | rin.CFrame = par.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))) | |
| 1498 | rin2.Size = vt(1.15,1.15,1.15) | |
| 1499 | rin2.Transparency = 1 | |
| 1500 | rin2.Anchored = true | |
| 1501 | rin2.Material = "Neon" | |
| 1502 | rin2.BrickColor = par.BrickColor | |
| 1503 | rin2.CFrame = par.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))) | |
| 1504 | partMesh3.Scale = vt(0,1,0) | |
| 1505 | partMesh4.Scale = vt(0,1,0) | |
| 1506 | local dec2 = Instance.new("Decal", rin)
| |
| 1507 | dec2.Face = "Top" | |
| 1508 | dec2.Texture = "http://www.roblox.com/asset/?id=874580939" | |
| 1509 | dec2.Parent = rin | |
| 1510 | local dec2b = dec2:Clone() | |
| 1511 | dec2b.Face = "Bottom" | |
| 1512 | dec2b.Parent = rin | |
| 1513 | ||
| 1514 | local dec2a = Instance.new("Decal", rin2)
| |
| 1515 | dec2a.Face = "Top" | |
| 1516 | dec2a.Texture = "http://www.roblox.com/asset/?id=874580939" | |
| 1517 | dec2a.Parent = rin2 | |
| 1518 | local dec2ab = dec2a:Clone() | |
| 1519 | dec2ab.Face = "Bottom" | |
| 1520 | dec2ab.Parent = rin2 | |
| 1521 | expart.CanCollide = false | |
| 1522 | expart2.CanCollide = false | |
| 1523 | rin.CanCollide = false | |
| 1524 | rin2.CanCollide = false | |
| 1525 | MagniDamage(par, rad*5, mindam, maxdam, 0, "Normal") | |
| 1526 | local value = 1*rad/6.5 | |
| 1527 | for i = 0, 199 do | |
| 1528 | partMesh.Scale = partMesh.Scale + vt(value,value,value) | |
| 1529 | expart.CFrame = expart.CFrame | |
| 1530 | partMesh2.Scale = partMesh2.Scale + vt(value,value,value) | |
| 1531 | expart2.CFrame = expart.CFrame | |
| 1532 | value = value - 0.035*rad/30 | |
| 1533 | if value < 7.5 then | |
| 1534 | partMesh3.Scale = partMesh3.Scale + vt(rad/5,0,rad/5) | |
| 1535 | rin.CFrame = rin.CFrame*CFrame.Angles(0,math.rad(1),0) | |
| 1536 | partMesh4.Scale = partMesh4.Scale + vt(rad/7.5,0,rad/7.5) | |
| 1537 | rin2.CFrame = rin2.CFrame*CFrame.Angles(0,math.rad(-1),0) | |
| 1538 | end | |
| 1539 | if value < 0 then | |
| 1540 | dec2.Transparency = dec2.Transparency + 0.025 | |
| 1541 | dec2a.Transparency = dec2a.Transparency + 0.025 | |
| 1542 | dec2b.Transparency = dec2b.Transparency + 0.025 | |
| 1543 | dec2ab.Transparency = dec2ab.Transparency + 0.025 | |
| 1544 | expart.Transparency = expart.Transparency + 0.025 | |
| 1545 | expart2.Transparency = expart2.Transparency + 0.025 | |
| 1546 | rin.Transparency = rin.Transparency + 0.025 | |
| 1547 | rin2.Transparency = rin2.Transparency + 0.025 | |
| 1548 | end | |
| 1549 | swait() | |
| 1550 | end | |
| 1551 | game:GetService("Debris"):AddItem(expart, 1)
| |
| 1552 | game:GetService("Debris"):AddItem(expart2, 1)
| |
| 1553 | game:GetService("Debris"):AddItem(rin, 1)
| |
| 1554 | game:GetService("Debris"):AddItem(rin2, 1)
| |
| 1555 | end | |
| 1556 | ||
| 1557 | function ExplodeShort(rad,par,pitch,vol,mindam,maxdam) | |
| 1558 | local expart = Instance.new("Part",char)
| |
| 1559 | local expart2 = Instance.new("Part",char)
| |
| 1560 | local partMesh = Instance.new("SpecialMesh",expart)
| |
| 1561 | partMesh.MeshType = "Sphere" | |
| 1562 | local partMesh2 = Instance.new("SpecialMesh",expart2)
| |
| 1563 | partMesh2.MeshType = "Sphere" | |
| 1564 | CFuncs["Sound"].Create("http://www.roblox.com/asset/?id=142070127", expart,vol, pitch)
| |
| 1565 | partMesh.Scale = vt(rad,rad,rad) | |
| 1566 | expart.Size = vt(1,1,1) | |
| 1567 | expart.Transparency = 0 | |
| 1568 | expart.Anchored = true | |
| 1569 | expart.Material = "Neon" | |
| 1570 | expart.BrickColor = bc("White")
| |
| 1571 | expart.CFrame = par.CFrame | |
| 1572 | partMesh2.Scale = vt(rad,rad,rad) | |
| 1573 | expart2.Size = vt(1.15,1.15,1.15) | |
| 1574 | expart2.Transparency = 0.5 | |
| 1575 | expart2.Anchored = true | |
| 1576 | expart2.Material = "Neon" | |
| 1577 | expart2.BrickColor = par.BrickColor | |
| 1578 | expart2.CFrame = par.CFrame | |
| 1579 | expart.CanCollide = false | |
| 1580 | expart2.CanCollide = false | |
| 1581 | MagniDamage(par, rad*2.5, mindam, maxdam, 0, "Normal") | |
| 1582 | local value = 1*rad/6.5 | |
| 1583 | for i = 0, 75 do | |
| 1584 | partMesh.Scale = partMesh.Scale + vt(value,value,value) | |
| 1585 | expart.CFrame = expart.CFrame | |
| 1586 | partMesh2.Scale = partMesh2.Scale + vt(value,value,value) | |
| 1587 | expart2.CFrame = expart.CFrame | |
| 1588 | value = value - 0.035*rad/5 | |
| 1589 | if value < 0 then | |
| 1590 | value = 0 | |
| 1591 | expart.Transparency = expart.Transparency + 0.05 | |
| 1592 | expart2.Transparency = expart2.Transparency + 0.05 | |
| 1593 | end | |
| 1594 | swait() | |
| 1595 | end | |
| 1596 | game:GetService("Debris"):AddItem(expart, 1)
| |
| 1597 | game:GetService("Debris"):AddItem(expart2, 1)
| |
| 1598 | end | |
| 1599 | ||
| 1600 | function AreaDanger(rad,par,mindam,maxdam) | |
| 1601 | local expart = Instance.new("Part",char)
| |
| 1602 | local partMesh = Instance.new("SpecialMesh",expart)
| |
| 1603 | CFuncs["Sound"].Create("rbxassetid://231917784", expart,1.5,1.15)
| |
| 1604 | partMesh.MeshType = "Sphere" | |
| 1605 | partMesh.Scale = vt(rad,rad,rad) | |
| 1606 | expart.Size = vt(1,1,1) | |
| 1607 | expart.Transparency = 0.5 | |
| 1608 | expart.Anchored = true | |
| 1609 | expart.Material = "Neon" | |
| 1610 | expart.CanCollide = false | |
| 1611 | expart.BrickColor = par.BrickColor | |
| 1612 | expart.CFrame = par.CFrame | |
| 1613 | local value = 1*rad/5 | |
| 1614 | MagicBlock(origcolor,expart.CFrame,0,0,0,rad/2,rad/2,rad/2,0.1) | |
| 1615 | for i = 0, 14 do | |
| 1616 | wait() | |
| 1617 | partMesh.Scale = partMesh.Scale + vt(value,value,value) | |
| 1618 | expart.CFrame = expart.CFrame | |
| 1619 | value = value - 0.035*rad | |
| 1620 | if value < 0 then | |
| 1621 | value = 0 | |
| 1622 | end | |
| 1623 | end | |
| 1624 | wait(0.25) | |
| 1625 | CFuncs["Sound"].Create("rbxassetid://588738544", expart,1.5,1)
| |
| 1626 | wait(0.5) | |
| 1627 | CFuncs["Sound"].Create("rbxassetid://588737825", expart,1.5,1)
| |
| 1628 | CFuncs["Sound"].Create("rbxassetid://231917784", expart,1.5,0.75)
| |
| 1629 | MagniDamageWithEffect(par, rad, mindam, maxdam, 0, "Normal") | |
| 1630 | MagicBlock(origcolor,expart.CFrame,rad*2,rad*2,rad*2,0.1,0.1,0.1,0.025) | |
| 1631 | for i = 0, 14 do | |
| 1632 | wait() | |
| 1633 | partMesh.Scale = partMesh.Scale + vt(value,value,value) | |
| 1634 | expart.CFrame = expart.CFrame | |
| 1635 | value = value - 0.035*rad/2 | |
| 1636 | end | |
| 1637 | expart.Transparency = 1 | |
| 1638 | game:GetService("Debris"):AddItem(expart, 5)
| |
| 1639 | end | |
| 1640 | ||
| 1641 | function Swarmsplosions(negrad,rad,par,mindam,maxdam) | |
| 1642 | CFuncs["Sound"].Create("rbxassetid://588737825", par, 2.5, 2)
| |
| 1643 | CFuncs["Sound"].Create("rbxassetid://231917784", par, 2.5,1)
| |
| 1644 | CFuncs["Sound"].Create("rbxassetid://231917744", par, 2.5,1)
| |
| 1645 | CFuncs["Sound"].Create("rbxassetid://233856106", par, 2.5, 1)
| |
| 1646 | MagniDamageWithEffect(par, 25, 5,10, 0, "Normal") | |
| 1647 | MagicBlock(origcolor,par.CFrame,5,5,5,5,5,5,0.025) | |
| 1648 | for i = 0, 24 do | |
| 1649 | MagicShockTrailAlt2(origcolor,par.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),10/5,10/5,5,-0.05/5,-0.05/5,25,0.005,math.random(1,2)) | |
| 1650 | end | |
| 1651 | for i = 0, 24 do | |
| 1652 | local expart = Instance.new("Part",char)
| |
| 1653 | expart.Transparency = 1 | |
| 1654 | expart.Anchored = true | |
| 1655 | expart.CanCollide = false | |
| 1656 | expart.CFrame = par.CFrame*CFrame.new(math.random(negrad,rad),math.random(negrad,rad),math.random(negrad,rad)) | |
| 1657 | CFuncs["Sound"].Create("rbxassetid://588737825", expart,1,2)
| |
| 1658 | CFuncs["Sound"].Create("rbxassetid://231917784", expart,1.5,1.15)
| |
| 1659 | MagniDamage(expart, rad/2, mindam, maxdam, 0, "Normal") | |
| 1660 | MagicBlock(origcolor,expart.CFrame,rad,rad,rad,0.1,0.1,0.1,0.025) | |
| 1661 | for i = 0, 9 do | |
| 1662 | MagicShockTrailAlt2(origcolor,expart.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),10/5,10/5,5,-0.05/5,-0.05/5,5,0.05,math.random(1,2)) | |
| 1663 | end | |
| 1664 | game:GetService("Debris"):AddItem(expart, 2)
| |
| 1665 | wait(0.1) | |
| 1666 | end | |
| 1667 | end | |
| 1668 | ||
| 1669 | function EXterPlosion(par) | |
| 1670 | CFuncs["Sound"].Create("rbxassetid://919941001", par, 10, 1)
| |
| 1671 | CFuncs["Sound"].Create("rbxassetid://138213851", par, 5,0.85)
| |
| 1672 | CFuncs["Sound"].Create("rbxassetid://157878578", par, 5,0.2)
| |
| 1673 | CFuncs["Sound"].Create("rbxassetid://233856106", par, 2.5, 1)
| |
| 1674 | MagniDamageWithEffect(par, 500, 80,99, 0, "Normal") | |
| 1675 | MagicBlock(origcolor,par.CFrame,5,5,5,5,5,5,0.005) | |
| 1676 | MagicBlock(origcolor,par.CFrame,0,0,0,150,150,150,0.1) | |
| 1677 | for i = 0, 24 do | |
| 1678 | MagicShockTrailAlt2(origcolor,par.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),10*5,10*5,5,-0.05*10,-0.05*10,500,0.1,math.random(1,2)) | |
| 1679 | end | |
| 1680 | for i = 0, 24 do | |
| 1681 | MagicShockTrailAlt2(origcolor,par.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),10*5,10*5,5,-0.05*5,-0.05*5,50,0.005,math.random(1,2)) | |
| 1682 | end | |
| 1683 | end | |
| 1684 | ---- | |
| 1685 | function bullit() | |
| 1686 | attack = true | |
| 1687 | for i = 0,1,0.1 do | |
| 1688 | swait() | |
| 1689 | MagicBlock(origcolor,sorb.CFrame,3,3,3,0.05,0.05,0.05,0.05) | |
| 1690 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-80)),0.3) | |
| 1691 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(80)),.3) | |
| 1692 | RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.3) | |
| 1693 | LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(-90)), 0.3) | |
| 1694 | end | |
| 1695 | CFuncs["Sound"].Create("rbxassetid://558640653", sorb, 1.5, 1)
| |
| 1696 | local a = Instance.new("Part",Character)
| |
| 1697 | a.Name = "Direction" | |
| 1698 | a.Anchored = true | |
| 1699 | a.BrickColor = bc("Bright red")
| |
| 1700 | a.Material = "Neon" | |
| 1701 | a.Transparency = 1 | |
| 1702 | a.CanCollide = false | |
| 1703 | local ray = Ray.new( | |
| 1704 | sorb.CFrame.p, -- origin | |
| 1705 | (mouse.Hit.p - sorb.CFrame.p).unit * 500 -- direction | |
| 1706 | ) | |
| 1707 | local ignore = Character | |
| 1708 | local hit, position, normal = workspace:FindPartOnRay(ray, ignore) | |
| 1709 | a.BottomSurface = 10 | |
| 1710 | a.TopSurface = 10 | |
| 1711 | local distance = (root.CFrame.p - position).magnitude | |
| 1712 | a.Size = Vector3.new(0.1, 0.1, 0.1) | |
| 1713 | a.CFrame = CFrame.new(sorb.CFrame.p, position) * CFrame.new(0, 0, 0) | |
| 1714 | local lb = Instance.new("Part")
| |
| 1715 | lb.Parent = char | |
| 1716 | lb.BrickColor = origcolor | |
| 1717 | lb.CanCollide = false | |
| 1718 | lb.Material = "Glass" | |
| 1719 | lb.Anchored = true | |
| 1720 | lb.TopSurface = 0 | |
| 1721 | lb.BottomSurface = 0 | |
| 1722 | lb.Transparency = 0.75 | |
| 1723 | lb.Size = vt(0.5,0.5,0.5) | |
| 1724 | lb.CFrame = a.CFrame | |
| 1725 | lb.Anchored = false | |
| 1726 | local thingery = Instance.new("SpecialMesh",lb)
| |
| 1727 | thingery.MeshType = "Sphere" | |
| 1728 | thingery.Scale = vt(20,20,20) | |
| 1729 | game:GetService("Debris"):AddItem(lb, 10)
| |
| 1730 | local bv = Instance.new("BodyVelocity")
| |
| 1731 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
| 1732 | bv.velocity = a.CFrame.lookVector*150 | |
| 1733 | bv.Parent = lb | |
| 1734 | local hitted = false | |
| 1735 | game:GetService("Debris"):AddItem(a, 0.1)
| |
| 1736 | wait(0.01) | |
| 1737 | lb.Touched:connect(function(hit) | |
| 1738 | if hitted == false then | |
| 1739 | hitted = true | |
| 1740 | lb.Anchored = true | |
| 1741 | lb.Transparency = 1 | |
| 1742 | Explode(7.5,lb,1,1,10,15) | |
| 1743 | end | |
| 1744 | end) | |
| 1745 | for i = 0,2,0.1 do | |
| 1746 | swait() | |
| 1747 | MagicBlock(origcolor,sorb.CFrame,3,3,3,0.05,0.05,0.05,0.05) | |
| 1748 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(20),math.rad(0),math.rad(80)),0.5) | |
| 1749 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(-80)),.5) | |
| 1750 | RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(20)), 0.5) | |
| 1751 | LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5, 0) * angles(math.rad(50), math.rad(0), math.rad(-90)), 0.5) | |
| 1752 | end | |
| 1753 | attack = false | |
| 1754 | end | |
| 1755 | ||
| 1756 | ||
| 1757 | function RingEffect(pos,startsize,size,col) | |
| 1758 | local lb = Instance.new("Part")
| |
| 1759 | lb.Parent = char | |
| 1760 | lb.BrickColor = col | |
| 1761 | lb.CanCollide = false | |
| 1762 | lb.Material = "Neon" | |
| 1763 | lb.Anchored = true | |
| 1764 | lb.TopSurface = 0 | |
| 1765 | lb.BottomSurface = 0 | |
| 1766 | lb.Transparency = 1 | |
| 1767 | lb.Size = vt(1,1,1) | |
| 1768 | lb.CFrame = pos | |
| 1769 | local thingery = Instance.new("SpecialMesh",lb)
| |
| 1770 | thingery.MeshType = "Brick" | |
| 1771 | thingery.Scale = vt(startsize,0.1,startsize) | |
| 1772 | local dec2 = Instance.new("Texture", lb)
| |
| 1773 | dec2.Face = "Top" | |
| 1774 | dec2.Texture = "http://www.roblox.com/asset/?id=874580939" | |
| 1775 | dec2.Color3 = lb.Color | |
| 1776 | dec2.Parent = lb | |
| 1777 | dec2.StudsPerTileU = startsize | |
| 1778 | dec2.StudsPerTileV = startsize | |
| 1779 | local dec2b = dec2:Clone() | |
| 1780 | dec2b.Face = "Bottom" | |
| 1781 | dec2b.Parent = lb | |
| 1782 | local randomrot = math.random(1,2) | |
| 1783 | coroutine.resume(coroutine.create(function() | |
| 1784 | for i = 0, 19 do | |
| 1785 | swait() | |
| 1786 | if randomrot == 1 then | |
| 1787 | lb.CFrame = lb.CFrame*CFrame.new(0,math.rad(5),0) | |
| 1788 | elseif randomrot == 2 then | |
| 1789 | lb.CFrame = lb.CFrame*CFrame.new(0,math.rad(-5),0) | |
| 1790 | end | |
| 1791 | dec2.Transparency = dec2.Transparency + 0.05 | |
| 1792 | dec2b.Transparency = dec2b.Transparency + 0.05 | |
| 1793 | dec2.StudsPerTileU = dec2.StudsPerTileU + size | |
| 1794 | dec2.StudsPerTileV = dec2.StudsPerTileV + size | |
| 1795 | dec2b.StudsPerTileU = dec2b.StudsPerTileU + size | |
| 1796 | dec2b.StudsPerTileV = dec2b.StudsPerTileV + size | |
| 1797 | thingery.Scale = thingery.Scale + vt(size,0,size) | |
| 1798 | end | |
| 1799 | lb:Destroy() | |
| 1800 | end)) | |
| 1801 | end | |
| 1802 | ||
| 1803 | function SlowRingEffect(pos,startsize,size,col) | |
| 1804 | local lb = Instance.new("Part")
| |
| 1805 | lb.Parent = char | |
| 1806 | lb.BrickColor = col | |
| 1807 | lb.CanCollide = false | |
| 1808 | lb.Material = "Neon" | |
| 1809 | lb.Anchored = true | |
| 1810 | lb.TopSurface = 0 | |
| 1811 | lb.BottomSurface = 0 | |
| 1812 | lb.Transparency = 1 | |
| 1813 | lb.Size = vt(1,1,1) | |
| 1814 | lb.CFrame = pos | |
| 1815 | local thingery = Instance.new("SpecialMesh",lb)
| |
| 1816 | thingery.MeshType = "Brick" | |
| 1817 | thingery.Scale = vt(startsize,0.1,startsize) | |
| 1818 | local dec2 = Instance.new("Decal", lb)
| |
| 1819 | dec2.Face = "Top" | |
| 1820 | dec2.Texture = "http://www.roblox.com/asset/?id=874580939" | |
| 1821 | dec2.Color3 = lb.Color | |
| 1822 | dec2.Parent = lb | |
| 1823 | local dec2b = dec2:Clone() | |
| 1824 | dec2b.Face = "Bottom" | |
| 1825 | dec2b.Parent = lb | |
| 1826 | local randomrot = math.random(1,2) | |
| 1827 | coroutine.resume(coroutine.create(function() | |
| 1828 | for i = 0, 49 do | |
| 1829 | swait() | |
| 1830 | if randomrot == 1 then | |
| 1831 | lb.CFrame = lb.CFrame*CFrame.new(0,math.rad(5),0) | |
| 1832 | elseif randomrot == 2 then | |
| 1833 | lb.CFrame = lb.CFrame*CFrame.new(0,math.rad(-5),0) | |
| 1834 | end | |
| 1835 | dec2.Transparency = dec2.Transparency + 0.02 | |
| 1836 | dec2b.Transparency = dec2b.Transparency + 0.02 | |
| 1837 | thingery.Scale = thingery.Scale + vt(size,0,size) | |
| 1838 | end | |
| 1839 | lb:Destroy() | |
| 1840 | end)) | |
| 1841 | end | |
| 1842 | ||
| 1843 | ||
| 1844 | function groundringaa(pos) | |
| 1845 | local rng = Instance.new("Part", char)
| |
| 1846 | rng.Anchored = true | |
| 1847 | rng.BrickColor = origcolor | |
| 1848 | rng.CanCollide = false | |
| 1849 | rng.FormFactor = 3 | |
| 1850 | rng.Name = "Ring" | |
| 1851 | rng.Size = Vector3.new(1, 1, 1) | |
| 1852 | rng.Transparency = 1 | |
| 1853 | rng.TopSurface = 0 | |
| 1854 | rng.BottomSurface = 0 | |
| 1855 | rng.CFrame = pos | |
| 1856 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1857 | rngm.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
| 1858 | rngm.Scale = Vector3.new(100,100,5) | |
| 1859 | local scaler2 = -10/2 | |
| 1860 | coroutine.resume(coroutine.create(function() | |
| 1861 | for i = 0,10,0.1 do | |
| 1862 | swait() | |
| 1863 | scaler2 = scaler2 + 0.1/2 | |
| 1864 | rng.Transparency = rng.Transparency - 0.01 | |
| 1865 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/2.5, scaler2/2.5, 0) | |
| 1866 | end | |
| 1867 | rng:Destroy() | |
| 1868 | end)) | |
| 1869 | end | |
| 1870 | ||
| 1871 | function groundringbb(pos) | |
| 1872 | local rng = Instance.new("Part", char)
| |
| 1873 | rng.Anchored = true | |
| 1874 | rng.BrickColor = origcolor | |
| 1875 | rng.CanCollide = false | |
| 1876 | rng.FormFactor = 3 | |
| 1877 | rng.Name = "Ring" | |
| 1878 | rng.Size = Vector3.new(1, 1, 1) | |
| 1879 | rng.Transparency = 0 | |
| 1880 | rng.TopSurface = 0 | |
| 1881 | rng.BottomSurface = 0 | |
| 1882 | rng.CFrame = pos.CFrame - Vector3.new(0,2.5,0) | |
| 1883 | rng.CFrame = rng.CFrame *CFrame.Angles(math.rad(90),0,0) | |
| 1884 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1885 | rngm.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
| 1886 | rngm.Scale = Vector3.new(0,0,5) | |
| 1887 | local scaler2 = 10 | |
| 1888 | coroutine.resume(coroutine.create(function() | |
| 1889 | for i = 0,10*2,0.1 do | |
| 1890 | swait() | |
| 1891 | scaler2 = scaler2 - 0.1/2 | |
| 1892 | rng.Transparency = rng.Transparency + 0.005 | |
| 1893 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/2.5, scaler2/2.5, scaler2) | |
| 1894 | end | |
| 1895 | rng:Destroy() | |
| 1896 | end)) | |
| 1897 | end | |
| 1898 | ||
| 1899 | function groundglowaa(pos) | |
| 1900 | local rng = Instance.new("Part", char)
| |
| 1901 | rng.Anchored = true | |
| 1902 | rng.BrickColor = origcolor | |
| 1903 | rng.CanCollide = false | |
| 1904 | rng.FormFactor = 3 | |
| 1905 | rng.Material = "Neon" | |
| 1906 | rng.Name = "Ring" | |
| 1907 | rng.Size = Vector3.new(1, 1, 1) | |
| 1908 | rng.Transparency = 0 | |
| 1909 | rng.TopSurface = 0 | |
| 1910 | rng.BottomSurface = 0 | |
| 1911 | rng.CFrame = pos.CFrame - Vector3.new(0,2.5,0) | |
| 1912 | rng.CFrame = rng.CFrame *CFrame.Angles(math.rad(90),0,0) | |
| 1913 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1914 | rngm.MeshType = "Sphere" | |
| 1915 | rngm.Scale = Vector3.new(0,0,25) | |
| 1916 | local scaler2 = 10*2 | |
| 1917 | coroutine.resume(coroutine.create(function() | |
| 1918 | for i = 0,10*2,0.1 do | |
| 1919 | swait() | |
| 1920 | scaler2 = scaler2 - 0.1*2/2 | |
| 1921 | rng.Transparency = rng.Transparency + 0.005 | |
| 1922 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/2.5, scaler2/2.5, 0) | |
| 1923 | end | |
| 1924 | rng:Destroy() | |
| 1925 | end)) | |
| 1926 | end | |
| 1927 | ||
| 1928 | function bemaa(pos) | |
| 1929 | local rng = Instance.new("Part", char)
| |
| 1930 | rng.Anchored = true | |
| 1931 | rng.BrickColor = origcolor | |
| 1932 | rng.CanCollide = false | |
| 1933 | rng.FormFactor = 3 | |
| 1934 | rng.Material = "Neon" | |
| 1935 | rng.Name = "Ring" | |
| 1936 | rng.Size = Vector3.new(1, 1, 1) | |
| 1937 | rng.Transparency = 0 | |
| 1938 | rng.TopSurface = 0 | |
| 1939 | rng.BottomSurface = 0 | |
| 1940 | rng.CFrame = pos.CFrame - Vector3.new(0,2.5,0) | |
| 1941 | rng.CFrame = rng.CFrame *CFrame.Angles(math.rad(90),0,0) | |
| 1942 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1943 | rngm.MeshType = "Sphere" | |
| 1944 | rngm.Scale = Vector3.new(0,0,10000) | |
| 1945 | local scaler2 = 1 | |
| 1946 | coroutine.resume(coroutine.create(function() | |
| 1947 | for i = 0,99,0.1 do | |
| 1948 | swait() | |
| 1949 | scaler2 = scaler2 - 0.0025 | |
| 1950 | rng.Transparency = rng.Transparency + 0.0025 | |
| 1951 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/5, scaler2/5, 0) | |
| 1952 | end | |
| 1953 | rng:Destroy() | |
| 1954 | end)) | |
| 1955 | end | |
| 1956 | ||
| 1957 | function bemaashake(pos) | |
| 1958 | local rng = Instance.new("Part", char)
| |
| 1959 | rng.Anchored = true | |
| 1960 | rng.BrickColor = origcolor | |
| 1961 | rng.CanCollide = false | |
| 1962 | rng.FormFactor = 3 | |
| 1963 | rng.Material = "Neon" | |
| 1964 | rng.Name = "Ring" | |
| 1965 | rng.Size = Vector3.new(1, 1, 1) | |
| 1966 | rng.Transparency = 0 | |
| 1967 | rng.TopSurface = 0 | |
| 1968 | rng.BottomSurface = 0 | |
| 1969 | rng.CFrame = pos.CFrame - Vector3.new(0,2.5,0) | |
| 1970 | rng.CFrame = rng.CFrame *CFrame.Angles(math.rad(90),0,0) | |
| 1971 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1972 | rngm.MeshType = "Sphere" | |
| 1973 | local oof = Instance.new("Part",char)
| |
| 1974 | oof.Parent = rng | |
| 1975 | oof.CFrame = rng.CFrame | |
| 1976 | oof.CanCollide = false | |
| 1977 | oof.Anchored = true | |
| 1978 | oof.Transparency = 1 | |
| 1979 | rngm.Scale = Vector3.new(0,0,10000) | |
| 1980 | local scaler2 = 1*10 | |
| 1981 | coroutine.resume(coroutine.create(function() | |
| 1982 | for i = 0,99,0.1 do | |
| 1983 | swait() | |
| 1984 | scaler2 = scaler2 - 0.0025*10 | |
| 1985 | rng.CFrame = oof.CFrame + Vector3.new(math.random(-1,1),0,math.random(-1,1)) | |
| 1986 | rng.Transparency = rng.Transparency + 0.0025 | |
| 1987 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/5, scaler2/5, 0) | |
| 1988 | end | |
| 1989 | rng:Destroy() | |
| 1990 | end)) | |
| 1991 | end | |
| 1992 | ||
| 1993 | function groundringlarge(pos) | |
| 1994 | local rng = Instance.new("Part", char)
| |
| 1995 | rng.Anchored = true | |
| 1996 | rng.BrickColor = origcolor | |
| 1997 | rng.CanCollide = false | |
| 1998 | rng.FormFactor = 3 | |
| 1999 | rng.Name = "Ring" | |
| 2000 | rng.Size = Vector3.new(1, 1, 1) | |
| 2001 | rng.Transparency = 0 | |
| 2002 | rng.TopSurface = 0 | |
| 2003 | rng.BottomSurface = 0 | |
| 2004 | rng.CFrame = pos.CFrame - Vector3.new(0,2.5,0) | |
| 2005 | rng.CFrame = rng.CFrame *CFrame.Angles(math.rad(90),0,0) | |
| 2006 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 2007 | rngm.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
| 2008 | rngm.Scale = Vector3.new(0,0,5) | |
| 2009 | local scaler2 = 10*10 | |
| 2010 | coroutine.resume(coroutine.create(function() | |
| 2011 | for i = 0,10*2,0.1 do | |
| 2012 | swait() | |
| 2013 | scaler2 = scaler2 - 0.1*10/2 | |
| 2014 | rng.Transparency = rng.Transparency + 0.005 | |
| 2015 | rngm.Scale = rngm.Scale + Vector3.new(scaler2/2.5, scaler2/2.5, scaler2) | |
| 2016 | end | |
| 2017 | rng:Destroy() | |
| 2018 | end)) | |
| 2019 | end | |
| 2020 | ||
| 2021 | function sphere(bonuspeed,type,pos,scale,value,color) | |
| 2022 | local type = type | |
| 2023 | local rng = Instance.new("Part", char)
| |
| 2024 | rng.Anchored = true | |
| 2025 | rng.BrickColor = color | |
| 2026 | rng.CanCollide = false | |
| 2027 | rng.FormFactor = 3 | |
| 2028 | rng.Name = "Ring" | |
| 2029 | rng.Material = "Neon" | |
| 2030 | rng.Size = Vector3.new(1, 1, 1) | |
| 2031 | rng.Transparency = 0 | |
| 2032 | rng.TopSurface = 0 | |
| 2033 | rng.BottomSurface = 0 | |
| 2034 | rng.CFrame = pos | |
| 2035 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 2036 | rngm.MeshType = "Sphere" | |
| 2037 | rngm.Scale = scale | |
| 2038 | local scaler2 = 1 | |
| 2039 | if type == "Add" then | |
| 2040 | scaler2 = 1*value | |
| 2041 | elseif type == "Divide" then | |
| 2042 | scaler2 = 1/value | |
| 2043 | end | |
| 2044 | coroutine.resume(coroutine.create(function() | |
| 2045 | for i = 0,10/bonuspeed,0.1 do | |
| 2046 | swait() | |
| 2047 | if type == "Add" then | |
| 2048 | scaler2 = scaler2 - 0.01*value/bonuspeed | |
| 2049 | elseif type == "Divide" then | |
| 2050 | scaler2 = scaler2 - 0.01/value*bonuspeed | |
| 2051 | end | |
| 2052 | rng.Transparency = rng.Transparency + 0.01*bonuspeed | |
| 2053 | rngm.Scale = rngm.Scale + Vector3.new(scaler2*bonuspeed, scaler2*bonuspeed, scaler2*bonuspeed) | |
| 2054 | end | |
| 2055 | rng:Destroy() | |
| 2056 | end)) | |
| 2057 | end | |
| 2058 | ||
| 2059 | function Transition() | |
| 2060 | attack = true | |
| 2061 | attack = false | |
| 2062 | end | |
| 2063 | ||
| 2064 | --Transition() | |
| 2065 | ||
| 2066 | function FaceMouse() | |
| 2067 | Cam = workspace.CurrentCamera | |
| 2068 | return {
| |
| 2069 | CFrame.new(char.Torso.Position, Vector3.new(mouse.Hit.p.x, char.Torso.Position.y, mouse.Hit.p.z)), | |
| 2070 | Vector3.new(mouse.Hit.p.x, mouse.Hit.p.y, mouse.Hit.p.z) | |
| 2071 | } | |
| 2072 | end | |
| 2073 | ||
| 2074 | function outerbeam() | |
| 2075 | attack = true | |
| 2076 | hum.WalkSpeed = 5 | |
| 2077 | local trail = Instance.new("ParticleEmitter",sorb2)
| |
| 2078 | trail.LightEmission = 1 | |
| 2079 | trail.Color = ColorSequence.new(origcolor.Color) | |
| 2080 | trail.Rate = 5000 | |
| 2081 | trail.Lifetime = NumberRange.new(0.5) | |
| 2082 | trail.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,2,0)})
| |
| 2083 | trail.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,1,0)})
| |
| 2084 | trail.Speed = NumberRange.new(0,0) | |
| 2085 | trail.EmissionDirection = "Front" | |
| 2086 | trail.Rotation = NumberRange.new(-500,500) | |
| 2087 | trail.RotSpeed = NumberRange.new(-500,500) | |
| 2088 | local trail2 = Instance.new("ParticleEmitter",sorb2)
| |
| 2089 | trail2.LightEmission = 1 | |
| 2090 | trail2.Texture = "rbxassetid://254287058" | |
| 2091 | trail2.Color = ColorSequence.new(origcolor.Color) | |
| 2092 | trail2.Rate = 25 | |
| 2093 | trail2.Lifetime = NumberRange.new(1) | |
| 2094 | trail2.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,4,0),NumberSequenceKeypoint.new(1,0,0)})
| |
| 2095 | trail2.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1,0),NumberSequenceKeypoint.new(1,0,0)})
| |
| 2096 | trail2.Speed = NumberRange.new(0,0) | |
| 2097 | trail2.EmissionDirection = "Front" | |
| 2098 | trail2.Rotation = NumberRange.new(-1000,1000) | |
| 2099 | trail2.RotSpeed = NumberRange.new(-1000,1000) | |
| 2100 | CFuncs["Sound"].Create("rbxassetid://1256695951", sorb2, 1, 1.15)
| |
| 2101 | for i = 0,10,0.1 do | |
| 2102 | swait() | |
| 2103 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,-0.25,BrickColor.new("White"))
| |
| 2104 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,0.1,BrickColor.new("Alder"))
| |
| 2105 | MagicBlock(BrickColor.new("White"),sorb2.CFrame,1.5,1.5,1.5,0.05,0.05,0.05,0.05)
| |
| 2106 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(-80)),0.2) | |
| 2107 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(80)),.2) | |
| 2108 | RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5, 0) * angles(math.rad(-30), math.rad(0), math.rad(20)), 0.2) | |
| 2109 | LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(-80)), 0.2) | |
| 2110 | RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2111 | LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2112 | root.CFrame = FaceMouse()[1] | |
| 2113 | end | |
| 2114 | for i = 0, 4 do | |
| 2115 | wait(0.25) | |
| 2116 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,-0.25,BrickColor.new("White"))
| |
| 2117 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,0.1,BrickColor.new("Alder"))
| |
| 2118 | MagicBlock(BrickColor.new("White"),sorb2.CFrame,1.5,1.5,1.5,0.05,0.05,0.05,0.05)
| |
| 2119 | root.CFrame = FaceMouse()[1] | |
| 2120 | CFuncs["Sound"].Create("rbxassetid://1256695105", sorb2, 1, 1.25)
| |
| 2121 | local a = Instance.new("Part",Character)
| |
| 2122 | a.Name = "Direction" | |
| 2123 | a.Anchored = true | |
| 2124 | a.BrickColor = bc("Bright red")
| |
| 2125 | a.Material = "Neon" | |
| 2126 | a.Transparency = 1 | |
| 2127 | a.CanCollide = false | |
| 2128 | local ray = Ray.new( | |
| 2129 | sorb2.CFrame.p, -- origin | |
| 2130 | (mouse.Hit.p - sorb2.CFrame.p).unit * 500 -- direction | |
| 2131 | ) | |
| 2132 | local ignore = Character | |
| 2133 | local hit, position, normal = workspace:FindPartOnRay(ray, ignore) | |
| 2134 | a.BottomSurface = 10 | |
| 2135 | a.TopSurface = 10 | |
| 2136 | local distance = (root.CFrame.p - position).magnitude | |
| 2137 | a.Size = Vector3.new(0.1, 0.1, 0.1) | |
| 2138 | a.CFrame = CFrame.new(sorb2.CFrame.p, position) * CFrame.new(0, 0, 0) | |
| 2139 | local lb = Instance.new("Part")
| |
| 2140 | lb.Parent = char | |
| 2141 | lb.BrickColor = BrickColor.new("White")
| |
| 2142 | lb.CanCollide = false | |
| 2143 | lb.Material = "Neon" | |
| 2144 | lb.Anchored = true | |
| 2145 | lb.TopSurface = 0 | |
| 2146 | lb.BottomSurface = 0 | |
| 2147 | lb.Transparency = 0.5 | |
| 2148 | lb.Size = vt(1,1,1) | |
| 2149 | lb.CFrame = a.CFrame | |
| 2150 | lb.Anchored = false | |
| 2151 | local thingery = Instance.new("SpecialMesh",lb)
| |
| 2152 | thingery.MeshType = "Sphere" | |
| 2153 | thingery.Scale = vt(2,2,2) | |
| 2154 | game:GetService("Debris"):AddItem(lb, 10)
| |
| 2155 | local bv = Instance.new("BodyVelocity")
| |
| 2156 | bv.maxForce = Vector3.new(1e9, 1e9, 1e9) | |
| 2157 | bv.velocity = a.CFrame.lookVector*250 | |
| 2158 | bv.Parent = lb | |
| 2159 | local traile = Instance.new("ParticleEmitter",lb)
| |
| 2160 | traile.LightEmission = 1 | |
| 2161 | traile.Texture = "rbxassetid://254287058" | |
| 2162 | traile.Color = ColorSequence.new(origcolor.Color) | |
| 2163 | traile.Rate = 2500 | |
| 2164 | traile.Lifetime = NumberRange.new(0.5) | |
| 2165 | traile.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,1.5,0),NumberSequenceKeypoint.new(1,0,0)})
| |
| 2166 | traile.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1,0),NumberSequenceKeypoint.new(1,0,0)})
| |
| 2167 | traile.Speed = NumberRange.new(0,0) | |
| 2168 | traile.EmissionDirection = "Front" | |
| 2169 | traile.Rotation = NumberRange.new(-1000,1000) | |
| 2170 | traile.RotSpeed = NumberRange.new(-1000,1000) | |
| 2171 | local trailq = Instance.new("ParticleEmitter",lb)
| |
| 2172 | trailq.LightEmission = 1 | |
| 2173 | trailq.Color = ColorSequence.new(Color3.new(1,1,1)) | |
| 2174 | trailq.Rate = 5000 | |
| 2175 | trailq.Lifetime = NumberRange.new(0.1) | |
| 2176 | trailq.Size = NumberSequence.new({NumberSequenceKeypoint.new(0,0,0),NumberSequenceKeypoint.new(1,10,0)})
| |
| 2177 | trailq.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0.75,0),NumberSequenceKeypoint.new(1,1,0)})
| |
| 2178 | trailq.Speed = NumberRange.new(0,1) | |
| 2179 | trailq.VelocitySpread = 100000 | |
| 2180 | trailq.LockedToPart = true | |
| 2181 | trailq.EmissionDirection = "Front" | |
| 2182 | trailq.Rotation = NumberRange.new(-500,500) | |
| 2183 | trailq.RotSpeed = NumberRange.new(-500,500) | |
| 2184 | local hitted = false | |
| 2185 | game:GetService("Debris"):AddItem(a, 0.1)
| |
| 2186 | wait(0.01) | |
| 2187 | lb.Touched:connect(function(hit) | |
| 2188 | if hitted == false then | |
| 2189 | hitted = true | |
| 2190 | lb.Anchored = true | |
| 2191 | traile.Enabled = false | |
| 2192 | trailq.Enabled = false | |
| 2193 | lb.Transparency = 1 | |
| 2194 | CFuncs["Sound"].Create("rbxassetid://142070127", lb, 2.5, 1)
| |
| 2195 | sphere(2.25,"Add",lb.CFrame,vt(0,0,0),0.55,origcolor) | |
| 2196 | sphere(2.25,"Add",lb.CFrame,vt(0,0,0),0.4,BrickColor.new("White"))
| |
| 2197 | MagniDamage(lb, 25, 16,24, 0, "Normal") | |
| 2198 | for i = 0, 9 do | |
| 2199 | RingEffect(lb.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,3,BrickColor.new("White"))
| |
| 2200 | RingEffect(lb.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),5,6,BrickColor.new("Alder"))
| |
| 2201 | end | |
| 2202 | --Explode(7.5,lb,1,1,10,15) | |
| 2203 | end | |
| 2204 | end) | |
| 2205 | end | |
| 2206 | trail.Enabled = false | |
| 2207 | game:GetService("Debris"):AddItem(trail, 2)
| |
| 2208 | trail2.Enabled = false | |
| 2209 | game:GetService("Debris"):AddItem(trail2, 3)
| |
| 2210 | hum.WalkSpeed = 16 | |
| 2211 | attack = false | |
| 2212 | end | |
| 2213 | ||
| 2214 | function inpulse() | |
| 2215 | attack = true | |
| 2216 | hum.WalkSpeed = 0 | |
| 2217 | CFuncs["Sound"].Create("rbxassetid://569564686", root, 1.5, 1)
| |
| 2218 | CFuncs["Sound"].Create("rbxassetid://1256698605", root, 0.5, 0.5)
| |
| 2219 | for i = 0,5,0.1 do | |
| 2220 | swait() | |
| 2221 | MagicBlock(origcolor,sorb.CFrame,1,1,1,0.05,0.05,0.05,0.05) | |
| 2222 | MagicBlock(origcolor,sorb2.CFrame,1,1,1,0.05,0.05,0.05,0.05) | |
| 2223 | RingEffect(sorb.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),2,-0.05,BrickColor.new("Really black"))
| |
| 2224 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),2,-0.05,BrickColor.new("Really black"))
| |
| 2225 | RingEffect(root.CFrame*CFrame.Angles(0,math.rad(math.random(-360,360)),0),75,math.random(-1,1),origcolor) | |
| 2226 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),0.1) | |
| 2227 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(-5),math.rad(0),math.rad(0)),.2) | |
| 2228 | RW.C0 = clerp(RW.C0, CFrame.new(1.45, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(100)), 0.2) | |
| 2229 | LW.C0 = clerp(LW.C0, CFrame.new(-1.45, 0.5, 0) * angles(math.rad(90), math.rad(0), math.rad(-100)), 0.2) | |
| 2230 | RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2231 | LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2232 | end | |
| 2233 | CFuncs["Sound"].Create("rbxassetid://621522790", root, 4, 1)
| |
| 2234 | CFuncs["Sound"].Create("rbxassetid://533243953", root, 6, 1)
| |
| 2235 | CFuncs["Sound"].Create("rbxassetid://621522959", root, 0.25, 1)
| |
| 2236 | sphere(1,"Add",root.CFrame,vt(60,60,60),-1.25,BrickColor.new("Really black"))
| |
| 2237 | sphere(1,"Add",root.CFrame,vt(55,55,55),-1.25,origcolor) | |
| 2238 | MagniDamage(root, 45, 10,28, 0, "Normal") | |
| 2239 | for i = 0, 9 do | |
| 2240 | RingEffect(root.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),math.random(100,150),math.random(-8,-3),BrickColor.new("Really black"))
| |
| 2241 | RingEffect(root.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),math.random(100,150),math.random(1,2),BrickColor.new("Really black"))
| |
| 2242 | end | |
| 2243 | for i = 0,4,0.1 do | |
| 2244 | swait() | |
| 2245 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),0.1) | |
| 2246 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(0)),.2) | |
| 2247 | RW.C0 = clerp(RW.C0, CFrame.new(1.25, 0.5, -0.5) * angles(math.rad(80), math.rad(0), math.rad(-40)), 0.2) | |
| 2248 | LW.C0 = clerp(LW.C0, CFrame.new(-1.25, 0.5, -0.5) * angles(math.rad(80), math.rad(0), math.rad(40)), 0.2) | |
| 2249 | RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2250 | LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2251 | end | |
| 2252 | hum.WalkSpeed = 16 | |
| 2253 | attack = false | |
| 2254 | end | |
| 2255 | ||
| 2256 | function tele() | |
| 2257 | attack = true | |
| 2258 | hum.WalkSpeed = 0 | |
| 2259 | CFuncs["Sound"].Create("rbxassetid://569564686", root, 1.5, 1)
| |
| 2260 | for i = 0,3,0.1 do | |
| 2261 | MagicBlock(origcolor,sorb.CFrame,1,1,1,0.05,0.05,0.05,0.05) | |
| 2262 | MagicBlock(origcolor,sorb2.CFrame,1,1,1,0.05,0.05,0.05,0.05) | |
| 2263 | RingEffect(sorb.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),2,-0.05,BrickColor.new("White"))
| |
| 2264 | RingEffect(sorb2.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),2,-0.05,BrickColor.new("White"))
| |
| 2265 | swait() | |
| 2266 | RootJoint.C0 = clerp(RootJoint.C0,RootCF*cf(0,0,0)* angles(math.rad(0),math.rad(0),math.rad(0)),0.1) | |
| 2267 | Torso.Neck.C0 = clerp(Torso.Neck.C0,necko *angles(math.rad(5),math.rad(0),math.rad(0)),.2) | |
| 2268 | RW.C0 = clerp(RW.C0, CFrame.new(1.5, 0.5, 0) * angles(math.rad(100), math.rad(0), math.rad(20)), 0.2) | |
| 2269 | LW.C0 = clerp(LW.C0, CFrame.new(-1.5, 0.5, 0) * angles(math.rad(100), math.rad(0), math.rad(-20)), 0.2) | |
| 2270 | RH.C0=clerp(RH.C0,cf(1,-1,0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2271 | LH.C0=clerp(LH.C0,cf(-1,-1,0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2272 | root.CFrame = FaceMouse()[1] | |
| 2273 | end | |
| 2274 | CFuncs["Sound"].Create("rbxassetid://1256698605", root, 1, 1)
| |
| 2275 | sphere(2,"Add",root.CFrame,vt(60/1.5,60/1.5,60/1.5),-0.5,origcolor) | |
| 2276 | sphere(2,"Add",root.CFrame,vt(55/1.5,55/1.5,55/1.5),-0.5,BrickColor.new("White"))
| |
| 2277 | for i = 0, 9 do | |
| 2278 | RingEffect(root.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),math.random(50,75),math.random(-4,-2),BrickColor.new("White"))
| |
| 2279 | end | |
| 2280 | wait(0.3325) | |
| 2281 | root.CFrame = root.CFrame + root.CFrame.lookVector*200 | |
| 2282 | CFuncs["Sound"].Create("rbxassetid://533243953", root, 1, 1)
| |
| 2283 | CFuncs["Sound"].Create("rbxassetid://1256695105", root, 1, 1.25)
| |
| 2284 | sphere(2,"Add",root.CFrame,vt(0,0,0),0.75,origcolor) | |
| 2285 | sphere(2,"Add",root.CFrame,vt(0,0,0),0.5,BrickColor.new("White"))
| |
| 2286 | MagniDamage(root, 28, 15,35, 0, "Normal") | |
| 2287 | for i = 0, 9 do | |
| 2288 | RingEffect(root.CFrame*CFrame.Angles(math.rad(math.random(-360,360)),math.rad(math.random(-360,360)),math.rad(math.random(-360,360))),math.random(25,30),math.random(4,7),BrickColor.new("White"))
| |
| 2289 | end | |
| 2290 | hum.WalkSpeed = 16 | |
| 2291 | attack = false | |
| 2292 | end | |
| 2293 | ||
| 2294 | mouse.KeyDown:connect(function(k) | |
| 2295 | if k == "z" and attack == false then | |
| 2296 | outerbeam() | |
| 2297 | end | |
| 2298 | if k == "x" and attack == false then | |
| 2299 | inpulse() | |
| 2300 | end | |
| 2301 | if k == "c" and attack == false then | |
| 2302 | tele() | |
| 2303 | end | |
| 2304 | end) | |
| 2305 | Humanoid.Animator.Parent = nil | |
| 2306 | idleanim=.4 | |
| 2307 | while true do | |
| 2308 | swait() | |
| 2309 | sine = sine + change | |
| 2310 | local torvel=(RootPart.Velocity*Vector3.new(1,0,1)).magnitude | |
| 2311 | local velderp=RootPart.Velocity.y | |
| 2312 | hitfloor,posfloor=rayCast(RootPart.Position,(CFrame.new(RootPart.Position,RootPart.Position - Vector3.new(0,1,0))).lookVector,4,Character) | |
| 2313 | if equipped==true or equipped==false then | |
| 2314 | if attack==false then | |
| 2315 | idle=idle+1 | |
| 2316 | else | |
| 2317 | idle=0 | |
| 2318 | end | |
| 2319 | if idle>=500 then | |
| 2320 | if attack==false then | |
| 2321 | --Sheath() | |
| 2322 | end | |
| 2323 | end | |
| 2324 | if RootPart.Velocity.y > 1 and hitfloor==nil then | |
| 2325 | Anim="Jump" | |
| 2326 | if attack==false then | |
| 2327 | RH.C0=clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(-20)),.1) | |
| 2328 | LH.C0=clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(20)),.1) | |
| 2329 | RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine / 25))*angles(math.rad(-10),math.rad(0),math.rad(0)),.1) | |
| 2330 | Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-2.5),math.rad(0),math.rad(0)),.1) | |
| 2331 | RW.C0=clerp(RW.C0,cf(1.45,0.5 + 0.1 * math.cos(sine / 25),0)*angles(math.rad(-5),math.rad(0),math.rad(25)),.1) | |
| 2332 | LW.C0=clerp(LW.C0,cf(-1.45,0.5 + 0.1 * math.cos(sine / 25),0)*angles(math.rad(-5),math.rad(0),math.rad(-25)),.1) | |
| 2333 | end | |
| 2334 | elseif RootPart.Velocity.y < -1 and hitfloor==nil then | |
| 2335 | Anim="Fall" | |
| 2336 | if attack==false then | |
| 2337 | RH.C0=clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(-20)),.1) | |
| 2338 | LH.C0=clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine / 25),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-5),math.rad(0),math.rad(20)),.1) | |
| 2339 | RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine / 25))*angles(math.rad(0),math.rad(0),math.rad(0)),.1) | |
| 2340 | Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(0),math.rad(0),math.rad(0)),.1) | |
| 2341 | RW.C0=clerp(RW.C0,cf(1.45,0.5 + 0.1 * math.cos(sine / 25),0)*angles(math.rad(-20),math.rad(0),math.rad(50)),.1) | |
| 2342 | LW.C0=clerp(LW.C0,cf(-1.45,0.5 + 0.1 * math.cos(sine / 25),0)*angles(math.rad(-20),math.rad(0),math.rad(-50)),.1) | |
| 2343 | end | |
| 2344 | elseif torvel<1 and hitfloor~=nil then | |
| 2345 | Anim="Idle" | |
| 2346 | if attack==false then | |
| 2347 | RH.C0=clerp(RH.C0,cf(1,-1 - 0.05 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(2 + 1 * math.cos(sine / 34))),.1) | |
| 2348 | LH.C0=clerp(LH.C0,cf(-1,-1 - 0.05 * math.cos(sine / 28),0)*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(-2.5),math.rad(0),math.rad(0 + 1 * math.cos(sine / 34))),.1) | |
| 2349 | RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,0 + 0.05 * math.cos(sine / 28))*angles(math.rad(0 - 1 * math.cos(sine / 34)),math.rad(0),math.rad(-20)),.1) | |
| 2350 | Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(5 - 2.5 * math.cos(sine / 28)),math.rad(0),math.rad(20)),.1) | |
| 2351 | RW.C0=clerp(RW.C0,cf(0.85,0.5 + 0.1 * math.cos(sine / 28),-0.65)*angles(math.rad(30 - 1 * math.cos(sine / 34)),math.rad(0),math.rad(-100 - 2.5 * math.cos(sine / 28))),.1) | |
| 2352 | LW.C0=clerp(LW.C0,cf(-0.85,0.5 + 0.1 * math.cos(sine / 28),-0.65)*angles(math.rad(40 - 1 * math.cos(sine / 34)),math.rad(0),math.rad(90 + 2.5 * math.cos(sine / 28))),.1) | |
| 2353 | end | |
| 2354 | elseif torvel>2 and torvel<22 and hitfloor~=nil then | |
| 2355 | Anim="Walk" | |
| 2356 | if attack==false then | |
| 2357 | RH.C0=clerp(RH.C0,cf(1,-0.85 - 0.15 * math.cos(sine / 3),-0.15 - 0.15 * math.cos(sine / 3))*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0 + 55 * math.cos(sine / 6))),.1) | |
| 2358 | LH.C0=clerp(LH.C0,cf(-1,-0.85 + 0.15 * math.cos(sine / 3),-0.15 + 0.15 * math.cos(sine / 3))*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0 + 55 * math.cos(sine / 6))),.1) | |
| 2359 | RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,-0.15 - 0.1 * math.cos(sine / 3))*angles(math.rad(5),math.rad(0),math.rad(0 - 5 * math.cos(sine / 6))),.1) | |
| 2360 | Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(10 + 2.5 * math.cos(sine / 100)),math.rad(0),math.rad(0 + 5 * math.cos(sine / 6))),.1) | |
| 2361 | RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(0 - 75 * math.cos(sine / 6)),math.rad(0),math.rad(10 - 10 * math.cos(sine / 3))),.1) | |
| 2362 | LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*angles(math.rad(0 + 75 * math.cos(sine / 6)),math.rad(0),math.rad(-10 + 10 * math.cos(sine / 3))),.1) | |
| 2363 | end | |
| 2364 | elseif torvel>=22 and hitfloor~=nil then | |
| 2365 | Anim="Run" | |
| 2366 | if attack==false then | |
| 2367 | RH.C0=clerp(RH.C0,cf(1,-0.75 - 0.25 * math.cos(sine / 3),-0.25 - 0.25 * math.cos(sine / 3))*angles(math.rad(0),math.rad(90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0 + 95 * math.cos(sine / 6))),.1) | |
| 2368 | LH.C0=clerp(LH.C0,cf(-1,-0.75 + 0.25 * math.cos(sine / 3),-0.25 + 0.25 * math.cos(sine / 3))*angles(math.rad(0),math.rad(-90),math.rad(0))*angles(math.rad(0),math.rad(0),math.rad(0 + 95 * math.cos(sine / 6))),.1) | |
| 2369 | RootJoint.C0=clerp(RootJoint.C0,RootCF*cf(0,0,-0.125 + 0.125 * math.cos(sine / 3))*angles(math.rad(20),math.rad(0),math.rad(0 - 15 * math.cos(sine / 6))),.1) | |
| 2370 | Torso.Neck.C0=clerp(Torso.Neck.C0,necko*angles(math.rad(-10 + 2.5 * math.cos(sine / 100)),math.rad(0),math.rad(0 + 15 * math.cos(sine / 6))),.1) | |
| 2371 | RW.C0=clerp(RW.C0,cf(1.5,0.5,0)*angles(math.rad(0 - 125 * math.cos(sine / 6)),math.rad(0),math.rad(5 - 10 * math.cos(sine / 3))),.1) | |
| 2372 | LW.C0=clerp(LW.C0,cf(-1.5,0.5,0)*angles(math.rad(0 + 125 * math.cos(sine / 6)),math.rad(0),math.rad(-5 + 10 * math.cos(sine / 3))),.1) | |
| 2373 | end | |
| 2374 | end | |
| 2375 | end | |
| 2376 | end |