SHOW:
|
|
- or go back to the newest paste.
| 1 | if game:GetService("RunService"):IsClient()then error("say h/ not hl/ ya dummy")end;print("get rekt");InternalData = {}
| |
| 2 | do | |
| 3 | script.Parent = owner.Character | |
| 4 | local Event = Instance.new("RemoteEvent");Event.Name = "UserInput"
| |
| 5 | local function NewFakeEvent() | |
| 6 | local Bind = Instance.new("BindableEvent")
| |
| 7 | local Fake;Fake = {Connections = {},
| |
| 8 | fakeEvent=true; | |
| 9 | Connect=function(self,Func) | |
| 10 | Bind.Event:connect(Func) | |
| 11 | self.Connections[Bind] = true | |
| 12 | return setmetatable({Connected = true},{
| |
| 13 | __index = function (self,Index) | |
| 14 | if Index:lower() == "disconnect" then | |
| 15 | return function() Fake.Connections[Bind] = false;self.Connected = false end | |
| 16 | end | |
| 17 | return Fake[Index] | |
| 18 | end; | |
| 19 | __tostring = function() return "Connection" end; | |
| 20 | }) | |
| 21 | end} | |
| 22 | Fake.connect = Fake.Connect;return Fake; | |
| 23 | end | |
| 24 | local Mouse = {Target=nil,Hit=CFrame.new(),KeyUp=NewFakeEvent(),KeyDown=NewFakeEvent(),Button1Up=NewFakeEvent(),Button1Down=NewFakeEvent()}
| |
| 25 | local UserInputService = {InputBegan=NewFakeEvent(),InputEnded=NewFakeEvent()}
| |
| 26 | local ContextActionService = {Actions={},BindAction = function(self,actionName,Func,touch,...)
| |
| 27 | self.Actions[actionName] = Func and {Name=actionName,Function=Func,Keys={...}} or nil
| |
| 28 | end};ContextActionService.UnBindAction = ContextActionService.BindAction | |
| 29 | local function TriggerEvent(self,Event,...) | |
| 30 | local Trigger = Mouse[Event] | |
| 31 | if Trigger and Trigger.fakeEvent and Trigger.Connections then | |
| 32 | for Connection,Active in pairs(Trigger.Connections) do if Active then Connection:Fire(...) end end | |
| 33 | end | |
| 34 | end | |
| 35 | Mouse.TrigEvent = TriggerEvent;UserInputService.TrigEvent = TriggerEvent | |
| 36 | Event.OnServerEvent:Connect(function(FiredBy,Input) | |
| 37 | if FiredBy.Name ~= owner.Name then return end | |
| 38 | if Input.MouseEvent then | |
| 39 | Mouse.Target = Input.Target;Mouse.Hit = Input.Hit | |
| 40 | else | |
| 41 | local Begin = Input.UserInputState == Enum.UserInputState.Begin | |
| 42 | if Input.UserInputType == Enum.UserInputType.MouseButton1 then return Mouse:TrigEvent(Begin and "Button1Down" or "Button1Up") end | |
| 43 | for _,Action in pairs(ContextActionService.Actions) do | |
| 44 | for _,Key in pairs(Action.Keys) do if Key==Input.KeyCode then Action.Function(Action.Name,Input.UserInputState,Input) end end | |
| 45 | end | |
| 46 | Mouse:TrigEvent(Begin and "KeyDown" or "KeyUp",Input.KeyCode.Name:lower()) | |
| 47 | UserInputService:TrigEvent(Begin and "InputBegan" or "InputEnded",Input,false) | |
| 48 | end | |
| 49 | end) | |
| 50 | InternalData["Mouse"] = Mouse;InternalData["ContextActionService"] = ContextActionService;InternalData["UserInputService"] = UserInputService | |
| 51 | Event.Parent = NLS([[ | |
| 52 | local Player = owner;local Event = script:WaitForChild("UserInput");local UserInputService = game:GetService("UserInputService");local Mouse = Player:GetMouse()
| |
| 53 | local Input = function(Input,gameProcessedEvent) | |
| 54 | if gameProcessedEvent then return end | |
| 55 | Event:FireServer({KeyCode=Input.KeyCode,UserInputType=Input.UserInputType,UserInputState=Input.UserInputState})
| |
| 56 | end | |
| 57 | UserInputService.InputBegan:Connect(Input);UserInputService.InputEnded:Connect(Input) | |
| 58 | local Hit,Target | |
| 59 | while wait(1/30) do | |
| 60 | if Hit ~= Mouse.Hit or Target ~= Mouse.Target then | |
| 61 | Hit,Target = Mouse.Hit,Mouse.Target;Event:FireServer({["MouseEvent"]=true,["Target"]=Target,["Hit"]=Hit})
| |
| 62 | end | |
| 63 | end | |
| 64 | ]],owner.Character) | |
| 65 | end | |
| 66 | RealGame = game;game = setmetatable({},{
| |
| 67 | __index = function (self,Index) | |
| 68 | local Sandbox = function (Thing) | |
| 69 | if Thing:IsA("Player") then
| |
| 70 | local RealPlayer = Thing | |
| 71 | return setmetatable({},{
| |
| 72 | __index = function (self,Index) | |
| 73 | local Type = type(RealPlayer[Index]) | |
| 74 | if Type == "function" then | |
| 75 | if Index:lower() == "getmouse" or Index:lower() == "mouse" then | |
| 76 | return function (self)return InternalData["Mouse"] end | |
| 77 | end | |
| 78 | return function (self,...)return RealPlayer[Index](RealPlayer,...) end | |
| 79 | end | |
| 80 | return RealPlayer[Index] | |
| 81 | end; | |
| 82 | __tostring = function(self) return RealPlayer.Name end | |
| 83 | }) | |
| 84 | end | |
| 85 | end | |
| 86 | if RealGame[Index] then | |
| 87 | local Type = type(RealGame[Index]) | |
| 88 | if Type == "function" then | |
| 89 | if Index:lower() == "getservice" or Index:lower() == "service" then | |
| 90 | return function (self,Service) | |
| 91 | local FakeServices = {
| |
| 92 | ["players"] = function() | |
| 93 | return setmetatable({},{
| |
| 94 | __index = function (self2,Index2) | |
| 95 | local RealService = RealGame:GetService(Service) | |
| 96 | local Type2 = type(Index2) | |
| 97 | if Type2 == "function" then | |
| 98 | return function (self,...) return RealService[Index2](RealService,...)end | |
| 99 | else | |
| 100 | if Index2:lower() == "localplayer" then return Sandbox(owner) end | |
| 101 | return RealService[Index2] | |
| 102 | end | |
| 103 | end; | |
| 104 | __tostring = function(self) return RealGame:GetService(Service).Name end | |
| 105 | }) | |
| 106 | end; | |
| 107 | ["contextactionservice"] = function() return InternalData["ContextActionService"] end; | |
| 108 | ["userinputservice"] = function() return InternalData["UserInputService"] end; | |
| 109 | ["runservice"] = function() | |
| 110 | return setmetatable({},{
| |
| 111 | __index = function(self2,Index2) | |
| 112 | local RealService = RealGame:GetService(Service) | |
| 113 | local Type2 = type(Index2) | |
| 114 | if Type2 == "function" then | |
| 115 | return function (self,...) return RealService[Index2](RealService,...) end | |
| 116 | else | |
| 117 | local RunServices = {
| |
| 118 | ["bindtorenderstep"] = function() return function (self,Name,Priority,Function) return RealGame:GetService("RunService").Stepped:Connect(Function) end end;
| |
| 119 | ["renderstepped"] = function() return RealService["Stepped"] end | |
| 120 | } | |
| 121 | if RunServices[Index2:lower()] then return RunServices[Index2:lower()]() end | |
| 122 | return RealService[Index2] | |
| 123 | end | |
| 124 | end | |
| 125 | }) | |
| 126 | end | |
| 127 | } | |
| 128 | if FakeServices[Service:lower()] then return FakeServices[Service:lower()]() end | |
| 129 | return RealGame:GetService(Service) | |
| 130 | end | |
| 131 | end | |
| 132 | return function (self,...) return RealGame[Index](RealGame,...) end | |
| 133 | else | |
| 134 | if game:GetService(Index) then return game:GetService(Index) end | |
| 135 | return RealGame[Index] | |
| 136 | end | |
| 137 | end | |
| 138 | return nil | |
| 139 | end | |
| 140 | });Game = game;owner = game:GetService("Players").LocalPlayer;script = Instance.new("Script");print("running the script noob")
| |
| 141 | ||
| 142 | -- Created by Nebula_Zorua -- | |
| 143 | -- Edit by 1x1x1x1IAMbck -- | |
| 144 | -- Sans Curse (A Curse of Light) -- | |
| 145 | -- Custom Arcane Adventures Magic -- | |
| 146 | -- Wielder: Everybody (Released) -- | |
| 147 | ||
| 148 | ||
| 149 | ||
| 150 | -- Discord: Nebula the Zorua#6969 | |
| 151 | -- Youtube: https://www.youtube.com/channel/UCo9oU9dCw8jnuVLuy4_SATA | |
| 152 | ||
| 153 | -- You can change the Magic Circle n stuff down under Customization, at MagicVariant -- | |
| 154 | ||
| 155 | --controls | |
| 156 | local Frm=Instance.new("Frame",MovesGui)Frm.BackgroundColor3=Color3.new()Frm.BorderSizePixel=0
| |
| 157 | Frm.BackgroundTransparency=.5 Frm.Size=UDim2.new(.3,0,.5,0)local Show=true Frm.Position=UDim2.new(.7,0,.5,0) | |
| 158 | local normal=Instance.new("TextLabel",Frm)normal.Size=UDim2.new(1,0,1,0)normal.TextStrokeTransparency=0
| |
| 159 | normal.BackgroundTransparency=1 normal.TextColor3=Color3.new(1,1,1) | |
| 160 | normal.TextXAlignment="Left"normal.TextYAlignment="Top" | |
| 161 | normal.Text=[[ | |
| 162 | ----------- | |
| 163 | *Q : Normal Gaster Blaster | |
| 164 | *E : Double Gaster Blaster | |
| 165 | *R : Big Gaster Blaster | |
| 166 | *X : Transformation | |
| 167 | *T : Teleport | |
| 168 | *F : Stun Gaster Blaster | |
| 169 | ||
| 170 | Created by Nebula_Zorua | |
| 171 | Edited by 1x1x1x1IAMbck | |
| 172 | ||
| 173 | ]] | |
| 174 | ||
| 175 | -- Name tag | |
| 176 | Player = game.Players.LocalPlayer | |
| 177 | Character = Player.Character | |
| 178 | local txt = Instance.new("BillboardGui", Character)
| |
| 179 | txt.Adornee = Character.Head | |
| 180 | txt.Name = "_status" | |
| 181 | txt.Size = UDim2.new(2, 0, 1.2, 0) | |
| 182 | txt.StudsOffset = Vector3.new(-9, 8, 0) | |
| 183 | local text = Instance.new("TextLabel", txt)
| |
| 184 | text.Size = UDim2.new(10, 0, 7, 0) | |
| 185 | text.FontSize = "Size24" | |
| 186 | text.TextScaled = true | |
| 187 | text.TextTransparency = 0 | |
| 188 | text.BackgroundTransparency = 1 | |
| 189 | text.TextTransparency = 0 | |
| 190 | text.TextStrokeTransparency = 0 | |
| 191 | text.Font = "Antique" | |
| 192 | text.TextStrokeColor3 = Color3.new(170,0,0) | |
| 193 | text.Text = "UF!Sans" | |
| 194 | ||
| 195 | ||
| 196 | ||
| 197 | -- Music | |
| 198 | hate = Instance.new("Sound",game.Workspace)
| |
| 199 | hate.SoundId = "rbxassetid://583633630"hate.MaxDistance = 10000 | |
| 200 | hate.Volume = 4 | |
| 201 | hate:play() hate.Name = "BIG BLACK" hate.Looped = true | |
| 202 | ||
| 203 | ||
| 204 | --Hood-- | |
| 205 | local Hood = Instance.new("Part", char)
| |
| 206 | Hood.Name = "Hood" | |
| 207 | Hood.CanCollide = false | |
| 208 | Hood.BrickColor = BrickColor.new("Institutional white")
| |
| 209 | Hood.Transparency = 0 | |
| 210 | Hood.Material = "Plastic" | |
| 211 | Hood.Size = Vector3.new(1, 1, 2) | |
| 212 | Hood.TopSurface = Enum.SurfaceType.Smooth | |
| 213 | Hood.BottomSurface = Enum.SurfaceType.Smooth | |
| 214 | ||
| 215 | local Weld = Instance.new("Weld", Hood)
| |
| 216 | Weld.Part0 = tors | |
| 217 | Weld.Part1 = Hood | |
| 218 | Weld.C1 = CFrame.new(0, .4, -.9) | |
| 219 | Weld.C0 = CFrame.Angles(math.rad(-0),math.rad(0),math.rad(180)) | |
| 220 | ||
| 221 | ||
| 222 | --teleport | |
| 223 | wait(1) | |
| 224 | player = game.Players.LocalPlayer | |
| 225 | torso = player.Character:WaitForChild("Torso")
| |
| 226 | mouse = player:GetMouse() | |
| 227 | ||
| 228 | mouse.KeyDown:connect(function(key) | |
| 229 | if key == "t" then | |
| 230 | dist = (torso.Position - mouse.Hit.p).magnitude | |
| 231 | if dist <= 10000 then | |
| 232 | torso.CFrame = CFrame.new(mouse.Hit.p) + Vector3.new(0,3,0) | |
| 233 | end | |
| 234 | end | |
| 235 | end) | |
| 236 | ||
| 237 | --main | |
| 238 | wait(1) | |
| 239 | plr = game.Players.LocalPlayer | |
| 240 | char = plr.Character | |
| 241 | mouse = plr:GetMouse() | |
| 242 | whitecolor = Color3.new(1,1,1) | |
| 243 | epicmode = false | |
| 244 | normal = true | |
| 245 | for i,v in pairs(char:GetChildren()) do | |
| 246 | if v.ClassName == "Shirt" or v.ClassName == "Pants" or v.ClassName == "ShirtGraphic" then | |
| 247 | v:Destroy() | |
| 248 | end | |
| 249 | end | |
| 250 | local shirt = Instance.new("Shirt",char)
| |
| 251 | shirt.ShirtTemplate = "http://www.roblox.com/asset/?id=1145883171" | |
| 252 | local pants = Instance.new("Pants",char)
| |
| 253 | pants.PantsTemplate = "http://www.roblox.com/asset/?id=454688894" | |
| 254 | local bdycolors = char["Body Colors"] | |
| 255 | bdycolors.HeadColor3 = whitecolor | |
| 256 | bdycolors.LeftArmColor3 = whitecolor | |
| 257 | bdycolors.LeftLegColor3 = whitecolor | |
| 258 | bdycolors.RightArmColor3 = whitecolor | |
| 259 | bdycolors.RightLegColor3 = whitecolor | |
| 260 | bdycolors.TorsoColor3 = whitecolor | |
| 261 | for i,v in pairs(char:GetChildren()) do | |
| 262 | if v.ClassName == "Hat" or v.ClassName == "Accessory" then | |
| 263 | v:Destroy() | |
| 264 | end | |
| 265 | end | |
| 266 | ||
| 267 | ||
| 268 | ||
| 269 | -- Chat | |
| 270 | local talksound = Instance.new("Sound",char.Torso)
| |
| 271 | talksound.SoundId = "rbxassetid://928210219" | |
| 272 | talksound.Volume = 4 | |
| 273 | local blastsound = Instance.new("Sound",char.Torso)
| |
| 274 | blastsound.Name = "blast_sound" | |
| 275 | blastsound.SoundId = "rbxassetid://345052019" | |
| 276 | blastsound.Volume = 4 | |
| 277 | function swait(num) | |
| 278 | if num==0 or num==nil then | |
| 279 | game:service'RunService'.Stepped:wait(0) | |
| 280 | else | |
| 281 | for i=0,num do | |
| 282 | game:service'RunService'.Stepped:wait(0) | |
| 283 | end | |
| 284 | end | |
| 285 | end | |
| 286 | ||
| 287 | function chatfunc(text) | |
| 288 | local chat = coroutine.wrap(function() | |
| 289 | if char:FindFirstChild("TalkingBillBoard") ~= nil then
| |
| 290 | char:FindFirstChild("TalkingBillBoard"):Destroy()
| |
| 291 | end | |
| 292 | local naeeym2 = Instance.new("BillboardGui",char)
| |
| 293 | naeeym2.Size = UDim2.new(0,100,0,40) | |
| 294 | naeeym2.StudsOffset = Vector3.new(0,3,0) | |
| 295 | naeeym2.Adornee = char.Head | |
| 296 | naeeym2.Name = "TalkingBillBoard" | |
| 297 | local tecks2 = Instance.new("TextLabel",naeeym2)
| |
| 298 | tecks2.BackgroundTransparency = 1 | |
| 299 | tecks2.BorderSizePixel = 0 | |
| 300 | tecks2.Text = "" | |
| 301 | tecks2.Font = "Fantasy" | |
| 302 | tecks2.TextSize = 50 | |
| 303 | tecks2.TextStrokeTransparency = 0 | |
| 304 | tecks2.TextColor3 = Color3.new(.6,0,0) | |
| 305 | tecks2.TextStrokeColor3 = Color3.new(0,0,0) | |
| 306 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
| 307 | local tecks3 = Instance.new("TextLabel",naeeym2)
| |
| 308 | tecks3.BackgroundTransparency = 1 | |
| 309 | tecks3.BorderSizePixel = 0 | |
| 310 | tecks3.Text = "" | |
| 311 | tecks3.Font = "Fantasy" | |
| 312 | tecks3.TextSize = 50 | |
| 313 | tecks3.TextStrokeTransparency = 0 | |
| 314 | tecks3.TextColor3 = Color3.new(1,1,1) | |
| 315 | tecks3.TextStrokeColor3 = Color3.new(200,0,0) | |
| 316 | tecks3.Size = UDim2.new(1,0,0.5,0) | |
| 317 | for i = 1,string.len(text),1 do | |
| 318 | tecks2.Text = string.sub(text,1,i) | |
| 319 | tecks3.Text = string.sub(text,1,i) | |
| 320 | talksound:Play() | |
| 321 | wait(0.01) | |
| 322 | end | |
| 323 | wait(2) | |
| 324 | for i = 1, 50 do | |
| 325 | swait() | |
| 326 | tecks2.Position = tecks2.Position - UDim2.new(math.random(-.4,.4),math.random(-5,5),.05,math.random(-5,5)) | |
| 327 | tecks2.Rotation = tecks2.Rotation - .8 | |
| 328 | tecks2.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 329 | tecks2.TextTransparency = tecks2.TextTransparency + .04 | |
| 330 | tecks3.Position = tecks2.Position - UDim2.new(math.random(-.4,.4),math.random(-5,5),.05,math.random(-5,5)) | |
| 331 | tecks3.Rotation = tecks2.Rotation + .8 | |
| 332 | tecks3.TextStrokeTransparency = tecks2.TextStrokeTransparency +.04 | |
| 333 | tecks3.TextTransparency = tecks2.TextTransparency + .04 | |
| 334 | end | |
| 335 | naeeym2:Destroy() | |
| 336 | end) | |
| 337 | chat() | |
| 338 | end | |
| 339 | function onChatted(msg) | |
| 340 | chatfunc(msg) | |
| 341 | end | |
| 342 | plr.Chatted:connect(onChatted) | |
| 343 | chatfunc("Hmm?")
| |
| 344 | wait(1) | |
| 345 | chatfunc("Who is there?")
| |
| 346 | wait(1.2) | |
| 347 | chatfunc("Maybe it is my friend?")
| |
| 348 | wait(2) | |
| 349 | chatfunc("Brother killer?!")
| |
| 350 | wait(0.5) | |
| 351 | char.Humanoid.Name = "Sans" | |
| 352 | local music = Instance.new("Sound",char.Torso)
| |
| 353 | music.SoundId = "rbxassetid://0" | |
| 354 | music.Volume = 4 | |
| 355 | music.Looped = true | |
| 356 | music:Play() | |
| 357 | LeyeColor = BrickColor.new("Really red")
| |
| 358 | local eyemodel = Instance.new("Model",char)
| |
| 359 | eyemodel.Name = "Eyes" | |
| 360 | local reye = Instance.new("Part",eyemodel)
| |
| 361 | reye.Name = "BurningEff" | |
| 362 | reye.Color = Color3.new(1,1,1) | |
| 363 | reye.Material = "Neon" | |
| 364 | reye.Transparency = 1 | |
| 365 | local reyemesh = Instance.new("SpecialMesh",reye)
| |
| 366 | reyemesh.MeshType = "Sphere" | |
| 367 | reye.Size = Vector3.new(0.12, 0.37, 0.27) | |
| 368 | local reyeweld = Instance.new("Weld",reye)
| |
| 369 | reyeweld.Part0 = reye | |
| 370 | reyeweld.Part1 = char.Head | |
| 371 | reyeweld.C0 = CFrame.new(-0.551300049, -0.19681406, -0.198293686, 0, 0, -1, 0, 1, 0, 1, 0, 0) | |
| 372 | local leye = Instance.new("Part",eyemodel)
| |
| 373 | leye.Name = "LeftEye" | |
| 374 | leye.BrickColor = LeyeColor | |
| 375 | leye.Material = "Neon" | |
| 376 | leye.Size = Vector3.new(0.2,0.2,0.2) | |
| 377 | local leyemesh = Instance.new("SpecialMesh",leye)
| |
| 378 | leyemesh.MeshType = "Sphere" | |
| 379 | leyemesh.Scale = Vector3.new(0.7,1.1,0.7) | |
| 380 | local leyeweld = Instance.new("Weld",leye)
| |
| 381 | leyeweld.Part0 = leye | |
| 382 | leyeweld.Part1 = char.Head | |
| 383 | leyeweld.C0 = CFrame.new(-0.109999999, -0.25, 0.550000012, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
| 384 | local leyeclone = leye:Clone() | |
| 385 | leyeclone.Transparency = 1 | |
| 386 | leyeclone.Name = "RightEye" | |
| 387 | leyeclone.Parent = eyemodel | |
| 388 | for i,v in pairs(leyeclone:GetChildren()) do | |
| 389 | if v.ClassName == "Weld" then | |
| 390 | v:Destroy() | |
| 391 | end | |
| 392 | end | |
| 393 | local leyeweld2 = Instance.new("Weld",leyeclone)
| |
| 394 | leyeweld2.Part0 = leyeclone | |
| 395 | leyeweld2.Part1 = char.Head | |
| 396 | leyeweld2.C0 = CFrame.new(0.0864697844, -0.25, 0.550000012, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
| 397 | local fire = Instance.new("Fire",reye)
| |
| 398 | fire.Heat = 25000 | |
| 399 | fire.Color = leye.BrickColor.Color | |
| 400 | fire.Size = 2 | |
| 401 | -- welds xd | |
| 402 | local rhandclone = game.Players.LocalPlayer.Character.Torso["Right Shoulder"]:Clone() | |
| 403 | local rhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
| |
| 404 | rhandweld.Part0 = game.Players.LocalPlayer.Character.Torso | |
| 405 | rhandweld.Part1 = game.Players.LocalPlayer.Character["Right Arm"] | |
| 406 | rhandweld.C0 = CFrame.new(1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1) | |
| 407 | local lhandclone = game.Players.LocalPlayer.Character.Torso["Left Shoulder"]:Clone() | |
| 408 | local lhandweld = Instance.new("Weld", game.Players.LocalPlayer.Character.Torso)
| |
| 409 | lhandweld.Part0 = game.Players.LocalPlayer.Character.Torso | |
| 410 | lhandweld.Part1 = game.Players.LocalPlayer.Character["Left Arm"] | |
| 411 | lhandweld.C0 = CFrame.new(-1.5, 0, 0, 1, -1.6395192e-43, 0, -1.6395192e-43, 1, 0, 0, 0, 1) | |
| 412 | for i = 0,1 ,0.03 do | |
| 413 | lhandweld.C0 = lhandweld.C0:lerp(CFrame.new(-0.925931931, -0.0977840424, 0.974765539, 0.886040092, -0.463608712, -1.69641942e-06, 0.405292064, 0.774584651, 0.485548228, -0.225103036, -0.430215806, 0.87421),i) | |
| 414 | rhandweld.C0 = rhandweld.C0:lerp(CFrame.new(0.881086826, -0.201818228, 0.747067213, 0.882895231, 0.4695701, 1.00883415e-06, -0.397803098, 0.747956276, 0.531332433, 0.249497056, -0.469111204, 0.847163498),i) | |
| 415 | game:GetService("RunService").RenderStepped:wait()
| |
| 416 | end | |
| 417 | local slapsound = Instance.new("Sound",char.Torso)
| |
| 418 | slapsound.SoundId = "rbxassetid://511340819" | |
| 419 | slapsound.Volume = 4 | |
| 420 | -- Funcs | |
| 421 | function Blast(AAA) | |
| 422 | if AAA == "f" then | |
| 423 | local chatmath = math.random(1,3) | |
| 424 | if chatmath == 1 then | |
| 425 | chatfunc("Gaster Blaster!")
| |
| 426 | end | |
| 427 | if chatmath == 2 then | |
| 428 | chatfunc("This is what you get for killing everybody.")
| |
| 429 | end | |
| 430 | if chatmath == 3 then | |
| 431 | chatfunc("Look, I gave up trying to go back a long time ago.")
| |
| 432 | end | |
| 433 | local gasterblaster = Instance.new("Part",char.Torso)
| |
| 434 | gasterblaster.Size = Vector3.new(7, 16, 4) | |
| 435 | gasterblaster.CanCollide = false | |
| 436 | local gasterblastermesh = Instance.new("FileMesh",gasterblaster)
| |
| 437 | gasterblastermesh.MeshId = "rbxassetid://431908407" | |
| 438 | gasterblastermesh.Scale = Vector3.new(0.05,0.05,0.05) | |
| 439 | local gasterblastertexture = Instance.new("Decal",gasterblaster)
| |
| 440 | gasterblastertexture.Face = "Back" | |
| 441 | gasterblastertexture.Texture = "http://www.roblox.com/asset/?id=441975828" | |
| 442 | local weeld = Instance.new("Weld",gasterblaster)
| |
| 443 | weeld.Part0 = gasterblaster | |
| 444 | weeld.Part1 = char.Torso | |
| 445 | weeld.C0 = CFrame.new(3.71674585, -11.54426, -0.129204988, -0.999741375, 0, 0.0227420069, 0, 1, 0, -0.0227420069, 0, -0.999741375) | |
| 446 | blastsound:Play() | |
| 447 | char.Head.Anchored = true | |
| 448 | wait(1) | |
| 449 | local blast = Instance.new("Part",gasterblaster)
| |
| 450 | blast.Size = Vector3.new(18.07, 16.36, 73.54) | |
| 451 | blast.Transparency = 0.7 | |
| 452 | blast.Material = "Neon" | |
| 453 | blast.Color = Color3.new(1,1,1) | |
| 454 | blast.CanCollide = true | |
| 455 | local blastweld = Instance.new("Weld",blast)
| |
| 456 | blastweld.Part0 = blast | |
| 457 | blastweld.Part1 = gasterblaster | |
| 458 | blastweld.C0 = CFrame.new(-0.430000305, 1.73999977, -40.1399994, 1, 0, 0, 0, 1, 0, 0, 0, 1) | |
| 459 | blast.Touched:connect(function(part) | |
| 460 | part.Parent:FindFirstChildOfClass("Humanoid"):Destroy() -- Makes them not able to move
| |
| 461 | end) | |
| 462 | wait(2) | |
| 463 | char.Head.Anchored = false | |
| 464 | blast:Destroy() | |
| 465 | gasterblaster:Destroy() | |
| 466 | end | |
| 467 | end | |
| 468 | mouse.KeyDown:connect(Blast) | |
| 469 | ||
| 470 | ||
| 471 | function Death() | |
| 472 | music:Stop() | |
| 473 | local deadsound = Instance.new("Sound",char.Torso)
| |
| 474 | deadsound.SoundId = "rbxassetid://427025525" | |
| 475 | deadsound.Volume = 4 | |
| 476 | deadsound:Play() | |
| 477 | for i,v in pairs(char:GetChildren()) do | |
| 478 | if v.ClassName == "Part" then | |
| 479 | v.Transparency = 1 | |
| 480 | end | |
| 481 | leye.Transparency = 1 | |
| 482 | fire:Destroy() | |
| 483 | char.Head.face.Transparency = 1 | |
| 484 | end | |
| 485 | end | |
| 486 | char.Sans.Died:connect(Death) | |
| 487 | ||
| 488 | ||
| 489 | function Transform(key) | |
| 490 | if key == "x" then | |
| 491 | music.SoundId = "rbxassetid://0" | |
| 492 | music:Stop() | |
| 493 | music:Play() | |
| 494 | chatfunc("Hehe, forgetting something?")
| |
| 495 | leyeclone.Transparency = 0 | |
| 496 | local fire2 = Instance.new("Fire",leyeclone)
| |
| 497 | fire2.Heat = 25000 | |
| 498 | fire2.Color = leye.BrickColor.Color | |
| 499 | fire2.Size = 2 | |
| 500 | end | |
| 501 | end | |
| 502 | mouse.KeyDown:connect(Transform) | |
| 503 | ||
| 504 | ||
| 505 | ||
| 506 | ||
| 507 | --// Shortcut Variables \\-- | |
| 508 | local S = setmetatable({},{__index = function(s,i) return game:service(i) end})
| |
| 509 | local CF = {N=CFrame.new,A=CFrame.Angles,fEA=CFrame.fromEulerAnglesXYZ}
| |
| 510 | local C3 = {N=Color3.new,RGB=Color3.fromRGB,HSV=Color3.fromHSV,tHSV=Color3.toHSV}
| |
| 511 | local V3 = {N=Vector3.new,FNI=Vector3.FromNormalId,A=Vector3.FromAxis}
| |
| 512 | local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
| |
| 513 | local R3 = {N=Region3.new}
| |
| 514 | local De = S.Debris | |
| 515 | local WS = workspace | |
| 516 | local Lght = S.Lighting | |
| 517 | local RepS = S.ReplicatedStorage | |
| 518 | local IN = Instance.new | |
| 519 | local Plrs = S.Players | |
| 520 | ||
| 521 | local Emit = IN("ParticleEmitter").Emit;
| |
| 522 | ||
| 523 | --// Initializing \\-- | |
| 524 | local Plr = Plrs.LocalPlayer | |
| 525 | local Char = Plr.Character | |
| 526 | local Hum = Char:FindFirstChildOfClass'Humanoid' | |
| 527 | local RArm = Char["Right Arm"] | |
| 528 | local LArm = Char["Left Arm"] | |
| 529 | local RLeg = Char["Right Leg"] | |
| 530 | local LLeg = Char["Left Leg"] | |
| 531 | local Root = Char:FindFirstChild'HumanoidRootPart' | |
| 532 | local Torso = Char.Torso | |
| 533 | local Head = Char.Head | |
| 534 | local NeutralAnims = true | |
| 535 | local Attack = false | |
| 536 | local Debounces = {Debounces={}}
| |
| 537 | local Mouse = Plr:GetMouse() | |
| 538 | local Hit = {}
| |
| 539 | local Sine = 0 | |
| 540 | local Change = 1 | |
| 541 | ||
| 542 | local Effects = IN("Folder",Char)
| |
| 543 | Effects.Name = "Effects" | |
| 544 | ||
| 545 | ||
| 546 | ||
| 547 | --// Music \\-- | |
| 548 | ||
| 549 | ||
| 550 | ||
| 551 | --// Debounce System \\-- | |
| 552 | ||
| 553 | ||
| 554 | function Debounces:New(name,cooldown) | |
| 555 | local aaaaa = {Usable=true,Cooldown=cooldown or 2,CoolingDown=false,LastUse=0}
| |
| 556 | setmetatable(aaaaa,{__index = Debounces})
| |
| 557 | Debounces.Debounces[name] = aaaaa | |
| 558 | return aaaaa | |
| 559 | end | |
| 560 | ||
| 561 | function Debounces:Use(overrideUsable) | |
| 562 | assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use") | |
| 563 | if(self.Usable or overrideUsable)then | |
| 564 | self.Usable = false | |
| 565 | self.CoolingDown = true | |
| 566 | local LastUse = time() | |
| 567 | self.LastUse = LastUse | |
| 568 | delay(self.Cooldown or 2,function() | |
| 569 | if(self.LastUse == LastUse)then | |
| 570 | self.CoolingDown = false | |
| 571 | self.Usable = true | |
| 572 | end | |
| 573 | end) | |
| 574 | end | |
| 575 | end | |
| 576 | ||
| 577 | function Debounces:Get(name) | |
| 578 | assert(typeof(name) == 'string',("bad argument #1 to 'get' (string expected, got %s)"):format(typeof(name) == nil and "no value" or typeof(name)))
| |
| 579 | for i,v in next, Debounces.Debounces do | |
| 580 | if(i == name)then | |
| 581 | return v; | |
| 582 | end | |
| 583 | end | |
| 584 | end | |
| 585 | ||
| 586 | function Debounces:GetProgressPercentage() | |
| 587 | assert(self.Usable ~= nil and self.LastUse ~= nil and self.CoolingDown ~= nil,"Expected ':' not '.' calling member function Use") | |
| 588 | if(self.CoolingDown and not self.Usable)then | |
| 589 | return math.max( | |
| 590 | math.floor( | |
| 591 | ( | |
| 592 | (time()-self.LastUse)/self.Cooldown or 2 | |
| 593 | )*100 | |
| 594 | ) | |
| 595 | ) | |
| 596 | else | |
| 597 | return 100 | |
| 598 | end | |
| 599 | end | |
| 600 | ||
| 601 | --// Instance Creation Functions \\-- | |
| 602 | ||
| 603 | function Sound(parent,id,pitch,volume,looped,effect,autoPlay) | |
| 604 | local Sound = IN("Sound")
| |
| 605 | Sound.SoundId = "rbxassetid://".. tostring(id or 0) | |
| 606 | Sound.Pitch = pitch or 1 | |
| 607 | Sound.Volume = volume or 1 | |
| 608 | Sound.Looped = looped or false | |
| 609 | if(autoPlay)then | |
| 610 | coroutine.wrap(function() | |
| 611 | repeat wait() until Sound.IsLoaded | |
| 612 | Sound.Playing = autoPlay or false | |
| 613 | end)() | |
| 614 | end | |
| 615 | if(not looped and effect)then | |
| 616 | Sound.Stopped:connect(function() | |
| 617 | Sound.Volume = 0 | |
| 618 | Sound:destroy() | |
| 619 | end) | |
| 620 | elseif(effect)then | |
| 621 | warn("Sound can't be looped and a sound effect!")
| |
| 622 | end | |
| 623 | Sound.Parent =parent or Torso | |
| 624 | return Sound | |
| 625 | end | |
| 626 | function Part(parent,color,material,size,cframe,anchored,cancollide) | |
| 627 | local part = IN("Part")
| |
| 628 | part.Parent = parent or Char | |
| 629 | part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or C3.N(0,0,0) | |
| 630 | part.Material = material or Enum.Material.SmoothPlastic | |
| 631 | part.TopSurface,part.BottomSurface=10,10 | |
| 632 | part.Size = size or V3.N(1,1,1) | |
| 633 | part.CFrame = cframe or CF.N(0,0,0) | |
| 634 | part.CanCollide = cancollide or false | |
| 635 | part.Anchored = anchored or false | |
| 636 | return part | |
| 637 | end | |
| 638 | ||
| 639 | function Weld(part0,part1,c0,c1) | |
| 640 | local weld = IN("Weld")
| |
| 641 | weld.Parent = part0 | |
| 642 | weld.Part0 = part0 | |
| 643 | weld.Part1 = part1 | |
| 644 | weld.C0 = c0 or CF.N() | |
| 645 | weld.C1 = c1 or CF.N() | |
| 646 | return weld | |
| 647 | end | |
| 648 | ||
| 649 | function Mesh(parent,meshtype,meshid,textid,scale,offset) | |
| 650 | local part = IN("SpecialMesh")
| |
| 651 | part.MeshId = meshid or "" | |
| 652 | part.TextureId = textid or "" | |
| 653 | part.Scale = scale or V3.N(1,1,1) | |
| 654 | part.Offset = offset or V3.N(0,0,0) | |
| 655 | part.MeshType = meshtype or Enum.MeshType.Sphere | |
| 656 | part.Parent = parent | |
| 657 | return part | |
| 658 | end | |
| 659 | ||
| 660 | NewInstance = function(instance,parent,properties) | |
| 661 | local inst = Instance.new(instance) | |
| 662 | inst.Parent = parent | |
| 663 | if(properties)then | |
| 664 | for i,v in next, properties do | |
| 665 | pcall(function() inst[i] = v end) | |
| 666 | end | |
| 667 | end | |
| 668 | return inst; | |
| 669 | end | |
| 670 | ||
| 671 | function Clone(instance,parent,properties) | |
| 672 | local inst = instance:Clone() | |
| 673 | inst.Parent = parent | |
| 674 | if(properties)then | |
| 675 | for i,v in next, properties do | |
| 676 | pcall(function() inst[i] = v end) | |
| 677 | end | |
| 678 | end | |
| 679 | return inst; | |
| 680 | end | |
| 681 | ||
| 682 | function SoundPart(id,pitch,volume,looped,effect,autoPlay,cf) | |
| 683 | local soundPart = NewInstance("Part",Effects,{Transparency=1,CFrame=cf or Torso.CFrame,Anchored=true,CanCollide=false,Size=V3.N()})
| |
| 684 | local Sound = IN("Sound")
| |
| 685 | Sound.SoundId = "rbxassetid://".. tostring(id or 0) | |
| 686 | Sound.Pitch = pitch or 1 | |
| 687 | Sound.Volume = volume or 1 | |
| 688 | Sound.Looped = looped or false | |
| 689 | if(autoPlay)then | |
| 690 | coroutine.wrap(function() | |
| 691 | repeat wait() until Sound.IsLoaded | |
| 692 | Sound.Playing = autoPlay or false | |
| 693 | end)() | |
| 694 | end | |
| 695 | if(not looped and effect)then | |
| 696 | Sound.Stopped:connect(function() | |
| 697 | Sound.Volume = 0 | |
| 698 | soundPart:destroy() | |
| 699 | end) | |
| 700 | elseif(effect)then | |
| 701 | warn("Sound can't be looped and a sound effect!")
| |
| 702 | end | |
| 703 | Sound.Parent = soundPart | |
| 704 | return Sound | |
| 705 | end | |
| 706 | ||
| 707 | ||
| 708 | --// Extended ROBLOX tables \\-- | |
| 709 | local Instance = setmetatable({ClearChildrenOfClass = function(where,class,recursive) local children = (recursive and where:GetDescendants() or where:GetChildren()) for _,v in next, children do if(v:IsA(class))then v:destroy();end;end;end},{__index = Instance})
| |
| 710 | --// Require stuff \\-- | |
| 711 | function CamShake(who,times,intense,origin) | |
| 712 | coroutine.wrap(function() | |
| 713 | if(script:FindFirstChild'CamShake')then | |
| 714 | local cam = script.CamShake:Clone() | |
| 715 | cam:WaitForChild'intensity'.Value = intense | |
| 716 | cam:WaitForChild'times'.Value = times | |
| 717 | ||
| 718 | if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
| |
| 719 | cam.Parent = who | |
| 720 | wait() | |
| 721 | cam.Disabled = false | |
| 722 | elseif(who == Plr or who == Char)then | |
| 723 | local intensity = intense | |
| 724 | local cam = workspace.CurrentCamera | |
| 725 | for i = 1, times do | |
| 726 | local camDistFromOrigin | |
| 727 | if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then | |
| 728 | camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25 | |
| 729 | elseif(typeof(origin) == 'Vector3')then | |
| 730 | camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25 | |
| 731 | end | |
| 732 | if(camDistFromOrigin)then | |
| 733 | intensity = math.min(intense, math.floor(intense/camDistFromOrigin)) | |
| 734 | end | |
| 735 | cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4) | |
| 736 | swait() | |
| 737 | end | |
| 738 | end | |
| 739 | end)() | |
| 740 | end | |
| 741 | ||
| 742 | function CamShakeAll(times,intense,origin) | |
| 743 | for _,v in next, Plrs:players() do | |
| 744 | CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin) | |
| 745 | end | |
| 746 | end | |
| 747 | ||
| 748 | function ServerScript(code) | |
| 749 | if(script:FindFirstChild'Loadstring')then | |
| 750 | local load = script.Loadstring:Clone() | |
| 751 | load:WaitForChild'Sauce'.Value = code | |
| 752 | load.Disabled = false | |
| 753 | load.Parent = workspace | |
| 754 | elseif(NS and typeof(NS) == 'function')then | |
| 755 | NS(code,workspace) | |
| 756 | else | |
| 757 | warn("no serverscripts lol")
| |
| 758 | end | |
| 759 | end | |
| 760 | ||
| 761 | function RunLocal(where,code) | |
| 762 | ServerScript([[ | |
| 763 | wait() | |
| 764 | script.Parent=nil | |
| 765 | if(not _G.Http)then _G.Http = game:service'HttpService' end | |
| 766 | ||
| 767 | local Http = _G.Http or game:service'HttpService' | |
| 768 | ||
| 769 | local source = ]].."[["..code.."]]"..[[ | |
| 770 | local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php" | |
| 771 | local asd = Http:PostAsync(link,source) | |
| 772 | repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID | |
| 773 | local ID = Http:JSONDecode(asd).Result.Require_ID | |
| 774 | local vs = require(ID).VORTH_SCRIPT | |
| 775 | vs.Parent = game.]]..where:GetFullName() | |
| 776 | ) | |
| 777 | end | |
| 778 | ||
| 779 | --// Customization \\-- | |
| 780 | ||
| 781 | local Frame_Speed = 60; | |
| 782 | local WalkSpeed = 16 | |
| 783 | local DamageColor = BrickColor.new'White' | |
| 784 | ||
| 785 | local MagicCircles = {
| |
| 786 | Default = {Color=C3.N(255,0,0),Texture1=0,Texture2=0},
| |
| 787 | OrangeWarPheonix = {EffectColor=BrickColor.new'Deep orange'.Color,Color=C3.N(.9,.9,.9),Texture1=623153986,Texture2=623153990},
| |
| 788 | BlueWarPheonix = {EffectColor=BrickColor.new'Teal'.Color,Color=C3.N(.9,.9,.9),Texture1=462499935,Texture2=462499970},
| |
| 789 | Plasma = {Color=C3.N(0.70588235294118,0,0.8),Texture1=415906687,Texture2=415906702},
| |
| 790 | Water = {Color=C3.RGB(33, 84, 185),Texture1=408441330,Texture2=408441353},
| |
| 791 | Earth = {Color=C3.RGB(86, 36, 36),Texture1=394253616,Texture2=394253651},
| |
| 792 | Wind = {Color=C3.N(.8,.8,.8),Texture1=376006317,Texture2=376006346},
| |
| 793 | Poseidon = {Color=C3.RGB(71, 99, 130),Texture1=346727970,Texture2=346727994},
| |
| 794 | AetherLightning = {Color=C3.RGB(23, 255, 197),Texture1=348320016,Texture2=348320030},
| |
| 795 | Light = {Color=C3.N(1,1,0),Texture1=343192085,Texture2=343192112},
| |
| 796 | Fire = {Color=C3.N(1,0,0),EffectColor=BrickColor.new'Bright red'.Color,Texture1=313945544,Texture2=313945673},
| |
| 797 | Lightning = {Color=C3.N(0,1,1),Texture1=314842290,Texture2=314842440},
| |
| 798 | GasterBlaster = {Color=C3.N(255,0,0),Texture1=331948662,Texture2=331948662}
| |
| 799 | } | |
| 800 | ||
| 801 | local MagicVariant = MagicCircles.GasterBlaster --[[ You can change this for a different element | |
| 802 | Example: | |
| 803 | ||
| 804 | Changing MagicCircles.GasterBlaster to MagicCircles.Light | |
| 805 | ||
| 806 | would make it a Light Element | |
| 807 | ]] | |
| 808 | ||
| 809 | --// Stop animations \\-- | |
| 810 | for _,v in next, Hum:GetPlayingAnimationTracks() do | |
| 811 | v:Stop(); | |
| 812 | end | |
| 813 | ||
| 814 | pcall(game.Destroy,Char:FindFirstChild'Animate') | |
| 815 | pcall(game.Destroy,Hum:FindFirstChild'Animator') | |
| 816 | ||
| 817 | --// Joints \\-- | |
| 818 | ||
| 819 | local LS = NewInstance('Motor',Char,{Part0=Torso,Part1=LArm,C0 = CF.N(-1.5,0.5,0),C1 = CF.N(0,.5,0)})
| |
| 820 | local RS = NewInstance('Motor',Char,{Part0=Torso,Part1=RArm,C0 = CF.N(1.5,0.5,0),C1 = CF.N(0,.5,0)})
| |
| 821 | local NK = NewInstance('Motor',Char,{Part0=Torso,Part1=Head,C0 = CF.N(0,1.5,0)})
| |
| 822 | local LH = NewInstance('Motor',Char,{Part0=Torso,Part1=LLeg,C0 = CF.N(-.5,-1,0),C1 = CF.N(0,1,0)})
| |
| 823 | local RH = NewInstance('Motor',Char,{Part0=Torso,Part1=RLeg,C0 = CF.N(.5,-1,0),C1 = CF.N(0,1,0)})
| |
| 824 | local RJ = NewInstance('Motor',Char,{Part0=Root,Part1=Torso})
| |
| 825 | ||
| 826 | local LSC0 = LS.C0 | |
| 827 | local RSC0 = RS.C0 | |
| 828 | local NKC0 = NK.C0 | |
| 829 | local LHC0 = LH.C0 | |
| 830 | local RHC0 = RH.C0 | |
| 831 | local RJC0 = RJ.C0 | |
| 832 | ||
| 833 | --// Artificial HB \\-- | |
| 834 | ||
| 835 | local ArtificialHB = IN("BindableEvent", script)
| |
| 836 | ArtificialHB.Name = "Heartbeat" | |
| 837 | ||
| 838 | script:WaitForChild("Heartbeat")
| |
| 839 | ||
| 840 | local tf = 0 | |
| 841 | local allowframeloss = false | |
| 842 | local tossremainder = false | |
| 843 | local lastframe = tick() | |
| 844 | local frame = 1/Frame_Speed | |
| 845 | ArtificialHB:Fire() | |
| 846 | ||
| 847 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 848 | tf = tf + s | |
| 849 | if tf >= frame then | |
| 850 | if allowframeloss then | |
| 851 | script.Heartbeat:Fire() | |
| 852 | lastframe = tick() | |
| 853 | else | |
| 854 | for i = 1, math.floor(tf / frame) do | |
| 855 | ArtificialHB:Fire() | |
| 856 | end | |
| 857 | lastframe = tick() | |
| 858 | end | |
| 859 | if tossremainder then | |
| 860 | tf = 0 | |
| 861 | else | |
| 862 | tf = tf - frame * math.floor(tf / frame) | |
| 863 | end | |
| 864 | end | |
| 865 | end) | |
| 866 | ||
| 867 | function swait(num) | |
| 868 | if num == 0 or num == nil then | |
| 869 | ArtificialHB.Event:wait() | |
| 870 | else | |
| 871 | for i = 0, num do | |
| 872 | ArtificialHB.Event:wait() | |
| 873 | end | |
| 874 | end | |
| 875 | end | |
| 876 | ||
| 877 | ||
| 878 | --// Effect Function(s) \\-- | |
| 879 | ||
| 880 | function NumSeq(...) | |
| 881 | local tab = {...}
| |
| 882 | local Sequence = {}
| |
| 883 | for _,v in next, tab do | |
| 884 | table.insert(Sequence,NumberSequenceKeypoint.new(unpack(v))) | |
| 885 | end | |
| 886 | if(tab[#tab][1] ~= 1)then | |
| 887 | local final = tab[#tab] | |
| 888 | table.insert(Sequence,NumberSequenceKeypoint.new(1,final[2],final[3])) | |
| 889 | end | |
| 890 | return NumberSequence.new(Sequence) | |
| 891 | end | |
| 892 | ||
| 893 | local DefaultRingParticle = IN("ParticleEmitter")
| |
| 894 | DefaultRingParticle.Name = 'RingEmit' | |
| 895 | DefaultRingParticle.LightEmission = 1 | |
| 896 | DefaultRingParticle.Size = NumSeq({0,0},{.7,6.28},{.8,5.03},{1,2.9})
| |
| 897 | DefaultRingParticle.Texture = "rbxassetid://313951123" | |
| 898 | DefaultRingParticle.Transparency = NumberSequence.new(0,1) | |
| 899 | DefaultRingParticle.ZOffset = 1 | |
| 900 | DefaultRingParticle.Drag = 0 | |
| 901 | DefaultRingParticle.Acceleration = V3.N() | |
| 902 | DefaultRingParticle.LockedToPart = true | |
| 903 | DefaultRingParticle.Enabled = false | |
| 904 | DefaultRingParticle.Lifetime = NumberRange.new(.6,.6) | |
| 905 | DefaultRingParticle.Rate = 5 | |
| 906 | DefaultRingParticle.Rotation = NumberRange.new(0,0) | |
| 907 | DefaultRingParticle.RotSpeed = NumberRange.new(0,0) | |
| 908 | DefaultRingParticle.Speed = NumberRange.new(0,0) | |
| 909 | DefaultRingParticle.SpreadAngle = Vector2.new(0,0) | |
| 910 | ||
| 911 | function MagicCircle(Data) | |
| 912 | local Variant = Data.Variant or MagicCircles.Default; | |
| 913 | ||
| 914 | local Size = Data.Size or 10; | |
| 915 | local Pos = Data.Pos*CF.A(M.R(-90),M.R(-90),0) or Torso.CFrame*CF.A(M.R(-90),M.R(-90),0); | |
| 916 | local GrowTime = Data.Time or 1; | |
| 917 | ||
| 918 | local WeldData = Data.Weld or false; | |
| 919 | ||
| 920 | ||
| 921 | local Color = Variant.Color or C3.N(.9,.9,.0) | |
| 922 | ||
| 923 | local CreationParticle = Data.CreationParticle or DefaultRingParticle; | |
| 924 | ||
| 925 | ||
| 926 | local Circle = Part(Effects,BrickColor.new'Maroon',Enum.Material.SmoothPlastic,V3.N(.05,.05,.05),Pos,true,false) | |
| 927 | local CircleM = NewInstance("BlockMesh",Circle,{Scale=V3.N()})
| |
| 928 | ||
| 929 | ||
| 930 | local Emitter = DefaultRingParticle:Clone(); | |
| 931 | Emitter.Parent = Circle | |
| 932 | Emitter.Color = ColorSequence.new(Variant.Color) | |
| 933 | ||
| 934 | local Top = IN("Decal",Circle)
| |
| 935 | Top.Texture = "rbxassetid://"..Variant.Texture1 | |
| 936 | Top.Face = Enum.NormalId.Top | |
| 937 | ||
| 938 | local Btm = IN("Decal",Circle)
| |
| 939 | Btm.Texture = "rbxassetid://"..Variant.Texture2 | |
| 940 | Btm.Face = Enum.NormalId.Bottom | |
| 941 | ||
| 942 | if(WeldData)then | |
| 943 | Circle.Anchored = false | |
| 944 | Weld(WeldData,Circle,Pos,CF.N()) | |
| 945 | end | |
| 946 | local GrowFrames = GrowTime * Frame_Speed | |
| 947 | print(GrowFrames) | |
| 948 | --Size*20,0,Size*20 | |
| 949 | Circle.Transparency = 1 | |
| 950 | local GrownEvent = Instance.new("BindableEvent",Circle)
| |
| 951 | coroutine.wrap(function() | |
| 952 | ||
| 953 | Emit(Emitter,5) | |
| 954 | local End = Size*20 | |
| 955 | local grow = End/GrowFrames | |
| 956 | for i = 1, GrowFrames+1 do | |
| 957 | local aa = math.min(CircleM.Scale.x + grow,End) | |
| 958 | if(aa >= End)then break end | |
| 959 | CircleM.Scale = V3.N(aa,0,aa) | |
| 960 | swait() | |
| 961 | end | |
| 962 | CircleM.Scale = V3.N(End,0,End) | |
| 963 | GrownEvent:Fire() | |
| 964 | ||
| 965 | end)() | |
| 966 | ||
| 967 | local Table = {
| |
| 968 | Circle = Circle, | |
| 969 | Mesh = CircleM, | |
| 970 | Grow = function(size) | |
| 971 | CircleM.Scale = CircleM.Scale + V3.N(size*20,0,size*20) | |
| 972 | end, | |
| 973 | Destroy = function(timer) | |
| 974 | coroutine.wrap(function() | |
| 975 | if(not timer)then timer = 1 end | |
| 976 | Tween(CircleM,{Scale=V3.N(0,0,0)},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
| |
| 977 | Tween(Top,{Transparency=1},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
| |
| 978 | Tween(Btm,{Transparency=1},timer,Enum.EasingStyle.Quad,Enum.EasingDirection.Out)
| |
| 979 | S.Debris:AddItem(Circle,timer+1) | |
| 980 | end)() | |
| 981 | end, | |
| 982 | Grown = GrownEvent.Event | |
| 983 | } | |
| 984 | ||
| 985 | return Table; | |
| 986 | end | |
| 987 | ||
| 988 | function Bezier(startpos, pos2, pos3, endpos, t) | |
| 989 | local A = startpos:lerp(pos2, t) | |
| 990 | local B = pos2:lerp(pos3, t) | |
| 991 | local C = pos3:lerp(endpos, t) | |
| 992 | local lerp1 = A:lerp(B, t) | |
| 993 | local lerp2 = B:lerp(C, t) | |
| 994 | local cubic = lerp1:lerp(lerp2, t) | |
| 995 | return cubic | |
| 996 | end | |
| 997 | ||
| 998 | function SphereFX(duration,color,scale,pos,endScale,increment) | |
| 999 | return Effect{
| |
| 1000 | Frames=duration, | |
| 1001 | Effect='ResizeAndFade', | |
| 1002 | Color=color, | |
| 1003 | Size=scale, | |
| 1004 | Mesh={MeshType=Enum.MeshType.Sphere},
| |
| 1005 | CFrame=pos, | |
| 1006 | FXSettings={
| |
| 1007 | EndSize=endScale, | |
| 1008 | EndIsIncrement=increment | |
| 1009 | } | |
| 1010 | } | |
| 1011 | end | |
| 1012 | ||
| 1013 | function BlastFX(duration,color,scale,pos,endScale,increment) | |
| 1014 | return Effect{
| |
| 1015 | Frames=duration, | |
| 1016 | Effect='ResizeAndFade', | |
| 1017 | Color=color, | |
| 1018 | Size=scale, | |
| 1019 | Mesh={MeshType=Enum.MeshType.FileMesh,MeshId='rbxassetid://20329976'},
| |
| 1020 | CFrame=pos, | |
| 1021 | FXSettings={
| |
| 1022 | EndSize=endScale, | |
| 1023 | EndIsIncrement=increment | |
| 1024 | } | |
| 1025 | } | |
| 1026 | end | |
| 1027 | ||
| 1028 | function BlockFX(duration,color,scale,pos,endScale,increment) | |
| 1029 | return Effect{
| |
| 1030 | Frames=duration, | |
| 1031 | Effect='ResizeAndFade', | |
| 1032 | Color=color, | |
| 1033 | Size=scale, | |
| 1034 | CFrame=pos, | |
| 1035 | FXSettings={
| |
| 1036 | EndSize=endScale, | |
| 1037 | EndIsIncrement=increment | |
| 1038 | } | |
| 1039 | } | |
| 1040 | end | |
| 1041 | ||
| 1042 | function ShootBullet(data) | |
| 1043 | --ShootBullet{Size=V3.N(3,3,3),Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
| |
| 1044 | local Size = data.Size or V3.N(2,2,2) | |
| 1045 | local Color = data.Color or MagicVariant.EffectColor or MagicVariant.Color | |
| 1046 | local StudsPerFrame = data.Speed or 10 | |
| 1047 | local Shape = data.Shape or 'Ball' | |
| 1048 | local Frames = data.Frames or 160 | |
| 1049 | local Pos = data.Origin or Torso.CFrame | |
| 1050 | local Direction = data.Direction or Mouse.Hit | |
| 1051 | local Material = data.Material or Enum.Material.Neon | |
| 1052 | local OnHit = data.HitFunction or function(hit,pos) | |
| 1053 | Effect{
| |
| 1054 | Effect='ResizeAndFade', | |
| 1055 | Color=Color, | |
| 1056 | Size=V3.N(10,10,10), | |
| 1057 | Mesh={MeshType=Enum.MeshType.Sphere},
| |
| 1058 | CFrame=CF.N(pos), | |
| 1059 | FXSettings={
| |
| 1060 | EndSize=V3.N(.05,.05,.05), | |
| 1061 | EndIsIncrement=true | |
| 1062 | } | |
| 1063 | } | |
| 1064 | for i = 1, 5 do | |
| 1065 | local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)) | |
| 1066 | Effect{
| |
| 1067 | Effect='Fade', | |
| 1068 | Frames=65, | |
| 1069 | Size=V3.N(5,5,10), | |
| 1070 | CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-10).p,pos), | |
| 1071 | Mesh = {MeshType=Enum.MeshType.Sphere},
| |
| 1072 | Material=Enum.Material.Neon, | |
| 1073 | Color=Color, | |
| 1074 | MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p, | |
| 1075 | } | |
| 1076 | end | |
| 1077 | AOEDamage(pos,10,15,30,0,'Normal',10,4) | |
| 1078 | end | |
| 1079 | ||
| 1080 | local Bullet = Part(Effects,Color,Material,Size,Pos,true,false) | |
| 1081 | local BMesh = Mesh(Bullet,Enum.MeshType.Brick,"","",V3.N(1,1,1),V3.N()) | |
| 1082 | if(Shape == 'Ball')then | |
| 1083 | BMesh.MeshType = Enum.MeshType.Sphere | |
| 1084 | elseif(Shape == 'Head')then | |
| 1085 | BMesh.MeshType = Enum.MeshType.Head | |
| 1086 | elseif(Shape == 'Cylinder')then | |
| 1087 | BMesh.MeshType = Enum.MeshType.Cylinder | |
| 1088 | end | |
| 1089 | ||
| 1090 | coroutine.wrap(function() | |
| 1091 | for i = 1, Frames+1 do | |
| 1092 | local hit,pos,norm,dist = CastRay(Bullet.CFrame.p,CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame).p,StudsPerFrame) | |
| 1093 | if(hit)then | |
| 1094 | OnHit(hit,pos,norm,dist) | |
| 1095 | break; | |
| 1096 | else | |
| 1097 | Bullet.CFrame = CF.N(Bullet.CFrame.p,Direction.p)*CF.N(0,0,-StudsPerFrame) | |
| 1098 | end | |
| 1099 | swait() | |
| 1100 | end | |
| 1101 | Bullet:destroy() | |
| 1102 | end)() | |
| 1103 | ||
| 1104 | end | |
| 1105 | ||
| 1106 | function Zap(data) | |
| 1107 | local sCF,eCF = data.StartCFrame,data.EndCFrame | |
| 1108 | assert(sCF,"You need a start CFrame!") | |
| 1109 | assert(eCF,"You need an end CFrame!") | |
| 1110 | local parts = data.PartCount or 15 | |
| 1111 | local zapRot = data.ZapRotation or {-5,5}
| |
| 1112 | local startThick = data.StartSize or 3; | |
| 1113 | local endThick = data.EndSize or startThick/2; | |
| 1114 | local color = data.Color or BrickColor.new'Electric blue' | |
| 1115 | local delay = data.Delay or 35 | |
| 1116 | local delayInc = data.DelayInc or 0 | |
| 1117 | local lastLightning; | |
| 1118 | local MagZ = (sCF.p - eCF.p).magnitude | |
| 1119 | local thick = startThick | |
| 1120 | local inc = (startThick/parts)-(endThick/parts) | |
| 1121 | ||
| 1122 | for i = 1, parts do | |
| 1123 | local pos = sCF.p | |
| 1124 | if(lastLightning)then | |
| 1125 | pos = lastLightning.CFrame*CF.N(0,0,MagZ/parts/2).p | |
| 1126 | end | |
| 1127 | delay = delay + delayInc | |
| 1128 | local zapPart = Part(Effects,color,Enum.Material.Neon,V3.N(thick,thick,MagZ/parts),CF.N(pos),true,false) | |
| 1129 | local posie = CF.N(pos,eCF.p)*CF.N(0,0,MagZ/parts).p+V3.N(M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot)),M.RNG(unpack(zapRot))) | |
| 1130 | if(parts == i)then | |
| 1131 | local MagZ = (pos-eCF.p).magnitude | |
| 1132 | zapPart.Size = V3.N(endThick,endThick,MagZ) | |
| 1133 | zapPart.CFrame = CF.N(pos, eCF.p)*CF.N(0,0,-MagZ/2) | |
| 1134 | Effect{Effect='ResizeAndFade',Size=V3.N(thick,thick,thick),CFrame=eCF*CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)),Color=color,Frames=delay*2,FXSettings={EndSize=V3.N(thick*8,thick*8,thick*8)}}
| |
| 1135 | else | |
| 1136 | zapPart.CFrame = CF.N(pos,posie)*CF.N(0,0,MagZ/parts/2) | |
| 1137 | end | |
| 1138 | ||
| 1139 | lastLightning = zapPart | |
| 1140 | Effect{Effect='Fade',Manual=zapPart,Frames=delay}
| |
| 1141 | ||
| 1142 | thick=thick-inc | |
| 1143 | ||
| 1144 | end | |
| 1145 | end | |
| 1146 | ||
| 1147 | function Zap2(data) | |
| 1148 | local Color = data.Color or BrickColor.new'Electric blue' | |
| 1149 | local StartPos = data.Start or Torso.Position | |
| 1150 | local EndPos = data.End or Mouse.Hit.p | |
| 1151 | local SegLength = data.SegL or 2 | |
| 1152 | local Thicc = data.Thickness or 0.5 | |
| 1153 | local Fades = data.Fade or 45 | |
| 1154 | local Parent = data.Parent or Effects | |
| 1155 | local MaxD = data.MaxDist or 200 | |
| 1156 | local Branch = data.Branches or false | |
| 1157 | local Material = data.Material or Enum.Material.Neon | |
| 1158 | local Raycasts = data.Raycasts or false | |
| 1159 | local Offset = data.Offset or {0,360}
| |
| 1160 | local AddMesh = (data.Mesh == nil and true or data.Mesh) | |
| 1161 | if((StartPos-EndPos).magnitude > MaxD)then | |
| 1162 | EndPos = CF.N(StartPos,EndPos)*CF.N(0,0,-MaxD).p | |
| 1163 | end | |
| 1164 | local hit,pos,norm,dist=nil,EndPos,nil,(StartPos-EndPos).magnitude | |
| 1165 | if(Raycasts)then | |
| 1166 | hit,pos,norm,dist = CastRay(StartPos,EndPos,MaxD) | |
| 1167 | end | |
| 1168 | local segments = dist/SegLength | |
| 1169 | local model = IN("Model",Parent)
| |
| 1170 | model.Name = 'Lightning' | |
| 1171 | local Last; | |
| 1172 | for i = 1, segments do | |
| 1173 | local size = (segments-i)/25 | |
| 1174 | local prt = Part(model,Color,Material,V3.N(Thicc+size,SegLength,Thicc+size),CF.N(),true,false) | |
| 1175 | if(AddMesh)then IN("CylinderMesh",prt) end
| |
| 1176 | if(Last and math.floor(segments) == i)then | |
| 1177 | local MagZ = (Last.CFrame*CF.N(0,-SegLength/2,0).p-EndPos).magnitude | |
| 1178 | prt.Size = V3.N(Thicc+size,MagZ,Thicc+size) | |
| 1179 | prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,EndPos)*CF.A(M.R(90),0,0)*CF.N(0,-MagZ/2,0) | |
| 1180 | elseif(not Last)then | |
| 1181 | prt.CFrame = CF.N(StartPos,pos)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0) | |
| 1182 | else | |
| 1183 | prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,CF.N(pos)*CF.A(M.R(M.RNG(0,360)),M.R(M.RNG(0,360)),M.R(M.RNG(0,360)))*CF.N(0,0,SegLength/3+(segments-i)).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0) | |
| 1184 | end | |
| 1185 | Last = prt | |
| 1186 | if(Branch)then | |
| 1187 | local choice = M.RNG(1,7+((segments-i)*2)) | |
| 1188 | if(choice == 1)then | |
| 1189 | local LastB; | |
| 1190 | for i2 = 1,M.RNG(2,5) do | |
| 1191 | local size2 = ((segments-i)/35)/i2 | |
| 1192 | local prt = Part(model,Color,Material,V3.N(Thicc+size2,SegLength,Thicc+size2),CF.N(),true,false) | |
| 1193 | if(AddMesh)then IN("CylinderMesh",prt) end
| |
| 1194 | if(not LastB)then | |
| 1195 | prt.CFrame = CF.N(Last.CFrame*CF.N(0,-SegLength/2,0).p,Last.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0) | |
| 1196 | else | |
| 1197 | prt.CFrame = CF.N(LastB.CFrame*CF.N(0,-SegLength/2,0).p,LastB.CFrame*CF.N(0,-SegLength/2,0)*CF.A(0,0,M.RRNG(0,360))*CF.N(0,Thicc*7,0)*CF.N(0,0,-1).p)*CF.A(M.R(90),0,0)*CF.N(0,-SegLength/2,0) | |
| 1198 | end | |
| 1199 | LastB = prt | |
| 1200 | end | |
| 1201 | end | |
| 1202 | end | |
| 1203 | end | |
| 1204 | if(Fades > 0)then | |
| 1205 | coroutine.wrap(function() | |
| 1206 | for i = 1, Fades do | |
| 1207 | for _,v in next, model:children() do | |
| 1208 | if(v:IsA'BasePart')then | |
| 1209 | v.Transparency = (i/Fades) | |
| 1210 | end | |
| 1211 | end | |
| 1212 | swait() | |
| 1213 | end | |
| 1214 | model:destroy() | |
| 1215 | end)() | |
| 1216 | else | |
| 1217 | S.Debris:AddItem(model,.01) | |
| 1218 | end | |
| 1219 | return {End=(Last and Last.CFrame*CF.N(0,-Last.Size.Y/2,0).p),Last=Last,Model=model}
| |
| 1220 | end | |
| 1221 | ||
| 1222 | function Tween(obj,props,time,easing,direction,repeats,backwards) | |
| 1223 | local info = TweenInfo.new(time or .5, easing or Enum.EasingStyle.Quad, direction or Enum.EasingDirection.Out, repeats or 0, backwards or false) | |
| 1224 | local tween = S.TweenService:Create(obj, info, props) | |
| 1225 | ||
| 1226 | tween:Play() | |
| 1227 | end | |
| 1228 | ||
| 1229 | function Effect(data) | |
| 1230 | local FX = data.Effect or 'ResizeAndFade' | |
| 1231 | local Parent = data.Parent or Effects | |
| 1232 | local Color = data.Color or C3.N(0,0,0) | |
| 1233 | local Size = data.Size or V3.N(1,1,1) | |
| 1234 | local MoveDir = data.MoveDirection or nil | |
| 1235 | local MeshData = data.Mesh or nil | |
| 1236 | local SndData = data.Sound or nil | |
| 1237 | local Frames = data.Frames or 45 | |
| 1238 | local Manual = data.Manual or nil | |
| 1239 | local Material = data.Material or Enum.Material.Neon | |
| 1240 | local CFra = data.CFrame or Torso.CFrame | |
| 1241 | local Settings = data.FXSettings or {}
| |
| 1242 | local Shape = data.Shape or Enum.PartType.Block | |
| 1243 | local Snd,Prt,Msh; | |
| 1244 | coroutine.wrap(function() | |
| 1245 | if(Manual and typeof(Manual) == 'Instance' and Manual:IsA'BasePart')then | |
| 1246 | Prt = Manual | |
| 1247 | else | |
| 1248 | Prt = Part(Parent,Color,Material,Size,CFra,true,false) | |
| 1249 | Prt.Shape = Shape | |
| 1250 | end | |
| 1251 | if(typeof(MeshData) == 'table')then | |
| 1252 | Msh = Mesh(Prt,MeshData.MeshType,MeshData.MeshId,MeshData.TextureId,MeshData.Scale,MeshData.Offset) | |
| 1253 | elseif(typeof(MeshData) == 'Instance')then | |
| 1254 | Msh = MeshData:Clone() | |
| 1255 | Msh.Parent = Prt | |
| 1256 | elseif(Shape == Enum.PartType.Block)then | |
| 1257 | Msh = Mesh(Prt,Enum.MeshType.Brick) | |
| 1258 | end | |
| 1259 | if(typeof(SndData) == 'table')then | |
| 1260 | Snd = Sound(Prt,SndData.SoundId,SndData.Pitch,SndData.Volume,false,false,true) | |
| 1261 | elseif(typeof(SndData) == 'Instance')then | |
| 1262 | Snd = SndData | |
| 1263 | end | |
| 1264 | if(Snd)then | |
| 1265 | repeat swait() until Snd.Playing and Snd.IsLoaded and Snd.TimeLength > 0 | |
| 1266 | Frames = Snd.TimeLength * Frame_Speed/Snd.Pitch | |
| 1267 | end | |
| 1268 | Size = (Msh and Msh.Scale or Size) | |
| 1269 | local grow = Size-(Settings.EndSize or (Msh and Msh.Scale or Size)/2) | |
| 1270 | ||
| 1271 | local MoveSpeed = nil; | |
| 1272 | if(MoveDir)then | |
| 1273 | MoveSpeed = (CFra.p - MoveDir).magnitude/Frames | |
| 1274 | end | |
| 1275 | if(FX ~= 'Arc')then | |
| 1276 | for Frame = 1, Frames do | |
| 1277 | if(FX == "Fade")then | |
| 1278 | Prt.Transparency = (Frame/Frames) | |
| 1279 | elseif(FX == "Resize")then | |
| 1280 | if(not Settings.EndSize)then | |
| 1281 | Settings.EndSize = V3.N(0,0,0) | |
| 1282 | end | |
| 1283 | if(Settings.EndIsIncrement)then | |
| 1284 | if(Msh)then | |
| 1285 | Msh.Scale = Msh.Scale + Settings.EndSize | |
| 1286 | else | |
| 1287 | Prt.Size = Prt.Size + Settings.EndSize | |
| 1288 | end | |
| 1289 | else | |
| 1290 | if(Msh)then | |
| 1291 | Msh.Scale = Msh.Scale - grow/Frames | |
| 1292 | else | |
| 1293 | Prt.Size = Prt.Size - grow/Frames | |
| 1294 | end | |
| 1295 | end | |
| 1296 | elseif(FX == "ResizeAndFade")then | |
| 1297 | if(not Settings.EndSize)then | |
| 1298 | Settings.EndSize = V3.N(0,0,0) | |
| 1299 | end | |
| 1300 | if(Settings.EndIsIncrement)then | |
| 1301 | if(Msh)then | |
| 1302 | Msh.Scale = Msh.Scale + Settings.EndSize | |
| 1303 | else | |
| 1304 | Prt.Size = Prt.Size + Settings.EndSize | |
| 1305 | end | |
| 1306 | else | |
| 1307 | if(Msh)then | |
| 1308 | Msh.Scale = Msh.Scale - grow/Frames | |
| 1309 | else | |
| 1310 | Prt.Size = Prt.Size - grow/Frames | |
| 1311 | end | |
| 1312 | end | |
| 1313 | Prt.Transparency = (Frame/Frames) | |
| 1314 | end | |
| 1315 | if(Settings.RandomizeCFrame)then | |
| 1316 | Prt.CFrame = Prt.CFrame * CF.A(M.RRNG(-360,360),M.RRNG(-360,360),M.RRNG(-360,360)) | |
| 1317 | end | |
| 1318 | if(MoveDir and MoveSpeed)then | |
| 1319 | local Orientation = Prt.Orientation | |
| 1320 | Prt.CFrame = CF.N(Prt.Position,MoveDir)*CF.N(0,0,-MoveSpeed) | |
| 1321 | Prt.Orientation = Orientation | |
| 1322 | end | |
| 1323 | swait() | |
| 1324 | end | |
| 1325 | Prt:destroy() | |
| 1326 | else | |
| 1327 | local start,third,fourth,endP = Settings.Start,Settings.Third,Settings.Fourth,Settings.End | |
| 1328 | if(not Settings.End and Settings.Home)then endP = Settings.Home.CFrame end | |
| 1329 | if(start and endP)then | |
| 1330 | local quarter = third or start:lerp(endP, 0.25) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25)) | |
| 1331 | local threequarter = fourth or start:lerp(endP, 0.75) * CF.N(M.RNG(-25,25),M.RNG(0,25),M.RNG(-25,25)) | |
| 1332 | for Frame = 0, 1, (Settings.Speed or 0.01) do | |
| 1333 | if(Settings.Home)then | |
| 1334 | endP = Settings.Home.CFrame | |
| 1335 | end | |
| 1336 | Prt.CFrame = Bezier(start, quarter, threequarter, endP, Frame) | |
| 1337 | end | |
| 1338 | if(Settings.RemoveOnGoal)then | |
| 1339 | Prt:destroy() | |
| 1340 | end | |
| 1341 | else | |
| 1342 | Prt:destroy() | |
| 1343 | assert(start,"You need a start position!") | |
| 1344 | assert(endP,"You need a start position!") | |
| 1345 | end | |
| 1346 | end | |
| 1347 | end)() | |
| 1348 | return Prt,Msh,Snd | |
| 1349 | end | |
| 1350 | function SoulSteal(whom) | |
| 1351 | local torso = (whom:FindFirstChild'Head' or whom:FindFirstChild'Torso' or whom:FindFirstChild'UpperTorso' or whom:FindFirstChild'LowerTorso' or whom:FindFirstChild'HumanoidRootPart') | |
| 1352 | print(torso) | |
| 1353 | if(torso and torso:IsA'BasePart')then | |
| 1354 | local Model = Instance.new("Model",Effects)
| |
| 1355 | Model.Name = whom.Name.."'s Soul" | |
| 1356 | whom:BreakJoints() | |
| 1357 | local Soul = Part(Model,BrickColor.new'Really red','Glass',V3.N(.5,.5,.5),torso.CFrame,true,false) | |
| 1358 | Soul.Name = 'Head' | |
| 1359 | NewInstance("Humanoid",Model,{Health=0,MaxHealth=0})
| |
| 1360 | Effect{
| |
| 1361 | Effect="Arc", | |
| 1362 | Manual = Soul, | |
| 1363 | FXSettings={
| |
| 1364 | Start=torso.CFrame, | |
| 1365 | Home = Torso, | |
| 1366 | RemoveOnGoal = true, | |
| 1367 | } | |
| 1368 | } | |
| 1369 | local lastPoint = Soul.CFrame.p | |
| 1370 | ||
| 1371 | for i = 0, 1, 0.01 do | |
| 1372 | local point = CFrame.new(lastPoint, Soul.Position) * CFrame.Angles(-math.pi/2, 0, 0) | |
| 1373 | local mag = (lastPoint - Soul.Position).magnitude | |
| 1374 | Effect{
| |
| 1375 | Effect = "Fade", | |
| 1376 | CFrame = point * CF.N(0, mag/2, 0), | |
| 1377 | Size = V3.N(.5,mag+.5,.5), | |
| 1378 | Color = Soul.BrickColor | |
| 1379 | } | |
| 1380 | lastPoint = Soul.CFrame.p | |
| 1381 | swait() | |
| 1382 | end | |
| 1383 | for i = 1, 5 do | |
| 1384 | Effect{
| |
| 1385 | Effect="Fade", | |
| 1386 | Color = BrickColor.new'Really red', | |
| 1387 | MoveDirection = (Torso.CFrame*CFrame.new(M.RNG(-40,40),M.RNG(-40,40),M.RNG(-40,40))).p | |
| 1388 | } | |
| 1389 | end | |
| 1390 | end | |
| 1391 | end | |
| 1392 | ||
| 1393 | --// Other Functions \\ -- | |
| 1394 | ||
| 1395 | function CastRay(startPos,endPos,range,ignoreList) | |
| 1396 | local ray = Ray.new(startPos,(endPos-startPos).unit*range) | |
| 1397 | local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
| |
| 1398 | return part,pos,norm,(pos and (startPos-pos).magnitude) | |
| 1399 | end | |
| 1400 | ||
| 1401 | function CastRayInDirection(startPos,direction,range,ignoreList) | |
| 1402 | local ray = Ray.new(startPos,direction*range) | |
| 1403 | local part,pos,norm = workspace:FindPartOnRayWithIgnoreList(ray,ignoreList or {Char},false,true)
| |
| 1404 | return part,pos,norm,(pos and (startPos-pos).magnitude) | |
| 1405 | end | |
| 1406 | ||
| 1407 | function getRegion(point,range,ignore) | |
| 1408 | return workspace:FindPartsInRegion3WithIgnoreList(R3.N(point-V3.N(1,1,1)*range/2,point+V3.N(1,1,1)*range/2),ignore,100) | |
| 1409 | end | |
| 1410 | ||
| 1411 | function clerp(startCF,endCF,alpha) | |
| 1412 | return startCF:lerp(endCF, alpha) | |
| 1413 | end | |
| 1414 | ||
| 1415 | function GetTorso(char) | |
| 1416 | return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart' | |
| 1417 | end | |
| 1418 | ||
| 1419 | function ShowDamage(Pos, Text, Time, Color) | |
| 1420 | coroutine.wrap(function() | |
| 1421 | local Rate = (1 / Frame_Speed) | |
| 1422 | local Pos = (Pos or Vector3.new(0, 0, 0)) | |
| 1423 | local Text = (Text or "") | |
| 1424 | local Time = (Time or 2) | |
| 1425 | local Color = (Color or Color3.new(1, 0, 1)) | |
| 1426 | local EffectPart = NewInstance("Part",Effects,{
| |
| 1427 | Material=Enum.Material.SmoothPlastic, | |
| 1428 | Reflectance = 0, | |
| 1429 | Transparency = 1, | |
| 1430 | BrickColor = BrickColor.new(Color), | |
| 1431 | Name = "Effect", | |
| 1432 | Size = Vector3.new(0,0,0), | |
| 1433 | Anchored = true, | |
| 1434 | CFrame = CF.N(Pos) | |
| 1435 | }) | |
| 1436 | local BillboardGui = NewInstance("BillboardGui",EffectPart,{
| |
| 1437 | Size = UDim2.new(1.25, 0, 1.25, 0), | |
| 1438 | Adornee = EffectPart, | |
| 1439 | }) | |
| 1440 | local TextLabel = NewInstance("TextLabel",BillboardGui,{
| |
| 1441 | BackgroundTransparency = 1, | |
| 1442 | Size = UDim2.new(1, 0, 1, 0), | |
| 1443 | Text = Text, | |
| 1444 | Font = "Bodoni", | |
| 1445 | TextColor3 = Color, | |
| 1446 | TextStrokeColor3 = Color3.new(0,0,0), | |
| 1447 | TextStrokeTransparency=0, | |
| 1448 | TextScaled = true, | |
| 1449 | }) | |
| 1450 | S.Debris:AddItem(EffectPart, (Time)) | |
| 1451 | EffectPart.Parent = workspace | |
| 1452 | delay(0, function() | |
| 1453 | Tween(EffectPart,{CFrame=CF.N(Pos)*CF.N(0,3,0)},Time,Enum.EasingStyle.Elastic,Enum.EasingDirection.Out)
| |
| 1454 | local Frames = (Time / Rate) | |
| 1455 | for Frame = 1, Frames do | |
| 1456 | swait() | |
| 1457 | local Percent = (Frame / Frames) | |
| 1458 | TextLabel.TextTransparency = Percent | |
| 1459 | TextLabel.TextStrokeTransparency = Percent | |
| 1460 | end | |
| 1461 | if EffectPart and EffectPart.Parent then | |
| 1462 | EffectPart:Destroy() | |
| 1463 | end | |
| 1464 | end) end)() | |
| 1465 | end | |
| 1466 | ||
| 1467 | ||
| 1468 | function DealDamage(who,minDam,maxDam,Knock,Type,critChance,critMult) | |
| 1469 | if(who)then | |
| 1470 | local hum = who:FindFirstChildOfClass'Humanoid' | |
| 1471 | local Damage = M.RNG(minDam,maxDam) | |
| 1472 | local canHit = true | |
| 1473 | if(hum)then | |
| 1474 | for _, p in pairs(Hit) do | |
| 1475 | if p[1] == hum then | |
| 1476 | if(time() - p[2] < 0.01) then | |
| 1477 | canHit = false | |
| 1478 | else | |
| 1479 | Hit[_] = nil | |
| 1480 | end | |
| 1481 | end | |
| 1482 | end | |
| 1483 | if(canHit)then | |
| 1484 | table.insert(Hit,{hum,time()})
| |
| 1485 | if(hum.Health >= math.huge)then | |
| 1486 | who:BreakJoints() | |
| 1487 | if(who:FindFirstChild'Head' and hum.Health > 0)then | |
| 1488 | ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "INSTANT", 1.5, C3.N(1,0,0)) | |
| 1489 | end | |
| 1490 | else | |
| 1491 | local player = S.Players:GetPlayerFromCharacter(who) | |
| 1492 | if(Type == "Fire")then | |
| 1493 | --idk.. | |
| 1494 | else | |
| 1495 | local c = Instance.new("ObjectValue",hum)
| |
| 1496 | c.Name = "creator" | |
| 1497 | c.Value = Plr | |
| 1498 | game:service'Debris':AddItem(c,0.35) | |
| 1499 | if(M.RNG(1,100) <= (critChance or 0) and critMult > 1)then | |
| 1500 | if(who:FindFirstChild'Head' and hum.Health > 0)then | |
| 1501 | ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[CRIT] "..Damage*(critMult or 2), 1.5, BrickColor.new'New Yeller'.Color) | |
| 1502 | end | |
| 1503 | hum.Health = hum.Health - Damage*(critMult or 2) | |
| 1504 | else | |
| 1505 | if(who:FindFirstChild'Head' and hum.Health > 0)then | |
| 1506 | ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), Damage, 1.5, DamageColor.Color) | |
| 1507 | end | |
| 1508 | hum.Health = hum.Health - Damage | |
| 1509 | end | |
| 1510 | if(Type == 'Knockback' and GetTorso(who))then | |
| 1511 | local angle = GetTorso(who).Position - Root.Position + Vector3.new(0, 0, 0).unit | |
| 1512 | local body = NewInstance('BodyVelocity',GetTorso(who),{
| |
| 1513 | P = 500, | |
| 1514 | maxForce = V3.N(math.huge,0,math.huge), | |
| 1515 | velocity = Root.CFrame.lookVector * Knock + Root.Velocity / 1.05 | |
| 1516 | }) | |
| 1517 | game:service'Debris':AddItem(body,.5) | |
| 1518 | elseif(Type == "Electric")then | |
| 1519 | if(M.RNG(1,100) >= critChance)then | |
| 1520 | if(who:FindFirstChild'Head' and hum.Health > 0)then | |
| 1521 | ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[PARALYZED]", 1.5, BrickColor.new"New Yeller".Color) | |
| 1522 | end | |
| 1523 | local asd = hum.WalkSpeed/2 | |
| 1524 | hum.WalkSpeed = asd | |
| 1525 | local paralyzed = true | |
| 1526 | coroutine.wrap(function() | |
| 1527 | while paralyzed do | |
| 1528 | swait(25) | |
| 1529 | if(M.RNG(1,25) == 1)then | |
| 1530 | if(who:FindFirstChild'Head' and hum.Health > 0)then | |
| 1531 | ShowDamage((who.Head.CFrame * CF.N(0, 0, (who.Head.Size.Z / 2)).p+V3.N(0,1.5,0)+V3.N(M.RNG(-2,2),0,M.RNG(-2,2))), "[STATIC]", 1.5, BrickColor.new"New Yeller".Color) | |
| 1532 | end | |
| 1533 | hum.PlatformStand = true | |
| 1534 | end | |
| 1535 | end | |
| 1536 | end)() | |
| 1537 | delay(4, function() | |
| 1538 | paralyzed = false | |
| 1539 | hum.WalkSpeed = hum.WalkSpeed + asd | |
| 1540 | end) | |
| 1541 | end | |
| 1542 | ||
| 1543 | elseif(Type == 'Knockdown' and GetTorso(who))then | |
| 1544 | local rek = GetTorso(who) | |
| 1545 | hum.PlatformStand = true | |
| 1546 | delay(1,function() | |
| 1547 | hum.PlatformStand = false | |
| 1548 | end) | |
| 1549 | local angle = (GetTorso(who).Position - (Root.Position + Vector3.new(0, 0, 0))).unit | |
| 1550 | local bodvol = NewInstance("BodyVelocity",rek,{
| |
| 1551 | velocity = angle * Knock, | |
| 1552 | P = 5000, | |
| 1553 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
| 1554 | }) | |
| 1555 | local rl = NewInstance("BodyAngularVelocity",rek,{
| |
| 1556 | P = 3000, | |
| 1557 | maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000, | |
| 1558 | angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)), | |
| 1559 | }) | |
| 1560 | game:GetService("Debris"):AddItem(bodvol, .5)
| |
| 1561 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 1562 | end | |
| 1563 | end | |
| 1564 | end | |
| 1565 | end | |
| 1566 | end | |
| 1567 | end | |
| 1568 | end | |
| 1569 | ||
| 1570 | function AOEDamage(where,range,minDam,maxDam,Knock,Type,critChance,critMult) | |
| 1571 | for _,v in next, getRegion(where,range,{Char}) do
| |
| 1572 | if(v.Parent and v.Parent:FindFirstChildOfClass'Humanoid')then | |
| 1573 | coroutine.wrap(function() for i = 1, M.RNG(minDam,maxDam) do swait() DealDamage(v.Parent,1,1,Knock,Type,0,1) end end)() | |
| 1574 | end | |
| 1575 | end | |
| 1576 | end | |
| 1577 | ||
| 1578 | function AOEHeal(where,range,amount) | |
| 1579 | local healed = {}
| |
| 1580 | for _,v in next, getRegion(where,range,{Char}) do
| |
| 1581 | local hum = (v.Parent and v.Parent:FindFirstChildOfClass'Humanoid' or nil) | |
| 1582 | if(hum and not healed[hum])then | |
| 1583 | hum.Health = hum.Health + amount | |
| 1584 | if(v.Parent:FindFirstChild'Head' and hum.Health > 0)then | |
| 1585 | ShowDamage((v.Parent.Head.CFrame * CF.N(0, 0, (v.Parent.Head.Size.Z / 2)).p+V3.N(0,1.5,0)), "+"..amount, 1.5, BrickColor.new'Lime green'.Color) | |
| 1586 | end | |
| 1587 | end | |
| 1588 | end | |
| 1589 | end | |
| 1590 | ||
| 1591 | function CamShake(who,times,intense,origin) | |
| 1592 | coroutine.wrap(function() | |
| 1593 | if(script:FindFirstChild'CamShake')then | |
| 1594 | local cam = script.CamShake:Clone() | |
| 1595 | cam:WaitForChild'intensity'.Value = intense | |
| 1596 | cam:WaitForChild'times'.Value = times | |
| 1597 | ||
| 1598 | if(origin)then NewInstance((typeof(origin) == 'Instance' and "ObjectValue" or typeof(origin) == 'Vector3' and 'Vector3Value'),cam,{Name='origin',Value=origin}) end
| |
| 1599 | cam.Parent = who | |
| 1600 | wait() | |
| 1601 | cam.Disabled = false | |
| 1602 | elseif(who == Plr or who == Char)then | |
| 1603 | local intensity = intense | |
| 1604 | local cam = workspace.CurrentCamera | |
| 1605 | for i = 1, times do | |
| 1606 | local camDistFromOrigin | |
| 1607 | if(typeof(origin) == 'Instance' and origin:IsA'BasePart')then | |
| 1608 | camDistFromOrigin = math.floor( (cam.CFrame.p-origin.Position).magnitude )/25 | |
| 1609 | elseif(typeof(origin) == 'Vector3')then | |
| 1610 | camDistFromOrigin = math.floor( (cam.CFrame.p-origin).magnitude )/25 | |
| 1611 | end | |
| 1612 | if(camDistFromOrigin)then | |
| 1613 | intensity = math.min(intense, math.floor(intense/camDistFromOrigin)) | |
| 1614 | end | |
| 1615 | cam.CFrame = cam.CFrame:lerp(cam.CFrame*CFrame.new(math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100,math.random(-intensity,intensity)/100)*CFrame.Angles(math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100),math.rad(math.random(-intensity,intensity)/100)),.4) | |
| 1616 | swait() | |
| 1617 | end | |
| 1618 | end | |
| 1619 | end)() | |
| 1620 | end | |
| 1621 | ||
| 1622 | function CamShakeAll(times,intense,origin) | |
| 1623 | for _,v in next, Plrs:players() do | |
| 1624 | CamShake(v:FindFirstChildOfClass'PlayerGui' or v:FindFirstChildOfClass'Backpack' or v.Character,times,intense,origin) | |
| 1625 | end | |
| 1626 | end | |
| 1627 | ||
| 1628 | function ServerScript(code) | |
| 1629 | if(script:FindFirstChild'Loadstring')then | |
| 1630 | local load = script.Loadstring:Clone() | |
| 1631 | load:WaitForChild'Sauce'.Value = code | |
| 1632 | load.Disabled = false | |
| 1633 | load.Parent = workspace | |
| 1634 | elseif(NS and typeof(NS) == 'function')then | |
| 1635 | NS(code,workspace) | |
| 1636 | else | |
| 1637 | warn("no serverscripts lol")
| |
| 1638 | end | |
| 1639 | end | |
| 1640 | ||
| 1641 | function LocalOnPlayer(who,code) | |
| 1642 | ServerScript([[ | |
| 1643 | wait() | |
| 1644 | script.Parent=nil | |
| 1645 | if(not _G.Http)then _G.Http = game:service'HttpService' end | |
| 1646 | ||
| 1647 | local Http = _G.Http or game:service'HttpService' | |
| 1648 | ||
| 1649 | local source = ]].."[["..code.."]]"..[[ | |
| 1650 | local link = "https://api.vorth.xyz/R_API/R.UPLOAD/NEW_LOCAL.php" | |
| 1651 | local asd = Http:PostAsync(link,source) | |
| 1652 | repeat wait() until asd and Http:JSONDecode(asd) and Http:JSONDecode(asd).Result and Http:JSONDecode(asd).Result.Require_ID | |
| 1653 | local ID = Http:JSONDecode(asd).Result.Require_ID | |
| 1654 | local vs = require(ID).VORTH_SCRIPT | |
| 1655 | vs.Parent = game:service'Players'.]]..who.Name..[[.Character | |
| 1656 | ]]) | |
| 1657 | end | |
| 1658 | ||
| 1659 | ||
| 1660 | --// Attack Functions \\-- | |
| 1661 | function Laser(key) | |
| 1662 | NeutralAnims = false | |
| 1663 | Attack = true | |
| 1664 | Root.Anchored = true | |
| 1665 | local data = MagicCircle{Weld=Torso,Pos=CF.N(0,0,-4),Size=5,Variant=MagicVariant,Time=.5}
| |
| 1666 | local IsGrown = false | |
| 1667 | data.Grown:connect(function() IsGrown = true end) | |
| 1668 | repeat swait() | |
| 1669 | local Alpha = .1 | |
| 1670 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(125),0,0),Alpha) | |
| 1671 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(125),0,0),Alpha) | |
| 1672 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1673 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1674 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1675 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1676 | local LookVector = Mouse.Hit.p | |
| 1677 | Torso.CFrame = CF.N(Root.Position,LookVector) | |
| 1678 | until IsGrown | |
| 1679 | if(S.UserInputService:IsKeyDown(key))then | |
| 1680 | local grown = 0 | |
| 1681 | repeat | |
| 1682 | local Alpha = .1 | |
| 1683 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(125),0,0),Alpha) | |
| 1684 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(125),0,0),Alpha) | |
| 1685 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1686 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1687 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1688 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1689 | local LookVector = Mouse.Hit.p | |
| 1690 | Root.CFrame = CF.N(Root.Position,LookVector) | |
| 1691 | if(grown < 250)then | |
| 1692 | data.Grow(.05) | |
| 1693 | grown = grown + 1 | |
| 1694 | end | |
| 1695 | swait() | |
| 1696 | until not S.UserInputService:IsKeyDown(key) | |
| 1697 | end | |
| 1698 | Sound(data.Circle,340722848,1,1,false,true,true) | |
| 1699 | local hit,pos,norm,dist = CastRay(data.Circle.CFrame.p,Mouse.Hit.p,1024) | |
| 1700 | local part = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data.Mesh.Scale.x/40,data.Mesh.Scale.x/40),CF.N(data.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false) | |
| 1701 | Mesh(part,Enum.MeshType.Cylinder) | |
| 1702 | Tween(part,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
| |
| 1703 | Effect{
| |
| 1704 | Effect='ResizeAndFade', | |
| 1705 | Color=MagicVariant.Color, | |
| 1706 | Size=V3.N(data.Mesh.Scale.X/20,data.Mesh.Scale.X/20,data.Mesh.Scale.X/20), | |
| 1707 | Mesh={MeshType=Enum.MeshType.Sphere},
| |
| 1708 | CFrame=CF.N(pos), | |
| 1709 | FXSettings={
| |
| 1710 | EndSize=V3.N(.05,.05,.05), | |
| 1711 | EndIsIncrement=true | |
| 1712 | } | |
| 1713 | } | |
| 1714 | for i = 1, 5 do | |
| 1715 | local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)) | |
| 1716 | Effect{
| |
| 1717 | Effect='Fade', | |
| 1718 | Frames=65, | |
| 1719 | Size=V3.N((data.Mesh.Scale.X/20)/2,(data.Mesh.Scale.X/20)/2,data.Mesh.Scale.X/20), | |
| 1720 | CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data.Mesh.Scale.X/20)).p,pos), | |
| 1721 | Mesh = {MeshType=Enum.MeshType.Sphere},
| |
| 1722 | Material=Enum.Material.Neon, | |
| 1723 | Color=MagicVariant.Color, | |
| 1724 | MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p, | |
| 1725 | } | |
| 1726 | end | |
| 1727 | AOEDamage(pos,data.Mesh.Scale.X/20,15,45,0,'Normal',10,4) | |
| 1728 | coroutine.wrap(function() | |
| 1729 | local frame = (1/30) | |
| 1730 | for i = 1, 30 do | |
| 1731 | part.Transparency = (i/30) | |
| 1732 | swait() | |
| 1733 | end | |
| 1734 | part:destroy() | |
| 1735 | end)() | |
| 1736 | Attack = false | |
| 1737 | NeutralAnims = true | |
| 1738 | Root.Anchored = false | |
| 1739 | data.Destroy() | |
| 1740 | end | |
| 1741 | ||
| 1742 | function Balls(key) | |
| 1743 | NeutralAnims = false | |
| 1744 | Attack = true | |
| 1745 | Root.Anchored = true | |
| 1746 | local data = MagicCircle{Weld=Torso,Pos=CF.N(0,2,-1),Size=5,Variant=MagicVariant,Time=.5}
| |
| 1747 | local IsGrown = false | |
| 1748 | data.Grown:connect(function() IsGrown = true end) | |
| 1749 | repeat swait() | |
| 1750 | local Alpha = .1 | |
| 1751 | local idk = M.R(25) | |
| 1752 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1753 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1754 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1755 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1756 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1757 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1758 | local LookVector = Mouse.Hit.p | |
| 1759 | Torso.CFrame = CF.N(Root.Position,LookVector) | |
| 1760 | until IsGrown | |
| 1761 | local projectiles = 5 | |
| 1762 | if(S.UserInputService:IsKeyDown(key))then | |
| 1763 | local grown = 0 | |
| 1764 | repeat | |
| 1765 | local Alpha = .1 | |
| 1766 | local idk = M.R(25) | |
| 1767 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1768 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1769 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1770 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1771 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1772 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1773 | local LookVector = Mouse.Hit.p | |
| 1774 | Root.CFrame = CF.N(Root.Position,LookVector) | |
| 1775 | if(grown < 250)then | |
| 1776 | data.Grow(.05) | |
| 1777 | grown = grown + 1 | |
| 1778 | projectiles = projectiles + .05 | |
| 1779 | end | |
| 1780 | swait() | |
| 1781 | until not S.UserInputService:IsKeyDown(key) | |
| 1782 | end | |
| 1783 | for i = 1, math.floor(projectiles) do | |
| 1784 | data.Grow(-math.floor(projectiles)/20) | |
| 1785 | local LookVector = Mouse.Hit.p | |
| 1786 | Root.CFrame = CF.N(Root.Position,LookVector) | |
| 1787 | ShootBullet{Shape='Ball',Frames=160,Origin=data.Circle.CFrame,Speed=10}
| |
| 1788 | swait(1) | |
| 1789 | end | |
| 1790 | ||
| 1791 | Attack = false | |
| 1792 | NeutralAnims = true | |
| 1793 | Root.Anchored = false | |
| 1794 | data.Destroy() | |
| 1795 | end | |
| 1796 | ||
| 1797 | function DLaser(key) | |
| 1798 | NeutralAnims = false | |
| 1799 | Attack = true | |
| 1800 | Root.Anchored = true | |
| 1801 | local data1 = MagicCircle{Weld=Torso,Pos=CF.N(-5,5,2),Size=5,Variant=MagicVariant,Time=.5}
| |
| 1802 | local data2 = MagicCircle{Weld=Torso,Pos=CF.N(5,5,2),Size=5,Variant=MagicVariant,Time=.5}
| |
| 1803 | local IsGrown = false | |
| 1804 | data1.Grown:connect(function() IsGrown = true end) | |
| 1805 | repeat swait() | |
| 1806 | local Alpha = .1 | |
| 1807 | local idk = M.R(25) | |
| 1808 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1809 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1810 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1811 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1812 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1813 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1814 | local LookVector = Mouse.Hit.p | |
| 1815 | Torso.CFrame = CF.N(Root.Position,LookVector) | |
| 1816 | until IsGrown | |
| 1817 | if(S.UserInputService:IsKeyDown(key))then | |
| 1818 | local grown = 0 | |
| 1819 | repeat | |
| 1820 | local Alpha = .1 | |
| 1821 | local idk = M.R(25) | |
| 1822 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1823 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1824 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1825 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1826 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1827 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1828 | local LookVector = Mouse.Hit.p | |
| 1829 | Root.CFrame = CF.N(Root.Position,LookVector) | |
| 1830 | if(grown < 250)then | |
| 1831 | data1.Grow(.05) | |
| 1832 | data2.Grow(.05) | |
| 1833 | grown = grown + 1 | |
| 1834 | end | |
| 1835 | swait() | |
| 1836 | until not S.UserInputService:IsKeyDown(key) | |
| 1837 | end | |
| 1838 | Sound(data1.Circle,340722848,1,1,false,true,true) | |
| 1839 | Sound(data2.Circle,340722848,1,1,false,true,true) | |
| 1840 | local hit,pos,norm,dist = CastRay(data1.Circle.CFrame.p,Mouse.Hit.p,1024) | |
| 1841 | local part1 = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data1.Mesh.Scale.x/40,data1.Mesh.Scale.x/40),CF.N(data1.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false) | |
| 1842 | Mesh(part1,Enum.MeshType.Cylinder) | |
| 1843 | ||
| 1844 | ||
| 1845 | local part2 = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data2.Mesh.Scale.x/40,data2.Mesh.Scale.x/40),CF.N(data2.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false) | |
| 1846 | Mesh(part2,Enum.MeshType.Cylinder) | |
| 1847 | Tween(part1,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
| |
| 1848 | Tween(part2,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
| |
| 1849 | Effect{
| |
| 1850 | Effect='ResizeAndFade', | |
| 1851 | Color=MagicVariant.Color, | |
| 1852 | Size=V3.N(data1.Mesh.Scale.X/20,data1.Mesh.Scale.X/20,data1.Mesh.Scale.X/20), | |
| 1853 | Mesh={MeshType=Enum.MeshType.Sphere},
| |
| 1854 | CFrame=CF.N(pos), | |
| 1855 | FXSettings={
| |
| 1856 | EndSize=V3.N(.05,.05,.05), | |
| 1857 | EndIsIncrement=true | |
| 1858 | } | |
| 1859 | } | |
| 1860 | for i = 1, 5 do | |
| 1861 | local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)) | |
| 1862 | Effect{
| |
| 1863 | Effect='Fade', | |
| 1864 | Frames=65, | |
| 1865 | Size=V3.N((data1.Mesh.Scale.X/20)/2,(data1.Mesh.Scale.X/20)/2,data1.Mesh.Scale.X/20), | |
| 1866 | CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data1.Mesh.Scale.X/20)).p,pos), | |
| 1867 | Mesh = {MeshType=Enum.MeshType.Sphere},
| |
| 1868 | Material=Enum.Material.Neon, | |
| 1869 | Color=MagicVariant.Color, | |
| 1870 | MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p, | |
| 1871 | } | |
| 1872 | end | |
| 1873 | AOEDamage(pos,data1.Mesh.Scale.X/20,15,45,0,'Normal',10,4) | |
| 1874 | AOEDamage(pos,data2.Mesh.Scale.X/20,15,45,0,'Normal',10,4) | |
| 1875 | coroutine.wrap(function() | |
| 1876 | local frame = (1/30) | |
| 1877 | for i = 1, 30 do | |
| 1878 | part1.Transparency = (i/30) | |
| 1879 | part2.Transparency = (i/30) | |
| 1880 | swait() | |
| 1881 | end | |
| 1882 | part1:destroy() | |
| 1883 | part2:destroy() | |
| 1884 | end)() | |
| 1885 | Attack = false | |
| 1886 | NeutralAnims = true | |
| 1887 | Root.Anchored = false | |
| 1888 | data1.Destroy() | |
| 1889 | data2.Destroy() | |
| 1890 | end | |
| 1891 | ||
| 1892 | ||
| 1893 | function BLaser(key) | |
| 1894 | NeutralAnims = false | |
| 1895 | Attack = true | |
| 1896 | Root.Anchored = true | |
| 1897 | local data = MagicCircle{Weld=Torso,Pos=CF.N(0,10,10),Size=15,Variant=MagicVariant,Time=.75}
| |
| 1898 | local IsGrown = false | |
| 1899 | data.Grown:connect(function() IsGrown = true end) | |
| 1900 | repeat swait() | |
| 1901 | local Alpha = .1 | |
| 1902 | local idk = M.R(25) | |
| 1903 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1904 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1905 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1906 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1907 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1908 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1909 | local LookVector = Mouse.Hit.p | |
| 1910 | Torso.CFrame = CF.N(Root.Position,LookVector) | |
| 1911 | until IsGrown | |
| 1912 | if(S.UserInputService:IsKeyDown(key))then | |
| 1913 | local grown = 0 | |
| 1914 | repeat | |
| 1915 | local Alpha = .1 | |
| 1916 | local idk = M.R(25) | |
| 1917 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 1918 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 1919 | RJ.C0 = RJ.C0:lerp(RJC0,Alpha) | |
| 1920 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 1921 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 1922 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 1923 | local LookVector = Mouse.Hit.p | |
| 1924 | Root.CFrame = CF.N(Root.Position,LookVector) | |
| 1925 | swait() | |
| 1926 | until not S.UserInputService:IsKeyDown(key) | |
| 1927 | end | |
| 1928 | ||
| 1929 | local hit,pos,norm,dist = CastRay(data.Circle.CFrame.p,Mouse.Hit.p,1024) | |
| 1930 | local part = Part(Effects,MagicVariant.EffectColor or MagicVariant.Color,Enum.Material.Neon,V3.N(dist,data.Mesh.Scale.x/40,data.Mesh.Scale.x/40),CF.N(data.Circle.CFrame.p,pos)*CF.N(0,0,-dist/2)*CF.A(0,M.P/2,0),true,false) | |
| 1931 | Mesh(part,Enum.MeshType.Cylinder) | |
| 1932 | Tween(part,{Color=C3.N(1,1,1)},1,Enum.EasingStyle.Quad,Enum.EasingDirection.Out,0,false)
| |
| 1933 | local aa = data.Circle:Clone(); | |
| 1934 | aa.Parent = Effects | |
| 1935 | aa.Anchored = true | |
| 1936 | local blast = Sound(aa,334702766,1,5,false,true,true) | |
| 1937 | data.Circle:destroy() | |
| 1938 | if(not blast.IsLoaded)then repeat swait() until blast.IsLoaded end | |
| 1939 | Effect{
| |
| 1940 | Effect='ResizeAndFade', | |
| 1941 | Color=MagicVariant.Color, | |
| 1942 | Size=V3.N(data.Mesh.Scale.X/20,data.Mesh.Scale.X/20,data.Mesh.Scale.X/20), | |
| 1943 | Mesh={MeshType=Enum.MeshType.Sphere},
| |
| 1944 | CFrame=CF.N(pos), | |
| 1945 | Sound=blast, | |
| 1946 | FXSettings={
| |
| 1947 | EndSize=V3.N(.05,.05,.05), | |
| 1948 | EndIsIncrement=true | |
| 1949 | } | |
| 1950 | } | |
| 1951 | for i = 1, 5 do | |
| 1952 | local angles = CF.A(M.RRNG(-180,180),M.RRNG(-180,180),M.RRNG(-180,180)) | |
| 1953 | Effect{
| |
| 1954 | Effect='Fade', | |
| 1955 | Frames=65, | |
| 1956 | Sound=blast, | |
| 1957 | Size=V3.N((data.Mesh.Scale.X/20)/2,(data.Mesh.Scale.X/20)/2,data.Mesh.Scale.X/20), | |
| 1958 | CFrame=CF.N(CF.N(pos)*angles*CF.N(0,0,-(data.Mesh.Scale.X/20)).p,pos), | |
| 1959 | Mesh = {MeshType=Enum.MeshType.Sphere},
| |
| 1960 | Material=Enum.Material.Neon, | |
| 1961 | Color=MagicVariant.Color, | |
| 1962 | MoveDirection=CF.N(CF.N(pos)*angles*CF.N(0,0,-50).p,pos).p, | |
| 1963 | } | |
| 1964 | end | |
| 1965 | AOEDamage(pos,data.Mesh.Scale.X/20,45,75,0,'Normal',10,4) | |
| 1966 | coroutine.wrap(function() | |
| 1967 | for i = 1, (blast.TimeLength*Frame_Speed) do | |
| 1968 | part.Transparency = (i/(blast.TimeLength*Frame_Speed)) | |
| 1969 | for _,v in next, aa:children() do if v:IsA'Decal' then v.Transparency = (i/(blast.TimeLength*Frame_Speed)) end end | |
| 1970 | swait() | |
| 1971 | end | |
| 1972 | aa:destroy() | |
| 1973 | part:destroy() | |
| 1974 | end)() | |
| 1975 | ||
| 1976 | Attack = false | |
| 1977 | NeutralAnims = true | |
| 1978 | Root.Anchored = false | |
| 1979 | Root.Velocity = Mouse.Hit.lookVector*-125 | |
| 1980 | end | |
| 1981 | ||
| 1982 | function Skill1() | |
| 1983 | Laser(Enum.KeyCode.Q) | |
| 1984 | end | |
| 1985 | ||
| 1986 | function Skill2() | |
| 1987 | DLaser(Enum.KeyCode.Z) | |
| 1988 | end | |
| 1989 | ||
| 1990 | function Skill3() | |
| 1991 | BLaser(Enum.KeyCode.X) | |
| 1992 | end | |
| 1993 | ||
| 1994 | --// Wrap it all up \\-- | |
| 1995 | ||
| 1996 | Mouse.KeyDown:connect(function(k) | |
| 1997 | if(Attack)then return end | |
| 1998 | if(k == 'q')then Skill1() end | |
| 1999 | if(k == 'e')then Skill2() end | |
| 2000 | if(k == 'r')then Skill3() end | |
| 2001 | end) | |
| 2002 | ||
| 2003 | Plr.Chatted:connect(function(m) | |
| 2004 | ||
| 2005 | if(m:sub(1,3) == '/e ')then | |
| 2006 | local msg = m:sub(4) | |
| 2007 | --emote commands (gotta do) | |
| 2008 | end | |
| 2009 | end) | |
| 2010 | while true do | |
| 2011 | swait() | |
| 2012 | Sine = Sine + Change | |
| 2013 | ||
| 2014 | local hitfloor,posfloor = workspace:FindPartOnRay(Ray.new(Root.CFrame.p,((CFrame.new(Root.Position,Root.Position - Vector3.new(0,1,0))).lookVector).unit * (4)), Char) | |
| 2015 | ||
| 2016 | local Walking = (math.abs(Root.Velocity.x) > 1 or math.abs(Root.Velocity.z) > 1) | |
| 2017 | local State = (Hum.PlatformStand and 'Paralyzed' or Hum.Sit and 'Sit' or not hitfloor and Root.Velocity.y < -1 and "Fall" or not hitfloor and Root.Velocity.y > 1 and "Jump" or hitfloor and Walking and (Hum.WalkSpeed > 24 and "Run" or "Walk") or hitfloor and "Idle") | |
| 2018 | if(not Effects or not Effects.Parent)then | |
| 2019 | Effects = IN("Model",Char)
| |
| 2020 | Effects.Name = "Effects" | |
| 2021 | end | |
| 2022 | if(State == 'Run')then | |
| 2023 | local wsVal = 20 / (Hum.WalkSpeed/16) | |
| 2024 | local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1) | |
| 2025 | Change = 3 | |
| 2026 | RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.2*M.C(Sine/wsVal),0+.4*M.C(Sine/wsVal))*CF.A(M.R(15+25*M.C(Sine/wsVal))+-M.S(Sine/wsVal),0,0),Alpha) | |
| 2027 | LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.2*M.C(Sine/wsVal),0-.4*M.C(Sine/wsVal))*CF.A(M.R(15-25*M.C(Sine/wsVal))+M.S(Sine/wsVal),0,0),Alpha) | |
| 2028 | elseif(State == 'Walk')then | |
| 2029 | local wsVal = 20 / (Hum.WalkSpeed/16) | |
| 2030 | local Alpha = math.min(.3 * (Hum.WalkSpeed/8),1) | |
| 2031 | Change = 3 | |
| 2032 | RH.C1 = RH.C1:lerp(CF.N(0,1,0)*CF.N(0,0-.5*M.C(Sine/wsVal)/2,0+.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15-2*M.C(Sine/wsVal))+-M.S(Sine/wsVal)/2.5,0,0),Alpha) | |
| 2033 | LH.C1 = LH.C1:lerp(CF.N(0,1,0)*CF.N(0,0+.5*M.C(Sine/wsVal)/2,0-.6*M.C(Sine/wsVal)/2)*CF.A(M.R(15+2*M.C(Sine/wsVal))+M.S(Sine/wsVal)/2.5,0,0),Alpha) | |
| 2034 | else | |
| 2035 | RH.C1 = RH.C1:lerp(CF.N(0,1,0),.2) | |
| 2036 | LH.C1 = LH.C1:lerp(CF.N(0,1,0),.2) | |
| 2037 | end | |
| 2038 | ||
| 2039 | Hum.WalkSpeed = WalkSpeed | |
| 2040 | ||
| 2041 | if(NeutralAnims)then | |
| 2042 | if(State == 'Idle')then | |
| 2043 | local Alpha = .1 | |
| 2044 | Change = .75 | |
| 2045 | RJ.C0 = RJ.C0:lerp(RJC0*CF.N(0+.2*M.C(Sine/12),.2*M.C(Sine/6),0)*CF.A(M.R(-5+5*M.C(Sine/12)),0,0),Alpha) | |
| 2046 | NK.C0 = NK.C0:lerp(NKC0*CF.A(M.R(-5+5*M.C(Sine/12)),0,0),Alpha) | |
| 2047 | LS.C0 = LS.C0:lerp(LSC0*CF.N(.25,0,0)*CF.A(M.R(-45),0,M.R(45+5*M.C(Sine/12))),Alpha) | |
| 2048 | RS.C0 = RS.C0:lerp(RSC0*CF.N(-.25,0,0)*CF.A(M.R(-45),0,M.R(-45-5*M.C(Sine/12))),Alpha) | |
| 2049 | LH.C0 = LH.C0:lerp(LHC0*CF.N(0-.2*M.C(Sine/12),-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(10),0),Alpha) | |
| 2050 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0-.2*M.C(Sine/12),-.2*M.C(Sine/6),0)*CF.A(M.R(5-5*M.C(Sine/12)),M.R(-10),0),Alpha) | |
| 2051 | -- idle | |
| 2052 | elseif(State == 'Run')then | |
| 2053 | local wsVal = 20 / (Hum.WalkSpeed/16) | |
| 2054 | local Alpha = math.min(.2 * (Hum.WalkSpeed/16),1) | |
| 2055 | RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-15+2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha) | |
| 2056 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 2057 | LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,0-.3*M.S(Sine/wsVal))*CF.A(M.R(0+45*M.S(Sine/wsVal)),0,M.R(-5)),Alpha) | |
| 2058 | RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,0+.3*M.S(Sine/wsVal))*CF.A(M.R(0-45*M.S(Sine/wsVal)),0,M.R(5)),Alpha) | |
| 2059 | LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha) | |
| 2060 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha) | |
| 2061 | elseif(State == 'Walk')then | |
| 2062 | local wsVal = 20 / (Hum.WalkSpeed/16) | |
| 2063 | local Alpha = math.min(.3 * (Hum.WalkSpeed/16),1) | |
| 2064 | RJ.C0 = RJ.C0:lerp(CF.N(0,0-.1*M.C(Sine/(wsVal/2)),0)*CF.A(M.R(-5-2.5*M.C(Sine/(wsVal/2))),M.R(8*M.C(Sine/wsVal)),0),Alpha) | |
| 2065 | NK.C0 = NK.C0:lerp(NKC0,Alpha) | |
| 2066 | LS.C0 = LS.C0:lerp(LSC0*CF.N(0,0,-.22*M.C(Sine/wsVal))*CF.A(M.R(37*M.C(Sine/wsVal)),0,M.R(-5)),Alpha) | |
| 2067 | RS.C0 = RS.C0:lerp(RSC0*CF.N(0,0,.22*M.C(Sine/wsVal))*CF.A(M.R(-37*M.C(Sine/wsVal)),0,M.R(5)),Alpha) | |
| 2068 | LH.C0 = LH.C0:lerp(LHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha) | |
| 2069 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,0+.1*M.C(Sine/(wsVal/2)),0)*CF.A(0,-M.R(4*M.C(Sine/wsVal)),0),Alpha) | |
| 2070 | elseif(State == 'Jump')then | |
| 2071 | local Alpha = .1 | |
| 2072 | local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90)) | |
| 2073 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)),Alpha) | |
| 2074 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)),Alpha) | |
| 2075 | RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha) | |
| 2076 | NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha) | |
| 2077 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 2078 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 2079 | elseif(State == 'Fall')then | |
| 2080 | local Alpha = .1 | |
| 2081 | local idk = math.min(math.max(Root.Velocity.Y/50,-M.R(90)),M.R(90)) | |
| 2082 | LS.C0 = LS.C0:lerp(LSC0*CF.A(M.R(-5),0,M.R(-90)+idk),Alpha) | |
| 2083 | RS.C0 = RS.C0:lerp(RSC0*CF.A(M.R(-5),0,M.R(90)-idk),Alpha) | |
| 2084 | RJ.C0 = RJ.C0:lerp(RJC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha) | |
| 2085 | NK.C0 = NK.C0:lerp(NKC0*CF.A(math.min(math.max(Root.Velocity.Y/100,-M.R(45)),M.R(45)),0,0),Alpha) | |
| 2086 | LH.C0 = LH.C0:lerp(LHC0*CF.A(0,0,M.R(-5)),Alpha) | |
| 2087 | RH.C0 = RH.C0:lerp(RHC0*CF.N(0,1,-1)*CF.A(M.R(-5),0,M.R(5)),Alpha) | |
| 2088 | elseif(State == 'Paralyzed')then | |
| 2089 | -- paralyzed | |
| 2090 | elseif(State == 'Sit')then | |
| 2091 | -- sit | |
| 2092 | end | |
| 2093 | end | |
| 2094 | ||
| 2095 | end |