SHOW:
|
|
- or go back to the newest paste.
| 1 | -- This script has been converted to FE by iPxter | |
| 2 | ||
| 3 | ||
| 4 | - | local Player = game.Players.localPlayer |
| 4 | + | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
|
| 5 | local Player,Mouse,mouse,UserInputService,ContextActionService = owner | |
| 6 | do | |
| 7 | - | local mouse = Player:GetMouse() |
| 7 | + | print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
|
| 8 | script.Parent = Player.Character | |
| 9 | ||
| 10 | --RemoteEvent for communicating | |
| 11 | local Event = Instance.new("RemoteEvent")
| |
| 12 | Event.Name = "UserInput_Event" | |
| 13 | ||
| 14 | --Fake event to make stuff like Mouse.KeyDown work | |
| 15 | local function fakeEvent() | |
| 16 | local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
| |
| 17 | t.connect = t.Connect | |
| 18 | return t | |
| 19 | end | |
| 20 | ||
| 21 | --Creating fake input objects with fake variables | |
| 22 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
| |
| 23 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
| |
| 24 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
| |
| 25 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
| |
| 26 | end} | |
| 27 | --Merged 2 functions into one by checking amount of arguments | |
| 28 | CAS.UnbindAction = CAS.BindAction | |
| 29 | ||
| 30 | --This function will trigger the events that have been :Connect()'ed | |
| 31 | local function te(self,ev,...) | |
| 32 | local t = m[ev] | |
| 33 | if t and t._fakeEvent and t.Function then | |
| 34 | t.Function(...) | |
| 35 | end | |
| 36 | end | |
| 37 | m.TrigEvent = te | |
| 38 | UIS.TrigEvent = te | |
| 39 | ||
| 40 | Event.OnServerEvent:Connect(function(plr,io) | |
| 41 | if plr~=Player then return end | |
| 42 | if io.isMouse then | |
| 43 | m.Target = io.Target | |
| 44 | m.Hit = io.Hit | |
| 45 | else | |
| 46 | local b = io.UserInputState == Enum.UserInputState.Begin | |
| 47 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
| 48 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
| 49 | end | |
| 50 | for _,t in pairs(CAS.Actions) do | |
| 51 | for _,k in pairs(t.Keys) do | |
| 52 | if k==io.KeyCode then | |
| 53 | t.Function(t.Name,io.UserInputState,io) | |
| 54 | end | |
| 55 | end | |
| 56 | end | |
| 57 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
| 58 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
| 59 | end | |
| 60 | end) | |
| 61 | Event.Parent = NLS([==[ | |
| 62 | local Player = game:GetService("Players").LocalPlayer
| |
| 63 | local Event = script:WaitForChild("UserInput_Event")
| |
| 64 | ||
| 65 | local UIS = game:GetService("UserInputService")
| |
| 66 | local input = function(io,a) | |
| 67 | if a then return end | |
| 68 | --Since InputObject is a client-side instance, we create and pass table instead | |
| 69 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
| |
| 70 | end | |
| 71 | UIS.InputBegan:Connect(input) | |
| 72 | UIS.InputEnded:Connect(input) | |
| 73 | ||
| 74 | local Mouse = Player:GetMouse() | |
| 75 | local h,t | |
| 76 | --Give the server mouse data 30 times every second, but only if the values changed | |
| 77 | --If player is not moving their mouse, client won't fire events | |
| 78 | while wait(1/30) do | |
| 79 | if h~=Mouse.Hit or t~=Mouse.Target then | |
| 80 | h,t=Mouse.Hit,Mouse.Target | |
| 81 | Event:FireServer({isMouse=true,Target=t,Hit=h})
| |
| 82 | end | |
| 83 | end]==],Player.Character) | |
| 84 | Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS | |
| 85 | end | |
| 86 | --GK Gun but Non-Intro Version by Bacon Hair! | |
| 87 | ||
| 88 | wait(0.2) | |
| 89 | ||
| 90 | Player = owner | |
| 91 | PlayerGui = Player.PlayerGui | |
| 92 | Cam = workspace.CurrentCamera | |
| 93 | Backpack = Player.Backpack | |
| 94 | Character = Player.Character | |
| 95 | Humanoid = Character.Humanoid | |
| 96 | RootPart = Character.HumanoidRootPart | |
| 97 | Torso = Character.Torso | |
| 98 | Head = Character.Head | |
| 99 | RightArm = Character["Right Arm"] | |
| 100 | LeftArm = Character["Left Arm"] | |
| 101 | RightLeg = Character["Right Leg"] | |
| 102 | LeftLeg = Character["Left Leg"] | |
| 103 | RootJoint = RootPart.RootJoint | |
| 104 | Neck = Torso.Neck | |
| 105 | RightShoulder = Torso["Right Shoulder"] | |
| 106 | LeftShoulder = Torso["Left Shoulder"] | |
| 107 | RightHip = Torso["Right Hip"] | |
| 108 | LeftHip = Torso["Left Hip"] | |
| 109 | local sick = Instance.new("Sound",Character)
| |
| 110 | sick.SoundId = "rbxassetid://589853222" | |
| 111 | sick.Parent = Character | |
| 112 | sick.Looped = true | |
| 113 | sick.Pitch = 1 | |
| 114 | sick.Volume = 4 | |
| 115 | sick:Play() | |
| 116 | local LastBolt | |
| 117 | local LightningBolts = {}
| |
| 118 | local GunPoint | |
| 119 | IT = Instance.new | |
| 120 | CF = CFrame.new | |
| 121 | VT = Vector3.new | |
| 122 | RAD = math.rad | |
| 123 | C3 = Color3.new | |
| 124 | UD2 = UDim2.new | |
| 125 | BRICKC = BrickColor.new | |
| 126 | ANGLES = CFrame.Angles | |
| 127 | EULER = CFrame.fromEulerAnglesXYZ | |
| 128 | COS = math.cos | |
| 129 | ACOS = math.acos | |
| 130 | SIN = math.sin | |
| 131 | ASIN = math.asin | |
| 132 | ABS = math.abs | |
| 133 | MRANDOM = math.random | |
| 134 | FLOOR = math.floor | |
| 135 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
| 136 | local NEWMESH = IT(MESH) | |
| 137 | if MESH == "SpecialMesh" then | |
| 138 | NEWMESH.MeshType = MESHTYPE | |
| 139 | if MESHID ~= "nil" and MESHID ~= "" then | |
| 140 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id=" .. MESHID | |
| 141 | end | |
| 142 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
| 143 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id=" .. TEXTUREID | |
| 144 | end | |
| 145 | end | |
| 146 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
| 147 | NEWMESH.Scale = SCALE | |
| 148 | NEWMESH.Parent = PARENT | |
| 149 | return NEWMESH | |
| 150 | end | |
| 151 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
| 152 | local NEWPART = IT("Part")
| |
| 153 | NEWPART.formFactor = FORMFACTOR | |
| 154 | NEWPART.Reflectance = REFLECTANCE | |
| 155 | NEWPART.Transparency = TRANSPARENCY | |
| 156 | NEWPART.CanCollide = false | |
| 157 | NEWPART.Locked = true | |
| 158 | NEWPART.Anchored = true | |
| 159 | if ANCHOR == false then | |
| 160 | NEWPART.Anchored = false | |
| 161 | end | |
| 162 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
| 163 | NEWPART.Name = NAME | |
| 164 | NEWPART.Size = SIZE | |
| 165 | NEWPART.Position = Torso.Position | |
| 166 | NEWPART.Material = MATERIAL | |
| 167 | NEWPART:BreakJoints() | |
| 168 | NEWPART.Parent = PARENT | |
| 169 | return NEWPART | |
| 170 | end | |
| 171 | Player_Size = 1 | |
| 172 | Animation_Speed = 3 | |
| 173 | Frame_Speed = 0.016666666666666666 | |
| 174 | local Speed = 16 | |
| 175 | local Effects2 = {}
| |
| 176 | local weldBetween = function(a, b) | |
| 177 | local weldd = Instance.new("ManualWeld")
| |
| 178 | weldd.Part0 = a | |
| 179 | weldd.Part1 = b | |
| 180 | weldd.C0 = CFrame.new() | |
| 181 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
| 182 | weldd.Parent = a | |
| 183 | return weldd | |
| 184 | end | |
| 185 | function createaccessory(attachmentpart, mesh, texture, scale, offset, color) | |
| 186 | local acs = Instance.new("Part")
| |
| 187 | acs.CanCollide = false | |
| 188 | acs.Anchored = false | |
| 189 | acs.Size = Vector3.new(0, 0, 0) | |
| 190 | acs.CFrame = attachmentpart.CFrame | |
| 191 | acs.Parent = Character | |
| 192 | acs.BrickColor = color | |
| 193 | local meshs = Instance.new("SpecialMesh")
| |
| 194 | meshs.MeshId = mesh | |
| 195 | meshs.TextureId = texture | |
| 196 | meshs.Parent = acs | |
| 197 | meshs.Scale = scale | |
| 198 | meshs.Offset = offset | |
| 199 | weldBetween(attachmentpart, acs) | |
| 200 | end | |
| 201 | function createbodypart(TYPE, COLOR, PART, OFFSET, SIZE) | |
| 202 | if TYPE == "Gem" then | |
| 203 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0, 0, 0)) | |
| 204 | acs.Anchored = false | |
| 205 | acs.CanCollide = false | |
| 206 | acs.CFrame = PART.CFrame | |
| 207 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET)
| |
| 208 | weldBetween(PART, acs) | |
| 209 | elseif TYPE == "Skull" then | |
| 210 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0, 0, 0)) | |
| 211 | acs.Anchored = false | |
| 212 | acs.CanCollide = false | |
| 213 | acs.CFrame = PART.CFrame | |
| 214 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET)
| |
| 215 | weldBetween(PART, acs) | |
| 216 | elseif TYPE == "Eye" then | |
| 217 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0, 0, 0)) | |
| 218 | acs.Anchored = false | |
| 219 | acs.CanCollide = false | |
| 220 | acs.CFrame = PART.CFrame | |
| 221 | local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET)
| |
| 222 | weldBetween(PART, acs) | |
| 223 | end | |
| 224 | end | |
| 225 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 226 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 227 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
| 228 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
| 229 | local CHANGEDEFENSE = 0 | |
| 230 | local CHANGEDAMAGE = 0 | |
| 231 | local CHANGEMOVEMENT = 0 | |
| 232 | local ANIM = "Idle" | |
| 233 | local ATTACK = false | |
| 234 | local EQUIPPED = false | |
| 235 | local HOLD = false | |
| 236 | local COMBO = 1 | |
| 237 | local Rooted = false | |
| 238 | local SINE = 0 | |
| 239 | local KEYHOLD = false | |
| 240 | local CHANGE = 2 / Animation_Speed | |
| 241 | local WALKINGANIM = false | |
| 242 | local WALK = 0 | |
| 243 | local VALUE1 = false | |
| 244 | local VALUE2 = false | |
| 245 | local ROBLOXIDLEANIMATION = IT("Animation")
| |
| 246 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
| 247 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
| 248 | local WEAPONGUI = IT("ScreenGui", PlayerGui)
| |
| 249 | WEAPONGUI.Name = "Weapon GUI" | |
| 250 | local Weapon = IT("Model")
| |
| 251 | Weapon.Name = "Adds" | |
| 252 | local Delete = IT("Model", Character)
| |
| 253 | Delete.Name = "Those who must be banished." | |
| 254 | local Effects = IT("Folder", Weapon)
| |
| 255 | Effects.Name = "Effects" | |
| 256 | local ANIMATOR = Humanoid.Animator | |
| 257 | local ANIMATE = Character.Animate | |
| 258 | local HITPLAYERSOUNDS = {
| |
| 259 | "263032172", | |
| 260 | "263032182", | |
| 261 | "263032200", | |
| 262 | "263032221", | |
| 263 | "263032252", | |
| 264 | "263033191" | |
| 265 | } | |
| 266 | local HITARMORSOUNDS = {
| |
| 267 | "199149321", | |
| 268 | "199149338", | |
| 269 | "199149367", | |
| 270 | "199149409", | |
| 271 | "199149452" | |
| 272 | } | |
| 273 | local HITWEAPONSOUNDS = {
| |
| 274 | "199148971", | |
| 275 | "199149025", | |
| 276 | "199149072", | |
| 277 | "199149109", | |
| 278 | "199149119" | |
| 279 | } | |
| 280 | local HITBLOCKSOUNDS = {"199148933", "199148947"}
| |
| 281 | local UNANCHOR = true | |
| 282 | local SKILLTEXTCOLOR = C3(1, 0, 0) | |
| 283 | ArtificialHB = Instance.new("BindableEvent", script)
| |
| 284 | ArtificialHB.Name = "ArtificialHB" | |
| 285 | script:WaitForChild("ArtificialHB")
| |
| 286 | frame = Frame_Speed | |
| 287 | tf = 0 | |
| 288 | allowframeloss = false | |
| 289 | tossremainder = false | |
| 290 | lastframe = tick() | |
| 291 | script.ArtificialHB:Fire() | |
| 292 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 293 | tf = tf + s | |
| 294 | if tf >= frame then | |
| 295 | if allowframeloss then | |
| 296 | script.ArtificialHB:Fire() | |
| 297 | lastframe = tick() | |
| 298 | else | |
| 299 | for i = 1, math.floor(tf / frame) do | |
| 300 | script.ArtificialHB:Fire() | |
| 301 | end | |
| 302 | lastframe = tick() | |
| 303 | end | |
| 304 | if tossremainder then | |
| 305 | tf = 0 | |
| 306 | else | |
| 307 | tf = tf - frame * math.floor(tf / frame) | |
| 308 | end | |
| 309 | end | |
| 310 | end) | |
| 311 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
| 312 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
| 313 | end | |
| 314 | function PositiveAngle(NUMBER) | |
| 315 | if NUMBER >= 0 then | |
| 316 | NUMBER = 0 | |
| 317 | end | |
| 318 | return NUMBER | |
| 319 | end | |
| 320 | function NegativeAngle(NUMBER) | |
| 321 | if NUMBER <= 0 then | |
| 322 | NUMBER = 0 | |
| 323 | end | |
| 324 | return NUMBER | |
| 325 | end | |
| 326 | function Swait(NUMBER) | |
| 327 | if NUMBER == 0 or NUMBER == nil then | |
| 328 | ArtificialHB.Event:wait() | |
| 329 | else | |
| 330 | for i = 1, NUMBER do | |
| 331 | ArtificialHB.Event:wait() | |
| 332 | end | |
| 333 | end | |
| 334 | end | |
| 335 | function QuaternionFromCFrame(cf) | |
| 336 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 337 | local trace = m00 + m11 + m22 | |
| 338 | if trace > 0 then | |
| 339 | local s = math.sqrt(1 + trace) | |
| 340 | local recip = 0.5 / s | |
| 341 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
| 342 | else | |
| 343 | local i = 0 | |
| 344 | if m00 < m11 then | |
| 345 | i = 1 | |
| 346 | end | |
| 347 | if m22 > (i == 0 and m00 or m11) then | |
| 348 | i = 2 | |
| 349 | end | |
| 350 | if i == 0 then | |
| 351 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
| 352 | local recip = 0.5 / s | |
| 353 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
| 354 | elseif i == 1 then | |
| 355 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
| 356 | local recip = 0.5 / s | |
| 357 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
| 358 | elseif i == 2 then | |
| 359 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
| 360 | local recip = 0.5 / s | |
| 361 | return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
| 362 | end | |
| 363 | end | |
| 364 | end | |
| 365 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 366 | local xs, ys, zs = x + x, y + y, z + z | |
| 367 | local wx, wy, wz = w * xs, w * ys, w * zs | |
| 368 | local xx = x * xs | |
| 369 | local xy = x * ys | |
| 370 | local xz = x * zs | |
| 371 | local yy = y * ys | |
| 372 | local yz = y * zs | |
| 373 | local zz = z * zs | |
| 374 | return CFrame.new(px, py, pz, 1 - (yy + zz), xy - wz, xz + wy, xy + wz, 1 - (xx + zz), yz - wx, xz - wy, yz + wx, 1 - (xx + yy)) | |
| 375 | end | |
| 376 | function QuaternionSlerp(a, b, t) | |
| 377 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
| 378 | local startInterp, finishInterp | |
| 379 | if cosTheta >= 1.0E-4 then | |
| 380 | if 1 - cosTheta > 1.0E-4 then | |
| 381 | local theta = ACOS(cosTheta) | |
| 382 | local invSinTheta = 1 / SIN(theta) | |
| 383 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
| 384 | finishInterp = SIN(t * theta) * invSinTheta | |
| 385 | else | |
| 386 | startInterp = 1 - t | |
| 387 | finishInterp = t | |
| 388 | end | |
| 389 | elseif 1 + cosTheta > 1.0E-4 then | |
| 390 | local theta = ACOS(-cosTheta) | |
| 391 | local invSinTheta = 1 / SIN(theta) | |
| 392 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
| 393 | finishInterp = SIN(t * theta) * invSinTheta | |
| 394 | else | |
| 395 | startInterp = t - 1 | |
| 396 | finishInterp = t | |
| 397 | end | |
| 398 | return a[1] * startInterp + b[1] * finishInterp, a[2] * startInterp + b[2] * finishInterp, a[3] * startInterp + b[3] * finishInterp, a[4] * startInterp + b[4] * finishInterp | |
| 399 | end | |
| 400 | function Clerp(a, b, t) | |
| 401 | local qa = {
| |
| 402 | QuaternionFromCFrame(a) | |
| 403 | } | |
| 404 | local qb = {
| |
| 405 | QuaternionFromCFrame(b) | |
| 406 | } | |
| 407 | local ax, ay, az = a.x, a.y, a.z | |
| 408 | local bx, by, bz = b.x, b.y, b.z | |
| 409 | local _t = 1 - t | |
| 410 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
| 411 | end | |
| 412 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
| 413 | local frame = IT("Frame")
| |
| 414 | frame.BackgroundTransparency = TRANSPARENCY | |
| 415 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
| 416 | frame.Position = POSITION | |
| 417 | frame.Size = SIZE | |
| 418 | frame.BackgroundColor3 = COLOR | |
| 419 | frame.BorderColor3 = BORDERCOLOR | |
| 420 | frame.Name = NAME | |
| 421 | frame.Parent = PARENT | |
| 422 | return frame | |
| 423 | end | |
| 424 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
| 425 | local label = IT("TextLabel")
| |
| 426 | label.BackgroundTransparency = 1 | |
| 427 | label.Size = UD2(1, 0, 1, 0) | |
| 428 | label.Position = UD2(0, 0, 0, 0) | |
| 429 | label.TextColor3 = TEXTCOLOR | |
| 430 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
| 431 | label.TextTransparency = TRANSPARENCY | |
| 432 | label.FontSize = TEXTFONTSIZE | |
| 433 | label.Font = TEXTFONT | |
| 434 | label.BorderSizePixel = BORDERSIZEPIXEL | |
| 435 | label.TextScaled = false | |
| 436 | label.Text = TEXT | |
| 437 | label.Name = NAME | |
| 438 | label.Parent = PARENT | |
| 439 | return label | |
| 440 | end | |
| 441 | function NoOutlines(PART) | |
| 442 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
| 443 | end | |
| 444 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
| 445 | local NEWWELD = IT(TYPE) | |
| 446 | NEWWELD.Part0 = PART0 | |
| 447 | NEWWELD.Part1 = PART1 | |
| 448 | NEWWELD.C0 = C0 | |
| 449 | NEWWELD.C1 = C1 | |
| 450 | NEWWELD.Parent = PARENT | |
| 451 | return NEWWELD | |
| 452 | end | |
| 453 | local SOUND = IT("Sound", nil)
| |
| 454 | function CreateSound(ID, PARENT, VOLUME, PITCH) | |
| 455 | local NEWSOUND | |
| 456 | coroutine.resume(coroutine.create(function() | |
| 457 | NEWSOUND = SOUND:Clone() | |
| 458 | NEWSOUND.Parent = PARENT | |
| 459 | NEWSOUND.Volume = VOLUME | |
| 460 | NEWSOUND.Pitch = PITCH | |
| 461 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id=" .. ID | |
| 462 | NEWSOUND:play() | |
| 463 | repeat | |
| 464 | Swait() | |
| 465 | until NEWSOUND.Playing == false | |
| 466 | NEWSOUND:remove() | |
| 467 | end)) | |
| 468 | return NEWSOUND | |
| 469 | end | |
| 470 | function CFrameFromTopBack(at, top, back) | |
| 471 | local right = top:Cross(back) | |
| 472 | return CF(at.x, at.y, at.z, right.x, top.x, back.x, right.y, top.y, back.y, right.z, top.z, back.z) | |
| 473 | end | |
| 474 | function CreateWave(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
| 475 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 476 | local mesh = IT("SpecialMesh", wave)
| |
| 477 | mesh.MeshType = "FileMesh" | |
| 478 | mesh.MeshId = "http://www.roblox.com/asset/?id=20329976" | |
| 479 | mesh.Scale = SIZE | |
| 480 | mesh.Offset = VT(0, 0, -SIZE.X / 8) | |
| 481 | wave.CFrame = CFRAME | |
| 482 | coroutine.resume(coroutine.create(function(PART) | |
| 483 | for i = 1, WAIT do | |
| 484 | Swait() | |
| 485 | mesh.Scale = mesh.Scale + GROW | |
| 486 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
| 487 | if DOESROT == true then | |
| 488 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 489 | end | |
| 490 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 491 | if wave.Transparency > 0.99 then | |
| 492 | wave:remove() | |
| 493 | end | |
| 494 | end | |
| 495 | end)) | |
| 496 | end | |
| 497 | function CreateCrown(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
| 498 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 499 | local mesh = IT("SpecialMesh", wave)
| |
| 500 | mesh.MeshType = "FileMesh" | |
| 501 | mesh.MeshId = "http://www.roblox.com/asset/?id=1078075" | |
| 502 | mesh.Scale = SIZE | |
| 503 | mesh.Offset = VT(0, 0, -SIZE.X / 8) | |
| 504 | wave.CFrame = CFRAME | |
| 505 | coroutine.resume(coroutine.create(function(PART) | |
| 506 | for i = 1, WAIT do | |
| 507 | Swait() | |
| 508 | mesh.Scale = mesh.Scale + GROW | |
| 509 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
| 510 | if DOESROT == true then | |
| 511 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 512 | end | |
| 513 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 514 | if wave.Transparency > 0.99 then | |
| 515 | wave:remove() | |
| 516 | end | |
| 517 | end | |
| 518 | end)) | |
| 519 | end | |
| 520 | function CreateIceCrown(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
| 521 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 522 | local mesh = IT("SpecialMesh", wave)
| |
| 523 | mesh.MeshType = "FileMesh" | |
| 524 | mesh.MeshId = "http://www.roblox.com/asset/?id=1323306" | |
| 525 | mesh.Scale = SIZE | |
| 526 | mesh.Offset = VT(0, 0, -SIZE.X / 8) | |
| 527 | wave.CFrame = CFRAME | |
| 528 | coroutine.resume(coroutine.create(function(PART) | |
| 529 | for i = 1, WAIT do | |
| 530 | Swait() | |
| 531 | mesh.Scale = mesh.Scale + GROW | |
| 532 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
| 533 | if DOESROT == true then | |
| 534 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 535 | end | |
| 536 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 537 | if wave.Transparency > 0.99 then | |
| 538 | wave:remove() | |
| 539 | end | |
| 540 | end | |
| 541 | end)) | |
| 542 | end | |
| 543 | function CreateSpikeball(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
| 544 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 545 | local mesh = IT("SpecialMesh", wave)
| |
| 546 | mesh.MeshType = "FileMesh" | |
| 547 | mesh.MeshId = "http://www.roblox.com/asset/?id=9982590" | |
| 548 | mesh.Scale = SIZE | |
| 549 | mesh.Offset = VT(0, 0, -SIZE.X / 8) | |
| 550 | wave.CFrame = CFRAME | |
| 551 | coroutine.resume(coroutine.create(function(PART) | |
| 552 | for i = 1, WAIT do | |
| 553 | Swait() | |
| 554 | mesh.Scale = mesh.Scale + GROW | |
| 555 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
| 556 | if DOESROT == true then | |
| 557 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 558 | end | |
| 559 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 560 | if wave.Transparency > 0.99 then | |
| 561 | wave:remove() | |
| 562 | end | |
| 563 | end | |
| 564 | end)) | |
| 565 | end | |
| 566 | function CreateSwirl(SIZE, WAIT, CFRAME, DOESROT, ROT, COLOR, GROW) | |
| 567 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 568 | local mesh = IT("SpecialMesh", wave)
| |
| 569 | mesh.MeshType = "FileMesh" | |
| 570 | mesh.MeshId = "http://www.roblox.com/asset/?id=1051557" | |
| 571 | mesh.Scale = SIZE | |
| 572 | wave.CFrame = CFRAME | |
| 573 | coroutine.resume(coroutine.create(function(PART) | |
| 574 | for i = 1, WAIT do | |
| 575 | Swait() | |
| 576 | mesh.Scale = mesh.Scale + GROW | |
| 577 | mesh.Offset = VT(0, 0, -(mesh.Scale.X / 8)) | |
| 578 | if DOESROT == true then | |
| 579 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 580 | end | |
| 581 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 582 | if wave.Transparency > 0.99 then | |
| 583 | wave:remove() | |
| 584 | end | |
| 585 | end | |
| 586 | end)) | |
| 587 | end | |
| 588 | function CreateTornado(SIZE, DOESROT, ROT, WAIT, CFRAME, COLOR, GROW) | |
| 589 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 590 | local mesh = IT("SpecialMesh", wave)
| |
| 591 | mesh.MeshType = "FileMesh" | |
| 592 | mesh.MeshId = "http://www.roblox.com/asset/?id=102638417" | |
| 593 | mesh.Scale = SIZE | |
| 594 | wave.CFrame = CFRAME | |
| 595 | coroutine.resume(coroutine.create(function(PART) | |
| 596 | for i = 1, WAIT do | |
| 597 | Swait() | |
| 598 | mesh.Scale = mesh.Scale + GROW | |
| 599 | if DOESROT == true then | |
| 600 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 601 | end | |
| 602 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 603 | if wave.Transparency > 0.99 then | |
| 604 | wave:remove() | |
| 605 | end | |
| 606 | end | |
| 607 | end)) | |
| 608 | end | |
| 609 | function CreateRing(SIZE, DOESROT, ROT, WAIT, CFRAME, COLOR, GROW) | |
| 610 | local wave = CreatePart(3, Effects, "Neon", 0, 0.5, BRICKC(COLOR), "Effect", VT(0, 0, 0)) | |
| 611 | local mesh = IT("SpecialMesh", wave)
| |
| 612 | mesh.MeshType = "FileMesh" | |
| 613 | mesh.MeshId = "http://www.roblox.com/asset/?id=3270017" | |
| 614 | mesh.Scale = SIZE | |
| 615 | mesh.Offset = VT(0, 0, 0) | |
| 616 | wave.CFrame = CFRAME | |
| 617 | coroutine.resume(coroutine.create(function(PART) | |
| 618 | for i = 1, WAIT do | |
| 619 | Swait() | |
| 620 | mesh.Scale = mesh.Scale + GROW | |
| 621 | if DOESROT == true then | |
| 622 | wave.CFrame = wave.CFrame * CFrame.fromEulerAnglesXYZ(0, ROT, 0) | |
| 623 | end | |
| 624 | wave.Transparency = wave.Transparency + 0.5 / WAIT | |
| 625 | if wave.Transparency > 0.99 then | |
| 626 | wave:remove() | |
| 627 | end | |
| 628 | end | |
| 629 | end)) | |
| 630 | end | |
| 631 | function MagicSphere(SIZE, WAIT, CFRAME, COLOR, GROW) | |
| 632 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(1, 1, 1), true) | |
| 633 | local mesh = IT("SpecialMesh", wave)
| |
| 634 | mesh.MeshType = "Sphere" | |
| 635 | mesh.Scale = SIZE | |
| 636 | mesh.Offset = VT(0, 0, 0) | |
| 637 | wave.CFrame = CFRAME | |
| 638 | coroutine.resume(coroutine.create(function(PART) | |
| 639 | for i = 1, WAIT do | |
| 640 | Swait() | |
| 641 | mesh.Scale = mesh.Scale + GROW | |
| 642 | wave.Transparency = wave.Transparency + 1 / WAIT | |
| 643 | if wave.Transparency > 0.99 then | |
| 644 | wave:remove() | |
| 645 | end | |
| 646 | end | |
| 647 | end)) | |
| 648 | end | |
| 649 | function MagicBlock(SIZE, WAIT, CFRAME, COLOR, GROW) | |
| 650 | local wave = CreatePart(3, Effects, "Neon", 0, 0, BRICKC(COLOR), "Effect", VT(SIZE, SIZE, SIZE), true) | |
| 651 | local mesh = IT("BlockMesh", wave)
| |
| 652 | wave.CFrame = CFRAME | |
| 653 | coroutine.resume(coroutine.create(function(PART) | |
| 654 | for i = 1, WAIT do | |
| 655 | Swait() | |
| 656 | mesh.Scale = mesh.Scale + GROW | |
| 657 | wave.CFrame = CFRAME * ANGLES(RAD(math.random(-360, 360)), RAD(math.random(-360, 360)), RAD(math.random(-360, 360))) | |
| 658 | wave.Transparency = wave.Transparency + 1 / WAIT | |
| 659 | if wave.Transparency > 0.99 then | |
| 660 | wave:remove() | |
| 661 | end | |
| 662 | end | |
| 663 | end)) | |
| 664 | end | |
| 665 | function MakeForm(PART, TYPE) | |
| 666 | if TYPE == "Cyl" then | |
| 667 | local MSH = IT("CylinderMesh", PART)
| |
| 668 | elseif TYPE == "Ball" then | |
| 669 | local MSH = IT("SpecialMesh", PART)
| |
| 670 | MSH.MeshType = "Sphere" | |
| 671 | elseif TYPE == "Wedge" then | |
| 672 | local MSH = IT("SpecialMesh", PART)
| |
| 673 | MSH.MeshType = "Wedge" | |
| 674 | end | |
| 675 | end | |
| 676 | function CheckTableForString(Table, String) | |
| 677 | for i, v in pairs(Table) do | |
| 678 | if string.find(string.lower(String), string.lower(v)) then | |
| 679 | return true | |
| 680 | end | |
| 681 | end | |
| 682 | return false | |
| 683 | end | |
| 684 | function CheckIntangible(Hit) | |
| 685 | local ProjectileNames = {
| |
| 686 | "Water", | |
| 687 | "Arrow", | |
| 688 | "Projectile", | |
| 689 | "Effect", | |
| 690 | "Rail", | |
| 691 | "Lightning", | |
| 692 | "Bullet" | |
| 693 | } | |
| 694 | if Hit and Hit.Parent and (not Hit.CanCollide or CheckTableForString(ProjectileNames, Hit.Name)) and not Hit.Parent:FindFirstChild("Humanoid") then
| |
| 695 | return true | |
| 696 | end | |
| 697 | return false | |
| 698 | end | |
| 699 | Debris = game:GetService("Debris")
| |
| 700 | BaseLightning = IT("Part")
| |
| 701 | BaseLightning.Anchored = true | |
| 702 | BaseLightning.CanCollide = false | |
| 703 | BaseLightning.Material = "Neon" | |
| 704 | function CastZapRay(StartPos, Vec, Length, Ignore, DelayIfHit) | |
| 705 | local Ignore = type(Ignore) == "table" and Ignore or {Ignore}
| |
| 706 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Vec * Length), Ignore)
| |
| 707 | if RayHit and CheckIntangible(RayHit) then | |
| 708 | if DelayIfHit then | |
| 709 | wait() | |
| 710 | end | |
| 711 | RayHit, RayPos, RayNormal = CastZapRay(RayPos + Vec * 0.01, Vec, Length - (StartPos - RayPos).magnitude, Ignore, DelayIfHit) | |
| 712 | end | |
| 713 | return RayHit, RayPos, RayNormal | |
| 714 | end | |
| 715 | function Zap(Table) | |
| 716 | local StartPos, TargetPos, Character, Color = Table.StartPosition, Table.TargetPosition, Table.Character, Table.Color | |
| 717 | local Duration = Table.Duration or 2 | |
| 718 | local FadeRate = Table.FadeRate or 0.05 | |
| 719 | local Offset = Table.Offset or 2 | |
| 720 | local Individualize = Table.Individualize or false | |
| 721 | local MaxRange = Table.MaxRange or 200 | |
| 722 | local SegmentLength = Table.SegmentLength or 5 | |
| 723 | local TimeToFade = Table.TimeToFade or 0.5 | |
| 724 | local Ignore = Table.Ignore or {}
| |
| 725 | local SIZE = Table.Size or 0.3 | |
| 726 | if not (StartPos and TargetPos) or not Character then | |
| 727 | return | |
| 728 | end | |
| 729 | local LightningModel = IT("Folder", Effects)
| |
| 730 | LightningModel.Name = "ZAPP" | |
| 731 | for i, v in pairs({Character, LightningModel}) do
| |
| 732 | table.insert(Ignore, v) | |
| 733 | end | |
| 734 | local LastPos = StartPos | |
| 735 | local Direction = CFrame.new(StartPos, TargetPos).lookVector | |
| 736 | local RayHit, RayPos, RayNormal = CastZapRay(StartPos, Direction, MaxRange, Ignore, false) | |
| 737 | local RayLength = (StartPos - RayPos).Magnitude | |
| 738 | local Struck = false | |
| 739 | local TotalSegments = math.ceil(RayLength / SegmentLength) | |
| 740 | Direction = CFrame.new(StartPos, RayPos).lookVector | |
| 741 | local LightningBolt = IT("Model", Effects)
| |
| 742 | LightningBolt.Name = "Lightning" | |
| 743 | if not Individualize then | |
| 744 | table.insert(LightningBolts, LightningBolt) | |
| 745 | end | |
| 746 | LastBolt = LightningBolt | |
| 747 | Debris:AddItem(LightningBolt, Duration) | |
| 748 | LightningBolt.Parent = LightningModel | |
| 749 | for i = 1, TotalSegments do | |
| 750 | if not Struck then | |
| 751 | local Entropy = Vector3.new(math.random() * Offset * 2.5 - Offset, math.random() * Offset * 2.5 - Offset, math.random() * Offset * 2.5 - Offset) | |
| 752 | local NewPos = StartPos + Direction * (RayLength * (i / TotalSegments)) + Entropy | |
| 753 | local SegmentVec = NewPos - LastPos | |
| 754 | local RayHit, RayPos, RayNormal = CastZapRay(LastPos, SegmentVec.Unit, SegmentVec.Magnitude, {Character, LightningModel}, false)
| |
| 755 | local RayVec = LastPos - RayPos | |
| 756 | local LightningPart = BaseLightning:Clone() | |
| 757 | LightningPart.BrickColor = BrickColor.new(Color) | |
| 758 | LightningPart.Size = Vector3.new(SIZE, SIZE, RayVec.Magnitude) | |
| 759 | LightningPart.CFrame = CFrame.new(LastPos, RayPos) * CFrame.new(0, 0, -(RayVec.Magnitude / 2)) | |
| 760 | table.insert(Effects2, {
| |
| 761 | LightningPart, | |
| 762 | "Disappear", | |
| 763 | 0.025, | |
| 764 | 1, | |
| 765 | 1, | |
| 766 | 1, | |
| 767 | 2 | |
| 768 | }) | |
| 769 | local CylinderMesh = IT("CylinderMesh", LightningPart)
| |
| 770 | local OrigCF = LightningPart.CFrame | |
| 771 | LightningPart.Size = Vector3.new(LightningPart.Size.X, LightningPart.Size.Z, LightningPart.Size.Y) | |
| 772 | LightningPart.CFrame = OrigCF * CFrame.Angles(math.pi / 2, 0, 0) | |
| 773 | LightningPart.Parent = LightningBolt | |
| 774 | LastPos = NewPos | |
| 775 | end | |
| 776 | end | |
| 777 | return {
| |
| 778 | RayHit = RayHit, | |
| 779 | RayPos = RayPos, | |
| 780 | RayNormal = RayNormal, | |
| 781 | LightningModel = LightningModel | |
| 782 | } | |
| 783 | end | |
| 784 | function turnto(position) | |
| 785 | RootPart.CFrame = CFrame.new(RootPart.CFrame.p, VT(position.X, RootPart.Position.Y, position.Z)) * CFrame.new(0, 0, 0) | |
| 786 | end | |
| 787 | function chatfunc(text, waitt) | |
| 788 | local chat = coroutine.wrap(function() | |
| 789 | if Character:FindFirstChild("TalkingBillBoard") ~= nil then
| |
| 790 | Character:FindFirstChild("TalkingBillBoard").Parent = nil
| |
| 791 | end | |
| 792 | local naeeym2 = Instance.new("BillboardGui", Character)
| |
| 793 | naeeym2.Size = UDim2.new(0, 100, 0, 40) | |
| 794 | naeeym2.StudsOffset = Vector3.new(0, 2, 0) | |
| 795 | naeeym2.Adornee = Character.Head | |
| 796 | naeeym2.Name = "TalkingBillBoard" | |
| 797 | naeeym2.AlwaysOnTop = true | |
| 798 | local tecks2 = Instance.new("TextLabel", naeeym2)
| |
| 799 | tecks2.BackgroundTransparency = 1 | |
| 800 | tecks2.BorderSizePixel = 0 | |
| 801 | tecks2.Text = "" | |
| 802 | tecks2.Font = "Antique" | |
| 803 | tecks2.TextSize = 30 | |
| 804 | tecks2.TextStrokeTransparency = 1 | |
| 805 | tecks2.TextColor3 = SKILLTEXTCOLOR | |
| 806 | tecks2.TextStrokeColor3 = Color3.new(0, 0, 0) | |
| 807 | tecks2.Size = UDim2.new(1, 0, 0.5, 0) | |
| 808 | for i = 1, string.len(text) do | |
| 809 | if naeeym2.Parent ~= nil then | |
| 810 | CreateSound("418252437", Effects, 1, MRANDOM(9, 11) / 10)
| |
| 811 | end | |
| 812 | tecks2.Text = string.sub(text, 1, i) | |
| 813 | Swait(3) | |
| 814 | end | |
| 815 | wait(waitt / 10) | |
| 816 | coroutine.resume(coroutine.create(function() | |
| 817 | for i = 1, 10 do | |
| 818 | tecks2.TextTransparency = tecks2.TextTransparency + 0.1 | |
| 819 | Swait() | |
| 820 | end | |
| 821 | naeeym2:Destroy() | |
| 822 | end)) | |
| 823 | end) | |
| 824 | chat() | |
| 825 | end | |
| 826 | for _, c in pairs(Weapon:GetChildren()) do | |
| 827 | if c.ClassName == "Part" then | |
| 828 | c.CustomPhysicalProperties = PhysicalProperties.new(0, 0, 0, 0, 0) | |
| 829 | end | |
| 830 | end | |
| 831 | Weapon.Parent = Character | |
| 832 | Humanoid.Died:connect(function() | |
| 833 | ATTACK = true | |
| 834 | end) | |
| 835 | Humanoid.Died:connect(function() | |
| 836 | Humanoid.Parent = nil | |
| 837 | Humanoid.Health = "inf" | |
| 838 | Humanoid.MaxHealth = "inf" | |
| 839 | end) | |
| 840 | VALUE1 = true | |
| 841 | local SKILL1FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.23, 0, 0.8, 0), UD2(0.26, 0, 0.07, 0), C3(0, 0, 0), C3(0, 0, 0), "Skill 1 Frame") | |
| 842 | local SKILL2FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.5, 0, 0.8, 0), UD2(0.26, 0, 0.07, 0), C3(0, 0, 0), C3(0, 0, 0), "Skill 2 Frame") | |
| 843 | local SKILL3FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.23, 0, 0.93, 0), UD2(0.26, 0, 0.07, 0), C3(0, 0, 0), C3(0, 0, 0), "Skill 3 Frame") | |
| 844 | local SKILL4FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.5, 0, 0.93, 0), UD2(0.26, 0, 0.07, 0), C3(0, 0, 0), C3(0, 0, 0), "Skill 4 Frame") | |
| 845 | local SKILL5FRAME = CreateFrame(WEAPONGUI, 1, 2, UD2(0.365, 0, 0.7, 0), UD2(0.26, 0, 0.07, 0), C3(0, 0, 0), C3(0, 0, 0), "Skill 5 Frame") | |
| 846 | local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Banish Laser", SKILLTEXTCOLOR, 8, "Antique", 0, 2, 1, "Text 1") | |
| 847 | local SKILL2TEXT = CreateLabel(SKILL2FRAME, "[C] Banishing Rampage", SKILLTEXTCOLOR, 8, "Antique", 0, 2, 1, "Text 2") | |
| 848 | local SKILL3TEXT = CreateLabel(SKILL3FRAME, "[Q] Warp Vector", SKILLTEXTCOLOR, 8, "Antique", 0, 2, 1, "Text 3") | |
| 849 | local SKILL4TEXT = CreateLabel(SKILL4FRAME, "[V] Spectral Banish", SKILLTEXTCOLOR, 8, "Antique", 0, 2, 1, "Text 4") | |
| 850 | local SKILL5TEXT = CreateLabel(SKILL5FRAME, "[X] De-Banish", SKILLTEXTCOLOR, 8, "Antique", 0, 2, 1, "Text 5") | |
| 851 | function CastWarpOutlines(TARGET) | |
| 852 | coroutine.resume(coroutine.create(function() | |
| 853 | local T = TARGET:GetChildren() | |
| 854 | for i = 1, #T do | |
| 855 | local child = T[i] | |
| 856 | if child.ClassName == "Part" or child.ClassName == "MeshPart" then | |
| 857 | do | |
| 858 | local clone = child:Clone() | |
| 859 | clone.Parent = Effects | |
| 860 | clone.Anchored = true | |
| 861 | clone.CanCollide = false | |
| 862 | clone:ClearAllChildren() | |
| 863 | clone.CFrame = child.CFrame | |
| 864 | if clone.Name == "Head" then | |
| 865 | clone.Size = VT(clone.Size.Y, clone.Size.Y, clone.Size.Y) | |
| 866 | end | |
| 867 | if clone.ClassName == "MeshPart" then | |
| 868 | clone.TextureID = "" | |
| 869 | end | |
| 870 | clone.Color = C3(1, 0, 0) | |
| 871 | clone.Material = "Neon" | |
| 872 | coroutine.resume(coroutine.create(function() | |
| 873 | for i = 1, 100 do | |
| 874 | Swait() | |
| 875 | clone.Transparency = clone.Transparency + 0.01 | |
| 876 | clone.Size = clone.Size + VT(0.001, 0.001, 0.001) | |
| 877 | end | |
| 878 | clone:remove() | |
| 879 | end)) | |
| 880 | end | |
| 881 | end | |
| 882 | end | |
| 883 | end)) | |
| 884 | end | |
| 885 | function killnearest(position, range, maxstrength) | |
| 886 | for i, v in ipairs(workspace:GetChildren()) do | |
| 887 | local body = v:GetChildren() | |
| 888 | for part = 1, #body do | |
| 889 | if (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character and range > (body[part].Position - position).Magnitude and v.ClassName == "Model" then | |
| 890 | CastWarpOutlines(v) | |
| 891 | v:remove() | |
| 892 | if game.Players:FindFirstChild(v.Name) then | |
| 893 | local Value = IT("BoolValue", Delete)
| |
| 894 | Value.Name = v.Name | |
| 895 | end | |
| 896 | end | |
| 897 | end | |
| 898 | end | |
| 899 | end | |
| 900 | function CastProperRay(StartPos, Vec, Length, Ignore) | |
| 901 | local Direction = CFrame.new(StartPos, Vec).lookVector | |
| 902 | local Ignore = type(Ignore) == "table" and Ignore or {Ignore}
| |
| 903 | local RayHit, RayPos, RayNormal = game:GetService("Workspace"):FindPartOnRayWithIgnoreList(Ray.new(StartPos, Direction * Length), Ignore)
| |
| 904 | return RayHit, RayPos, RayNormal | |
| 905 | end | |
| 906 | function Debree(POS, SWAIT) | |
| 907 | coroutine.resume(coroutine.create(function() | |
| 908 | local HOLDER = IT("Model", Effects)
| |
| 909 | HOLDER.Name = "Debree" | |
| 910 | local HITFLOOR = Raycast(POS, CF(POS, POS + VT(0, -1, 0)).lookVector, 4 * Player_Size, Character) | |
| 911 | MagicSphere(VT(15, 1, 15), SWAIT, CF(POS), "Really red", VT(0, 0, 0)) | |
| 912 | MagicSphere(VT(13, 1, 13), SWAIT, CF(POS), "Really red", VT(0, 0, 0)) | |
| 913 | MagicSphere(VT(12, 1, 12), SWAIT, CF(POS), "Really red", VT(0, 0, 0)) | |
| 914 | repeat | |
| 915 | Swait() | |
| 916 | until HITFLOOR ~= nil | |
| 917 | local O = 0 | |
| 918 | for i = 1, 18 do | |
| 919 | do | |
| 920 | local Part = CreatePart(3, HOLDER, HITFLOOR.Material, 0, 0, HITFLOOR.BrickColor, "Debree", VT(3, 3, 3)) | |
| 921 | Part.CFrame = CF(CF(POS) * CF(10 - i, 0, O).p) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 922 | O = O - 2.25 + i / 4 | |
| 923 | coroutine.resume(coroutine.create(function() | |
| 924 | Swait(SWAIT) | |
| 925 | for i = 1, 60 do | |
| 926 | Swait() | |
| 927 | local RayHit, Way = CastProperRay(Part.Position, POS, 0.1, workspace) | |
| 928 | Part.CFrame = CF(Way) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 929 | end | |
| 930 | for i = 1, 50 do | |
| 931 | Swait() | |
| 932 | Part.Size = Part.Size * 0.9 | |
| 933 | end | |
| 934 | end)) | |
| 935 | end | |
| 936 | end | |
| 937 | local O = 0 | |
| 938 | for i = 1, 18 do | |
| 939 | do | |
| 940 | local Part = CreatePart(3, HOLDER, HITFLOOR.Material, 0, 0, HITFLOOR.BrickColor, "Debree", VT(3, 3, 3)) | |
| 941 | Part.CFrame = CF(CF(POS) * CF(10 - i, 0, O).p) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 942 | O = O + 2.25 - i / 4 | |
| 943 | coroutine.resume(coroutine.create(function() | |
| 944 | Swait(SWAIT) | |
| 945 | for i = 1, 60 do | |
| 946 | Swait() | |
| 947 | local RayHit, Way = CastProperRay(Part.Position, POS, 0.1, workspace) | |
| 948 | Part.CFrame = CF(Way) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 949 | end | |
| 950 | for i = 1, 50 do | |
| 951 | Swait() | |
| 952 | Part.Size = Part.Size * 0.9 | |
| 953 | end | |
| 954 | end)) | |
| 955 | end | |
| 956 | end | |
| 957 | Swait(SWAIT + 110) | |
| 958 | HOLDER:remove() | |
| 959 | end)) | |
| 960 | end | |
| 961 | local Gun = CreatePart(3, Weapon, "SmoothPlastic", 0, 0, "Really black", "Gun", VT(0, 0, 0), false) | |
| 962 | local HandleMesh = CreateMesh("SpecialMesh", Gun, "FileMesh", "430198390", "430198451", VT(0.02, 0.02, 0.02), VT(0, 0, 0))
| |
| 963 | local Weld = CreateWeldOrSnapOrMotor("Weld", Gun, RightArm, Gun, CF(0, -1.7, -0.2) * ANGLES(RAD(0), RAD(90), RAD(-90)), CF(0, 0, 0))
| |
| 964 | GunPoint = CreatePart(3, Weapon, "SmoothPlastic", 0, 1, "Really black", "Point blank", VT(0, 0, 0), false) | |
| 965 | local HandleWeld = CreateWeldOrSnapOrMotor("Weld", GunPoint, RightArm, GunPoint, CF(0, -3.1, -0.8) * ANGLES(RAD(0), RAD(0), RAD(135)), CF(0, 0, 0))
| |
| 966 | function BanishingBullet() | |
| 967 | ATTACK = true | |
| 968 | Rooted = false | |
| 969 | for i = 0, 0.4, 0.1 / Animation_Speed do | |
| 970 | Swait() | |
| 971 | turnto(Mouse.Hit.p) | |
| 972 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
| 973 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
| 974 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 975 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 976 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 977 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 978 | end | |
| 979 | repeat | |
| 980 | for i = 0, 0.2, 0.1 / Animation_Speed do | |
| 981 | Swait() | |
| 982 | turnto(Mouse.Hit.p) | |
| 983 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
| 984 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.5 / Animation_Speed) | |
| 985 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(0), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 986 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 987 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 988 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 989 | end | |
| 990 | CreateSound("238353911", GunPoint, 10, MRANDOM(9, 11) / 10)
| |
| 991 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.1, 0.1, 0.1)) | |
| 992 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.05, 0.05, 0.05)) | |
| 993 | local RayHit, Way = CastProperRay(GunPoint.Position, Mouse.Hit.p, 1500, Character) | |
| 994 | local distance = (GunPoint.Position - Way).magnitude | |
| 995 | for i = 1, 5 do | |
| 996 | local laser = Instance.new("Part", Effects)
| |
| 997 | laser.Transparency = 0 | |
| 998 | laser.CanCollide = false | |
| 999 | laser.Anchored = true | |
| 1000 | laser.Color = C3(1, 0, 0) | |
| 1001 | laser.Material = "Neon" | |
| 1002 | laser.formFactor = Enum.FormFactor.Custom | |
| 1003 | laser.Size = Vector3.new(0.15, 0.15, distance) | |
| 1004 | laser.CFrame = CFrame.new(GunPoint.Position, Way) * CFrame.new(0, 0, -distance / 2) | |
| 1005 | MagicSphere(VT(0.1, 0.1, 0.1), 45, CF(Way), "Really red", VT(0.05, 0.05, 0.05)) | |
| 1006 | for i = 1, 5 do | |
| 1007 | MagicSphere(VT(0.2, 0.2, 1), 65, CF(CF(Way) * CF(MRANDOM(-1, 1), MRANDOM(-1, 1), MRANDOM(-1, 1)).p, Way), "Really red", VT(0.001, 0.001, 0), 0.5) | |
| 1008 | end | |
| 1009 | table.insert(Effects2, {
| |
| 1010 | laser, | |
| 1011 | "Disappear", | |
| 1012 | 0.1, | |
| 1013 | 1, | |
| 1014 | 1, | |
| 1015 | 1, | |
| 1016 | 2 | |
| 1017 | }) | |
| 1018 | if RayHit ~= nil then | |
| 1019 | local v = RayHit.Parent | |
| 1020 | if v ~= nil and v.ClassName == "Model" then | |
| 1021 | CastWarpOutlines(v) | |
| 1022 | v.Parent = nil | |
| 1023 | if game.Players:FindFirstChild(v.Name) then | |
| 1024 | local Value = IT("BoolValue", Delete)
| |
| 1025 | Value.Name = v.Name | |
| 1026 | end | |
| 1027 | end | |
| 1028 | end | |
| 1029 | end | |
| 1030 | for i = 0, 0.3, 0.1 / Animation_Speed do | |
| 1031 | Swait() | |
| 1032 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
| 1033 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-90)), 0.25 / Animation_Speed) | |
| 1034 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(90), RAD(15), RAD(90)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1035 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1036 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1037 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1038 | end | |
| 1039 | until KEYHOLD == false | |
| 1040 | ATTACK = false | |
| 1041 | Rooted = false | |
| 1042 | end | |
| 1043 | function WarpVector() | |
| 1044 | ATTACK = true | |
| 1045 | Rooted = true | |
| 1046 | for i = 0, 1, 0.1 / Animation_Speed do | |
| 1047 | Swait() | |
| 1048 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1049 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1050 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(45), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1051 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1052 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1053 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1054 | end | |
| 1055 | Debree(CF(RootPart.Position) * CF(0, -2.8, 0).p, 75) | |
| 1056 | UNANCHOR = false | |
| 1057 | RootPart.Anchored = true | |
| 1058 | for i = 0, 2, 0.1 / Animation_Speed do | |
| 1059 | Swait() | |
| 1060 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, -10 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1061 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1062 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(45), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1063 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1064 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1065 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1066 | end | |
| 1067 | local POS = RootPart.Position | |
| 1068 | RootPart.CFrame = CF(CF(Mouse.Hit.p) * CF(0, 2.8, 0).p, POS) | |
| 1069 | Debree(CF(RootPart.Position) * CF(0, -2.5, 0).p, 150) | |
| 1070 | for i = 0, 2, 0.1 / Animation_Speed do | |
| 1071 | Swait() | |
| 1072 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1073 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1074 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(45), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1075 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1076 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1077 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1078 | end | |
| 1079 | ATTACK = false | |
| 1080 | Rooted = false | |
| 1081 | end | |
| 1082 | function BanishingRampage() | |
| 1083 | ATTACK = true | |
| 1084 | Rooted = false | |
| 1085 | chatfunc("Be gone...", 3)
| |
| 1086 | for i = 0, 2, 0.1 / Animation_Speed do | |
| 1087 | Swait() | |
| 1088 | turnto(Mouse.Hit.p) | |
| 1089 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, -1.5) * ANGLES(RAD(0), RAD(0), RAD(45)), 0.5 / Animation_Speed) | |
| 1090 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(15), RAD(0), RAD(-45)), 0.15 / Animation_Speed) | |
| 1091 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 1, -0.3) * ANGLES(RAD(25), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1092 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1093 | RightHip.C0 = Clerp(RightHip.C0, CF(1, 0.5, -0.75) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1094 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.4) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
| 1095 | end | |
| 1096 | local HITFLOOR = Raycast(RootPart.Position, CF(RootPart.Position, RootPart.Position + VT(0, -1, 0)).lookVector, 4 * Player_Size, Character) | |
| 1097 | repeat | |
| 1098 | Swait() | |
| 1099 | HITFLOOR = Raycast(RootPart.Position, CF(RootPart.Position, RootPart.Position + VT(0, -1, 0)).lookVector, 4 * Player_Size, Character) | |
| 1100 | until HITFLOOR ~= nil | |
| 1101 | CreateSound("238353911", GunPoint, 10, MRANDOM(9, 11) / 10)
| |
| 1102 | local SOUND = CreateSound("415700134", Effects, 10, 1.6)
| |
| 1103 | CreateSound("138677306", Effects, 7, 1.2)
| |
| 1104 | coroutine.resume(coroutine.create(function() | |
| 1105 | local CFRAME = RootPart.CFrame * CF(0, -1.2, -3) | |
| 1106 | local SIZE = 1 | |
| 1107 | while true do | |
| 1108 | Swait() | |
| 1109 | for i = 1, 2 do | |
| 1110 | MagicSphere(VT(SIZE / 5, SIZE / 5, SIZE * 2), 65, CF(CFRAME * CF(MRANDOM(-5, 5), MRANDOM(-5, 5), MRANDOM(-5, 5)).p, CFRAME.p), "Really red", VT(0.001, 0.001, 0), 0.5) | |
| 1111 | end | |
| 1112 | do | |
| 1113 | local Part = CreatePart(3, Effects, HITFLOOR.Material, 0, 0, HITFLOOR.BrickColor, "Debree", VT(SIZE / 5, SIZE / 5, SIZE / 5)) | |
| 1114 | Part.CFrame = CFRAME * CF(SIZE / 1.5, -0.7, 0) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 1115 | coroutine.resume(coroutine.create(function() | |
| 1116 | Swait(200) | |
| 1117 | Part.Anchored = false | |
| 1118 | end)) | |
| 1119 | local Part = CreatePart(3, Effects, HITFLOOR.Material, 0, 0, HITFLOOR.BrickColor, "Debree", VT(SIZE / 5, SIZE / 5, SIZE / 5)) | |
| 1120 | Part.CFrame = CFRAME * CF(-SIZE / 1.5, -0.7, 0) * ANGLES(RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180)), RAD(MRANDOM(-180, 180))) | |
| 1121 | coroutine.resume(coroutine.create(function() | |
| 1122 | Swait(200) | |
| 1123 | Part.Anchored = false | |
| 1124 | end)) | |
| 1125 | MagicSphere(VT(SIZE, SIZE, SIZE), 75, CFRAME, "Really red", VT(-SIZE / 75, -SIZE / 75, -SIZE / 75)) | |
| 1126 | killnearest(CFRAME.p, SIZE, 0) | |
| 1127 | SIZE = SIZE + 2 | |
| 1128 | CFRAME = CFRAME * CF(0, 0, -2) | |
| 1129 | if SOUND.Playing == false then | |
| 1130 | break | |
| 1131 | end | |
| 1132 | end | |
| 1133 | end | |
| 1134 | end)) | |
| 1135 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.1, 0.1, 0.1)) | |
| 1136 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.05, 0.05, 0.05)) | |
| 1137 | for i = 0, 3, 0.1 / Animation_Speed do | |
| 1138 | Swait() | |
| 1139 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, -1.5) * ANGLES(RAD(0), RAD(0), RAD(45)), 0.5 / Animation_Speed) | |
| 1140 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(10), RAD(0), RAD(-45)), 0.15 / Animation_Speed) | |
| 1141 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 1, -0.3) * ANGLES(RAD(55), RAD(0), RAD(0)) * RIGHTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1142 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-12)) * LEFTSHOULDERC0, 0.5 / Animation_Speed) | |
| 1143 | RightHip.C0 = Clerp(RightHip.C0, CF(1, 0.5, -0.75) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.5 / Animation_Speed) | |
| 1144 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.4) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(90)), 0.5 / Animation_Speed) | |
| 1145 | end | |
| 1146 | ATTACK = false | |
| 1147 | Rooted = false | |
| 1148 | end | |
| 1149 | function SpectralBanishing() | |
| 1150 | ATTACK = true | |
| 1151 | Rooted = false | |
| 1152 | chatfunc("If you desire to be a ghost...", 20)
| |
| 1153 | for i = 0, 5, 0.1 / Animation_Speed do | |
| 1154 | Swait() | |
| 1155 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(45)), 0.25 / Animation_Speed) | |
| 1156 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(-45 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(-45)), 0.25 / Animation_Speed) | |
| 1157 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(180), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(45), RAD(0)) * RIGHTSHOULDERC0, 0.25 / Animation_Speed) | |
| 1158 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.25 / Animation_Speed) | |
| 1159 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1160 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1161 | end | |
| 1162 | chatfunc("Then move on to the afterlife!", 6)
| |
| 1163 | CreateSound("238353911", GunPoint, 10, MRANDOM(9, 11) / 10)
| |
| 1164 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.1, 0.1, 0.1)) | |
| 1165 | MagicSphere(VT(0.1, 0.1, 0.1), 45, GunPoint.CFrame, "Really red", VT(0.05, 0.05, 0.05)) | |
| 1166 | local RayHit, Way = CastProperRay(GunPoint.Position, CF(GunPoint.Position) * CF(0, 1500, 0).p, 1500, Character) | |
| 1167 | local distance = (GunPoint.Position - Way).magnitude | |
| 1168 | for i = 1, 5 do | |
| 1169 | local laser = Instance.new("Part", Effects)
| |
| 1170 | laser.Transparency = 0 | |
| 1171 | laser.CanCollide = false | |
| 1172 | laser.Anchored = true | |
| 1173 | laser.Color = C3(1, 0, 0) | |
| 1174 | laser.Material = "Neon" | |
| 1175 | laser.formFactor = Enum.FormFactor.Custom | |
| 1176 | laser.Size = Vector3.new(0.15, 0.15, distance) | |
| 1177 | laser.CFrame = CFrame.new(GunPoint.Position, Way) * CFrame.new(0, 0, -distance / 2) | |
| 1178 | table.insert(Effects2, {
| |
| 1179 | laser, | |
| 1180 | "Disappear", | |
| 1181 | 0.1, | |
| 1182 | 1, | |
| 1183 | 1, | |
| 1184 | 1, | |
| 1185 | 2 | |
| 1186 | }) | |
| 1187 | end | |
| 1188 | coroutine.resume(coroutine.create(function() | |
| 1189 | Swait(15) | |
| 1190 | local FILTER = IT("ColorCorrectionEffect", game.Lighting)
| |
| 1191 | for i = 1, 25 do | |
| 1192 | Swait() | |
| 1193 | FILTER.TintColor = C3(1, 1 - i / 50, 1 - i / 50) | |
| 1194 | end | |
| 1195 | local GAME = game.Players:GetChildren() | |
| 1196 | for PLAYER = 1, #GAME do | |
| 1197 | do | |
| 1198 | local PLAY = GAME[PLAYER] | |
| 1199 | if PLAY.Character ~= nil and PLAY.Character.Parent ~= workspace then | |
| 1200 | PLAY.Character.Parent = nil | |
| 1201 | coroutine.resume(coroutine.create(function() | |
| 1202 | if PLAY.Character:FindFirstChild("HumanoidRootPart") then
| |
| 1203 | PLAY.Character.Parent = workspace | |
| 1204 | local Value = IT("BoolValue", Delete)
| |
| 1205 | Value.Name = PLAY.Name | |
| 1206 | end | |
| 1207 | end)) | |
| 1208 | end | |
| 1209 | end | |
| 1210 | end | |
| 1211 | for i = 1, 25 do | |
| 1212 | Swait() | |
| 1213 | FILTER.TintColor = C3(1, 0.4980392156862745 + i / 50, 0.4980392156862745 + i / 50) | |
| 1214 | end | |
| 1215 | end)) | |
| 1216 | for i = 0, 2, 0.1 / Animation_Speed do | |
| 1217 | Swait() | |
| 1218 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(45)), 0.25 / Animation_Speed) | |
| 1219 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(-45 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(-45)), 0.25 / Animation_Speed) | |
| 1220 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(195), RAD(0), RAD(0)) * ANGLES(RAD(0), RAD(45), RAD(0)) * RIGHTSHOULDERC0, 0.25 / Animation_Speed) | |
| 1221 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.25 / Animation_Speed) | |
| 1222 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1223 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1224 | end | |
| 1225 | ATTACK = false | |
| 1226 | Rooted = false | |
| 1227 | end | |
| 1228 | function Taunt() | |
| 1229 | ATTACK = true | |
| 1230 | Rooted = true | |
| 1231 | CreateSound("649634100", Head, 10, 0.5)
| |
| 1232 | for i = 1, 3 do | |
| 1233 | for i = 0, 0.7, 0.1 / Animation_Speed do | |
| 1234 | Swait() | |
| 1235 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1236 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(15)), 0.5 / Animation_Speed) | |
| 1237 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(145)) * ANGLES(RAD(0), RAD(90), RAD(0)) * RIGHTSHOULDERC0, 0.5) | |
| 1238 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-145)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * LEFTSHOULDERC0, 0.5) | |
| 1239 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1240 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1241 | end | |
| 1242 | for i = 0, 0.7, 0.1 / Animation_Speed do | |
| 1243 | Swait() | |
| 1244 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1245 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(15 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(-15)), 0.5 / Animation_Speed) | |
| 1246 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(145)) * ANGLES(RAD(0), RAD(90), RAD(0)) * RIGHTSHOULDERC0, 0.5) | |
| 1247 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5, 0) * ANGLES(RAD(0), RAD(0), RAD(-145)) * ANGLES(RAD(0), RAD(-90), RAD(0)) * LEFTSHOULDERC0, 0.5) | |
| 1248 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1249 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.25 / Animation_Speed) | |
| 1250 | end | |
| 1251 | end | |
| 1252 | ATTACK = false | |
| 1253 | Rooted = false | |
| 1254 | end | |
| 1255 | function MouseDown(Mouse) | |
| 1256 | if ATTACK == false then | |
| 1257 | end | |
| 1258 | end | |
| 1259 | function MouseUp(Mouse) | |
| 1260 | HOLD = false | |
| 1261 | end | |
| 1262 | function KeyDown(Key) | |
| 1263 | KEYHOLD = true | |
| 1264 | if Key == "z" and ATTACK == false then | |
| 1265 | BanishingBullet() | |
| 1266 | end | |
| 1267 | if Key == "c" and ATTACK == false then | |
| 1268 | BanishingRampage() | |
| 1269 | end | |
| 1270 | if Key == "q" and ATTACK == false then | |
| 1271 | WarpVector() | |
| 1272 | end | |
| 1273 | if Key == "v" and ATTACK == false then | |
| 1274 | SpectralBanishing() | |
| 1275 | end | |
| 1276 | if Key == "x" and ATTACK == false then | |
| 1277 | chatfunc("I will show you mercy.", 2)
| |
| 1278 | Delete:ClearAllChildren() | |
| 1279 | end | |
| 1280 | if Key == "t" and ATTACK == false then | |
| 1281 | Taunt() | |
| 1282 | end | |
| 1283 | end | |
| 1284 | function KeyUp(Key) | |
| 1285 | KEYHOLD = false | |
| 1286 | end | |
| 1287 | Mouse.Button1Down:connect(function(NEWKEY) | |
| 1288 | MouseDown(NEWKEY) | |
| 1289 | end) | |
| 1290 | Mouse.Button1Up:connect(function(NEWKEY) | |
| 1291 | MouseUp(NEWKEY) | |
| 1292 | end) | |
| 1293 | Mouse.KeyDown:connect(function(NEWKEY) | |
| 1294 | KeyDown(NEWKEY) | |
| 1295 | end) | |
| 1296 | Mouse.KeyUp:connect(function(NEWKEY) | |
| 1297 | KeyUp(NEWKEY) | |
| 1298 | end) | |
| 1299 | function unanchor() | |
| 1300 | if UNANCHOR == true then | |
| 1301 | g = Character:GetChildren() | |
| 1302 | for i = 1, #g do | |
| 1303 | if g[i].ClassName == "Part" then | |
| 1304 | g[i].Anchored = false | |
| 1305 | end | |
| 1306 | end | |
| 1307 | end | |
| 1308 | end | |
| 1309 | Humanoid.Changed:connect(function(Jump) | |
| 1310 | if Jump == "Jump" and Disable_Jump == true then | |
| 1311 | Humanoid.Jump = false | |
| 1312 | end | |
| 1313 | end) | |
| 1314 | chatfunc("Ahh yeah my brother.... GK Gun with intro version is dumb", 3)
| |
| 1315 | local BOLT | |
| 1316 | local FF = IT("ForceField", Character)
| |
| 1317 | FF.Visible = false | |
| 1318 | while true do | |
| 1319 | Swait() | |
| 1320 | if BOLT ~= nil then | |
| 1321 | BOLT:remove() | |
| 1322 | end | |
| 1323 | ANIMATE.Parent = nil | |
| 1324 | local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION) | |
| 1325 | IDLEANIMATION:Play() | |
| 1326 | SINE = SINE + CHANGE | |
| 1327 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
| 1328 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
| 1329 | local LV = Torso.CFrame:pointToObjectSpace(Torso.Velocity - Torso.Position) | |
| 1330 | local HITFLOOR = Raycast(RootPart.Position, CF(RootPart.Position, RootPart.Position + VT(0, -1, 0)).lookVector, 4 * Player_Size, Character) | |
| 1331 | local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16) | |
| 1332 | if ANIM == "Walk" and TORSOVELOCITY > 1 then | |
| 1333 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, -0.1 * COS(SINE / (WALKSPEEDVALUE / 2)) * Player_Size) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
| 1334 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(2.5 * SIN(SINE / (WALKSPEEDVALUE / 2))), RAD(0), RAD(0)), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
| 1335 | RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 0.875 * Player_Size - 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, -0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
| 1336 | LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 0.875 * Player_Size + 0.125 * SIN(SINE / WALKSPEEDVALUE) * Player_Size, 0.125 * COS(SINE / WALKSPEEDVALUE) * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(60 * COS(SINE / WALKSPEEDVALUE))), 0.2 * (Humanoid.WalkSpeed / 16) / Animation_Speed) | |
| 1337 | elseif ANIM ~= "Walk" or TORSOVELOCITY < 1 then | |
| 1338 | RootJoint.C1 = Clerp(RootJoint.C1, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1339 | Neck.C1 = Clerp(Neck.C1, CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * ANGLES(RAD(-90), RAD(0), RAD(180)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1340 | RightHip.C1 = Clerp(RightHip.C1, CF(0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1341 | LeftHip.C1 = Clerp(LeftHip.C1, CF(-0.5 * Player_Size, 1 * Player_Size, 0 * Player_Size) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1342 | end | |
| 1343 | if TORSOVERTICALVELOCITY > 1 and HITFLOOR == nil then | |
| 1344 | ANIM = "Jump" | |
| 1345 | if ATTACK == false then | |
| 1346 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1347 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0 * Player_Size, 0) * ANGLES(RAD(-20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1348 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(25), RAD(0), RAD(25)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1349 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1350 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.3) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(-20)), 0.2 / Animation_Speed) | |
| 1351 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, -0.3) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-5), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
| 1352 | end | |
| 1353 | elseif TORSOVERTICALVELOCITY < -1 and HITFLOOR == nil then | |
| 1354 | ANIM = "Fall" | |
| 1355 | if ATTACK == false then | |
| 1356 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1357 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(20), RAD(0), RAD(0)), 0.2 / Animation_Speed) | |
| 1358 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(55), RAD(0), RAD(55)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1359 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1360 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(20)), 0.2 / Animation_Speed) | |
| 1361 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(10)), 0.2 / Animation_Speed) | |
| 1362 | end | |
| 1363 | elseif TORSOVELOCITY < 1 and HITFLOOR ~= nil then | |
| 1364 | ANIM = "Idle" | |
| 1365 | if ATTACK == false then | |
| 1366 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1367 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1368 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(45), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1369 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1370 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1371 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1 - 0.05 * COS(SINE / 12), -0.01) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(-8), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1372 | end | |
| 1373 | elseif TORSOVELOCITY > 1 and HITFLOOR ~= nil then | |
| 1374 | ANIM = "Walk" | |
| 1375 | WALK = WALK + 1 / Animation_Speed | |
| 1376 | if WALK >= 15 - 5 * (Humanoid.WalkSpeed / 16 / Player_Size) then | |
| 1377 | WALK = 0 | |
| 1378 | if WALKINGANIM == true then | |
| 1379 | WALKINGANIM = false | |
| 1380 | elseif WALKINGANIM == false then | |
| 1381 | WALKINGANIM = true | |
| 1382 | end | |
| 1383 | end | |
| 1384 | if ATTACK == false then | |
| 1385 | RootJoint.C0 = Clerp(RootJoint.C0, ROOTC0 * CF(0, 0, 0 + 0.05 * COS(SINE / 12)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1386 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0 * Player_Size, 0 * Player_Size, 0) * ANGLES(RAD(0 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1387 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5, 0) * ANGLES(RAD(45), RAD(0), RAD(45)) * RIGHTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1388 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.6, 0) * ANGLES(RAD(-45), RAD(0), RAD(45)) * LEFTSHOULDERC0, 0.15 / Animation_Speed) | |
| 1389 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1390 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -1, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) * ANGLES(RAD(0), RAD(0), RAD(0)), 0.15 / Animation_Speed) | |
| 1391 | end | |
| 1392 | end | |
| 1393 | if #Effects2 > 0 then | |
| 1394 | for e = 1, #Effects2 do | |
| 1395 | if Effects2[e] ~= nil then | |
| 1396 | local Thing = Effects2[e] | |
| 1397 | if Thing ~= nil then | |
| 1398 | local Part = Thing[1] | |
| 1399 | local Mode = Thing[2] | |
| 1400 | local Delay = Thing[3] | |
| 1401 | local IncX = Thing[4] | |
| 1402 | local IncY = Thing[5] | |
| 1403 | local IncZ = Thing[6] | |
| 1404 | local Part2 = Thing[8] | |
| 1405 | if Thing[1].Transparency <= 1 then | |
| 1406 | if Thing[2] == "Block1" then | |
| 1407 | Thing[1].CFrame = Thing[1].CFrame | |
| 1408 | Mesh = Thing[1].Mesh | |
| 1409 | Mesh.Scale = Mesh.Scale + VT(Thing[4], Thing[5], Thing[6]) | |
| 1410 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1411 | elseif Thing[2] == "Cylinder" then | |
| 1412 | Mesh = Thing[1].Mesh | |
| 1413 | Mesh.Scale = Mesh.Scale + VT(Thing[4], Thing[5], Thing[6]) | |
| 1414 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1415 | elseif Thing[2] == "Blood" then | |
| 1416 | Mesh = Thing[7] | |
| 1417 | Thing[1].CFrame = Thing[1].CFrame * CF(0, 0.5, 0) | |
| 1418 | Mesh.Scale = Mesh.Scale + VT(Thing[4], Thing[5], Thing[6]) | |
| 1419 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1420 | elseif Thing[2] == "Elec" then | |
| 1421 | Mesh = Thing[1].Mesh | |
| 1422 | Mesh.Scale = Mesh.Scale + VT(Thing[7], Thing[8], Thing[9]) | |
| 1423 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1424 | elseif Thing[2] == "Disappear" then | |
| 1425 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1426 | end | |
| 1427 | else | |
| 1428 | Part.Parent = nil | |
| 1429 | table.remove(Effects2, e) | |
| 1430 | end | |
| 1431 | end | |
| 1432 | end | |
| 1433 | end | |
| 1434 | end | |
| 1435 | unanchor() | |
| 1436 | Humanoid.MaxHealth = "inf" | |
| 1437 | Humanoid.Health = "inf" | |
| 1438 | if Rooted == false then | |
| 1439 | Disable_Jump = false | |
| 1440 | Humanoid.WalkSpeed = Speed | |
| 1441 | elseif Rooted == true then | |
| 1442 | Disable_Jump = true | |
| 1443 | Humanoid.WalkSpeed = 0 | |
| 1444 | end | |
| 1445 | if VALUE1 == true then | |
| 1446 | local RayData = Zap({
| |
| 1447 | SegmentLength = 0.6, | |
| 1448 | Offset = 0.3, | |
| 1449 | Size = 0.05, | |
| 1450 | MaxRange = 1.5, | |
| 1451 | StartPosition = GunPoint.Position, | |
| 1452 | TargetPosition = RightArm.Position, | |
| 1453 | Character = workspace, | |
| 1454 | Color = "Really red", | |
| 1455 | Individual = true | |
| 1456 | }) | |
| 1457 | BOLT = RayData.LightningModel | |
| 1458 | MagicSphere(VT(0.5, 0.5, 0.5), 15, GunPoint.CFrame, "Really red", VT(-0.03333333333333333, -0.03333333333333333, -0.03333333333333333)) | |
| 1459 | SKILL1TEXT.TextTransparency = 0 | |
| 1460 | SKILL2TEXT.TextTransparency = 0 | |
| 1461 | SKILL3TEXT.TextTransparency = 0 | |
| 1462 | SKILL4TEXT.TextTransparency = 0 | |
| 1463 | SKILL5TEXT.TextTransparency = 0 | |
| 1464 | elseif VALUE1 == false then | |
| 1465 | SKILL1TEXT.TextTransparency = 1 | |
| 1466 | SKILL2TEXT.TextTransparency = 1 | |
| 1467 | SKILL3TEXT.TextTransparency = 1 | |
| 1468 | SKILL4TEXT.TextTransparency = 1 | |
| 1469 | SKILL5TEXT.TextTransparency = 1 | |
| 1470 | end | |
| 1471 | local MATHS = {"0", "1"}
| |
| 1472 | Humanoid.Name = MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] .. MATHS[MRANDOM(1, #MATHS)] | |
| 1473 | Humanoid.PlatformStand = false | |
| 1474 | local GAME = game.Players:GetChildren() | |
| 1475 | for PLAYER = 1, #GAME do | |
| 1476 | local PLAY = GAME[PLAYER] | |
| 1477 | if PLAY.Character ~= nil and Delete:FindFirstChild(PLAY.Name) then | |
| 1478 | PLAY.Character:remove() | |
| 1479 | end | |
| 1480 | end | |
| 1481 | end | |
| 1482 | --[[Nocturna_A._Alteriano_Night.Owl.Inc]]-- | |
| 1483 | wait(1 / 60) | |
| 1484 | Effects = { }
| |
| 1485 | local Player = owner | |
| 1486 | local Character = Player.Character | |
| 1487 | local Humanoid = Character.Humanoid | |
| 1488 | local m = Instance.new('Model', Character)
| |
| 1489 | m.Name = "WeaponModel" | |
| 1490 | local LeftArm = Character["Left Arm"] | |
| 1491 | local RightArm = Character["Right Arm"] | |
| 1492 | local LeftLeg = Character["Left Leg"] | |
| 1493 | local RightLeg = Character["Right Leg"] | |
| 1494 | local Head = Character.Head | |
| 1495 | local Torso = Character.Torso | |
| 1496 | local cam = game.Workspace.CurrentCamera | |
| 1497 | local RootPart = Character.HumanoidRootPart | |
| 1498 | local RootJoint = RootPart.RootJoint | |
| 1499 | local equipped = false | |
| 1500 | local attack = false | |
| 1501 | local Anim = 'Idle' | |
| 1502 | local idle = 0 | |
| 1503 | local attacktype = 1 | |
| 1504 | local Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude | |
| 1505 | local velocity = RootPart.Velocity.y | |
| 1506 | local sine = 0 | |
| 1507 | local change = 1 | |
| 1508 | local grabbed = false | |
| 1509 | local cn = CFrame.new | |
| 1510 | local mr = math.rad | |
| 1511 | local angles = CFrame.Angles | |
| 1512 | local ud = UDim2.new | |
| 1513 | local c3 = Color3.new | |
| 1514 | ||
| 1515 | Humanoid.Animator.Parent = nil | |
| 1516 | Character.Animate.Parent = nil | |
| 1517 | ||
| 1518 | local newMotor = function(part0, part1, c0, c1) | |
| 1519 | local w = Instance.new('Motor', part0)
| |
| 1520 | w.Part0 = part0 | |
| 1521 | w.Part1 = part1 | |
| 1522 | w.C0 = c0 | |
| 1523 | w.C1 = c1 | |
| 1524 | return w | |
| 1525 | end | |
| 1526 | ||
| 1527 | function clerp(a, b, t) | |
| 1528 | return a:lerp(b, t) | |
| 1529 | end | |
| 1530 | ||
| 1531 | RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14) | |
| 1532 | NeckCF = CFrame.new(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
| 1533 | ||
| 1534 | local RW = newMotor(Torso, RightArm, CFrame.new(1.5, 0, 0), CFrame.new(0, 0, 0)) | |
| 1535 | local LW = newMotor(Torso, LeftArm, CFrame.new(-1.5, 0, 0), CFrame.new(0, 0, 0)) | |
| 1536 | local RH = newMotor(Torso, RightLeg, CFrame.new(.5, -2, 0), CFrame.new(0, 0, 0)) | |
| 1537 | local LH = newMotor(Torso, LeftLeg, CFrame.new(-.5, -2, 0), CFrame.new(0, 0, 0)) | |
| 1538 | RootJoint.C1 = CFrame.new(0, 0, 0) | |
| 1539 | RootJoint.C0 = CFrame.new(0, 0, 0) | |
| 1540 | Torso.Neck.C1 = CFrame.new(0, 0, 0) | |
| 1541 | Torso.Neck.C0 = CFrame.new(0, 1.5, 0) | |
| 1542 | ||
| 1543 | local rarmc1 = RW.C1 | |
| 1544 | local larmc1 = LW.C1 | |
| 1545 | local rlegc1 = RH.C1 | |
| 1546 | local llegc1 = LH.C1 | |
| 1547 | ||
| 1548 | local resetc1 = false | |
| 1549 | ||
| 1550 | function PlayAnimationFromTable(table, speed, bool) | |
| 1551 | RootJoint.C0 = clerp(RootJoint.C0, table[1], speed) | |
| 1552 | Torso.Neck.C0 = clerp(Torso.Neck.C0, table[2], speed) | |
| 1553 | RW.C0 = clerp(RW.C0, table[3], speed) | |
| 1554 | LW.C0 = clerp(LW.C0, table[4], speed) | |
| 1555 | RH.C0 = clerp(RH.C0, table[5], speed) | |
| 1556 | LH.C0 = clerp(LH.C0, table[6], speed) | |
| 1557 | if bool == true then | |
| 1558 | if resetc1 == false then | |
| 1559 | resetc1 = true | |
| 1560 | RootJoint.C1 = RootJoint.C1 | |
| 1561 | Torso.Neck.C1 = Torso.Neck.C1 | |
| 1562 | RW.C1 = rarmc1 | |
| 1563 | LW.C1 = larmc1 | |
| 1564 | RH.C1 = rlegc1 | |
| 1565 | LH.C1 = llegc1 | |
| 1566 | end | |
| 1567 | end | |
| 1568 | end | |
| 1569 | ||
| 1570 | --[[Credits to SazErenos for his Artificial Heartbeat]]-- | |
| 1571 | ||
| 1572 | ArtificialHB = Instance.new("BindableEvent", script)
| |
| 1573 | ArtificialHB.Name = "Heartbeat" | |
| 1574 | ||
| 1575 | script:WaitForChild("Heartbeat")
| |
| 1576 | ||
| 1577 | frame = 1 / 30 | |
| 1578 | tf = 0 | |
| 1579 | allowframeloss = false | |
| 1580 | tossremainder = false | |
| 1581 | lastframe = tick() | |
| 1582 | script.Heartbeat:Fire() | |
| 1583 | ||
| 1584 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 1585 | tf = tf + s | |
| 1586 | if tf >= frame then | |
| 1587 | if allowframeloss then | |
| 1588 | script.Heartbeat:Fire() | |
| 1589 | lastframe = tick() | |
| 1590 | else | |
| 1591 | for i = 1, math.floor(tf / frame) do | |
| 1592 | script.Heartbeat:Fire() | |
| 1593 | end | |
| 1594 | lastframe = tick() | |
| 1595 | end | |
| 1596 | if tossremainder then | |
| 1597 | tf = 0 | |
| 1598 | else | |
| 1599 | tf = tf - frame * math.floor(tf / frame) | |
| 1600 | end | |
| 1601 | end | |
| 1602 | end) | |
| 1603 | ||
| 1604 | function swait(num) | |
| 1605 | if num == 0 or num == nil then | |
| 1606 | ArtificialHB.Event:wait() | |
| 1607 | else | |
| 1608 | for i = 0, num do | |
| 1609 | ArtificialHB.Event:wait() | |
| 1610 | end | |
| 1611 | end | |
| 1612 | end | |
| 1613 | ||
| 1614 | local RbxUtility = LoadLibrary("RbxUtility")
| |
| 1615 | local Create = RbxUtility.Create | |
| 1616 | ||
| 1617 | function RemoveOutlines(part) | |
| 1618 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
| 1619 | end | |
| 1620 | ||
| 1621 | CFuncs = {
| |
| 1622 | ["Part"] = {
| |
| 1623 | Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
| 1624 | local Part = Create("Part"){
| |
| 1625 | Parent = Parent, | |
| 1626 | Reflectance = Reflectance, | |
| 1627 | Transparency = Transparency, | |
| 1628 | CanCollide = false, | |
| 1629 | Locked = true, | |
| 1630 | BrickColor = BrickColor.new(tostring(BColor)), | |
| 1631 | Name = Name, | |
| 1632 | Size = Size, | |
| 1633 | Material = Material, | |
| 1634 | } | |
| 1635 | RemoveOutlines(Part) | |
| 1636 | return Part | |
| 1637 | end; | |
| 1638 | }; | |
| 1639 | ||
| 1640 | ["Mesh"] = {
| |
| 1641 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 1642 | local Msh = Create(Mesh){
| |
| 1643 | Parent = Part, | |
| 1644 | Offset = OffSet, | |
| 1645 | Scale = Scale, | |
| 1646 | } | |
| 1647 | if Mesh == "SpecialMesh" then | |
| 1648 | Msh.MeshType = MeshType | |
| 1649 | Msh.MeshId = MeshId | |
| 1650 | end | |
| 1651 | return Msh | |
| 1652 | end; | |
| 1653 | }; | |
| 1654 | ||
| 1655 | ["Mesh"] = {
| |
| 1656 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 1657 | local Msh = Create(Mesh){
| |
| 1658 | Parent = Part, | |
| 1659 | Offset = OffSet, | |
| 1660 | Scale = Scale, | |
| 1661 | } | |
| 1662 | if Mesh == "SpecialMesh" then | |
| 1663 | Msh.MeshType = MeshType | |
| 1664 | Msh.MeshId = MeshId | |
| 1665 | end | |
| 1666 | return Msh | |
| 1667 | end; | |
| 1668 | }; | |
| 1669 | ||
| 1670 | ["Weld"] = {
| |
| 1671 | Create = function(Parent, Part0, Part1, C0, C1) | |
| 1672 | local Weld = Create("Weld"){
| |
| 1673 | Parent = Parent, | |
| 1674 | Part0 = Part0, | |
| 1675 | Part1 = Part1, | |
| 1676 | C0 = C0, | |
| 1677 | C1 = C1, | |
| 1678 | } | |
| 1679 | return Weld | |
| 1680 | end; | |
| 1681 | }; | |
| 1682 | ||
| 1683 | ["Sound"] = {
| |
| 1684 | Create = function(id, par, vol, pit) | |
| 1685 | coroutine.resume(coroutine.create(function() | |
| 1686 | local S = Create("Sound"){
| |
| 1687 | Volume = vol, | |
| 1688 | Pitch = pit or 1, | |
| 1689 | SoundId = id, | |
| 1690 | Parent = par or workspace, | |
| 1691 | } | |
| 1692 | Instance.new("DistortionSoundEffect", S).Level = 1
| |
| 1693 | wait() | |
| 1694 | S:play() | |
| 1695 | game:GetService("Debris"):AddItem(S, 10)
| |
| 1696 | end)) | |
| 1697 | end; | |
| 1698 | }; | |
| 1699 | ||
| 1700 | ["ParticleEmitter"] = {
| |
| 1701 | Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread) | |
| 1702 | local fp = Create("ParticleEmitter"){
| |
| 1703 | Parent = Parent, | |
| 1704 | Color = ColorSequence.new(Color1, Color2), | |
| 1705 | LightEmission = LightEmission, | |
| 1706 | Size = Size, | |
| 1707 | Texture = Texture, | |
| 1708 | Transparency = Transparency, | |
| 1709 | ZOffset = ZOffset, | |
| 1710 | Acceleration = Accel, | |
| 1711 | Drag = Drag, | |
| 1712 | LockedToPart = LockedToPart, | |
| 1713 | VelocityInheritance = VelocityInheritance, | |
| 1714 | EmissionDirection = EmissionDirection, | |
| 1715 | Enabled = Enabled, | |
| 1716 | Lifetime = LifeTime, | |
| 1717 | Rate = Rate, | |
| 1718 | Rotation = Rotation, | |
| 1719 | RotSpeed = RotSpeed, | |
| 1720 | Speed = Speed, | |
| 1721 | VelocitySpread = VelocitySpread, | |
| 1722 | } | |
| 1723 | return fp | |
| 1724 | end; | |
| 1725 | }; | |
| 1726 | } | |
| 1727 | ||
| 1728 | function rayCast(Position, Direction, Range, Ignore) | |
| 1729 | return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
| |
| 1730 | end | |
| 1731 | ||
| 1732 | local function GetNearest(obj, distance) | |
| 1733 | local last, lastx = distance + 1 | |
| 1734 | for i, v in pairs(workspace:GetChildren()) do | |
| 1735 | if v:IsA'Model' and v ~= Character and v:findFirstChild('Humanoid') and v:findFirstChild('Torso') and v:findFirstChild('Humanoid').Health > 0 then
| |
| 1736 | local t = v.Torso | |
| 1737 | local dist = (t.Position - obj.Position).magnitude | |
| 1738 | if dist <= distance then | |
| 1739 | if dist < last then | |
| 1740 | last = dist | |
| 1741 | lastx = v | |
| 1742 | end | |
| 1743 | end | |
| 1744 | end | |
| 1745 | end | |
| 1746 | return lastx | |
| 1747 | end | |
| 1748 | ||
| 1749 | --[[ Credits to Kert109 (Ninja_Deer) for the Damage function. Fenrier for the Magnitude Damage ]]-- | |
| 1750 | ||
| 1751 | function Damage(hit, damage, cooldown, Color1, Color2, HSound, HPitch) | |
| 1752 | for i, v in pairs(hit:GetChildren()) do | |
| 1753 | if v:IsA("Humanoid") and hit.Name ~= Character.Name then
| |
| 1754 | local find = v:FindFirstChild("DebounceHit")
| |
| 1755 | if not find then | |
| 1756 | if v.Parent:findFirstChild("Head") then
| |
| 1757 | local BillG = Create("BillboardGui"){
| |
| 1758 | Parent = v.Parent.Head, | |
| 1759 | Size = UDim2.new(1, 0, 1, 0), | |
| 1760 | Adornee = v.Parent.Head, | |
| 1761 | StudsOffset = Vector3.new(math.random(-3, 3), math.random(3, 5), math.random(-3, 3)), | |
| 1762 | } | |
| 1763 | local TL = Create("TextLabel"){
| |
| 1764 | Parent = BillG, | |
| 1765 | Size = UDim2.new(3, 3, 3, 3), | |
| 1766 | BackgroundTransparency = 1, | |
| 1767 | Text = tostring(damage).."-", | |
| 1768 | TextColor3 = Color1.Color, | |
| 1769 | TextStrokeColor3 = Color2.Color, | |
| 1770 | TextStrokeTransparency = 0, | |
| 1771 | TextXAlignment = Enum.TextXAlignment.Center, | |
| 1772 | TextYAlignment = Enum.TextYAlignment.Center, | |
| 1773 | FontSize = Enum.FontSize.Size18, | |
| 1774 | Font = "ArialBold", | |
| 1775 | } | |
| 1776 | coroutine.resume(coroutine.create(function() | |
| 1777 | swait(1) | |
| 1778 | for i = 0, 1, .1 do | |
| 1779 | swait(.1) | |
| 1780 | BillG.StudsOffset = BillG.StudsOffset + Vector3.new(0, .1, 0) | |
| 1781 | end | |
| 1782 | BillG:Destroy() | |
| 1783 | end)) | |
| 1784 | end | |
| 1785 | v.Health = v.Health - damage | |
| 1786 | local bool = Create("BoolValue"){
| |
| 1787 | Parent = v, | |
| 1788 | Name = "DebounceHit", | |
| 1789 | } | |
| 1790 | if HSound ~= nil and HPitch ~= nil then | |
| 1791 | CFuncs["Sound"].Create(HSound, hit, 1, HPitch) | |
| 1792 | end | |
| 1793 | game:GetService("Debris"):AddItem(bool, cooldown)
| |
| 1794 | end | |
| 1795 | end | |
| 1796 | end | |
| 1797 | end | |
| 1798 | ||
| 1799 | function MagnitudeDamage(Part, magni, mindam, maxdam, Color1, Color2, HSound, HPitch) | |
| 1800 | for _, c in pairs(workspace:children()) do | |
| 1801 | local hum = c:findFirstChild("Humanoid")
| |
| 1802 | if hum ~= nil then | |
| 1803 | local head = c:findFirstChild("Torso")
| |
| 1804 | if head ~= nil then | |
| 1805 | local targ = head.Position - Part.Position | |
| 1806 | local mag = targ.magnitude | |
| 1807 | if mag <= magni and c.Name ~= Player.Name then | |
| 1808 | Damage(head.Parent, math.random(mindam, maxdam), 0.5, Color1, Color2, HSound, HPitch) | |
| 1809 | end | |
| 1810 | end | |
| 1811 | end | |
| 1812 | end | |
| 1813 | end | |
| 1814 | ||
| 1815 | Handle = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "Handle", Vector3.new(0.399999946, 0.899999976, 0.400000095)) | |
| 1816 | HandleWeld = CFuncs["Weld"].Create(m, Character["Right Arm"], Handle, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.199958801, -0.0500774384, -1.09998882, -1, 0, 0, 0, 0, -1, -0, -1, -0)) | |
| 1817 | FakeHandle = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "FakeHandle", Vector3.new(0.399999946, 0.899999976, 0.400000095)) | |
| 1818 | FakeHandleWeld = CFuncs["Weld"].Create(m, Handle, FakeHandle, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(-0.199996948, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1)) | |
| 1819 | Barrel = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 1, "Medium stone grey", "Barrel", Vector3.new(0.399999946, 0.399999976, 0.400000095)) | |
| 1820 | BarrelWeld = CFuncs["Weld"].Create(m, FakeHandle, Barrel, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0, -0.749999046, -1.50000024, 1, 0, 0, 0, 1, 0, 0, 0, 1)) | |
| 1821 | Part = CFuncs["Part"].Create(m, Enum.Material.SmoothPlastic, 0, 0, "Medium stone grey", "Part", Vector3.new(0.399999946, 0.299999952, 0.400000095)) | |
| 1822 | PartWeld = CFuncs["Weld"].Create(m, FakeHandle, Part, CFrame.new(0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1), CFrame.new(0, -0.300000191, -0.400000095, 1, 0, 0, 0, 1, 0, 0, 0, 1)) | |
| 1823 | CFuncs["Mesh"].Create("SpecialMesh", Part, Enum.MeshType.FileMesh, "rbxassetid://435840330", Vector3.new(0, 0, 0), Vector3.new(0.00200000009, 0.00200000009, 0.00200000009))
| |
| 1824 | Part.Mesh.TextureId = "rbxassetid://435840335" | |
| 1825 | ||
| 1826 | EffectModel = Instance.new("Model", Character)
| |
| 1827 | EffectModel.Name = "Effects" | |
| 1828 | ||
| 1829 | Effects = {
| |
| 1830 | ["Block"] = {
| |
| 1831 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type) | |
| 1832 | local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 1833 | prt.Anchored = true | |
| 1834 | prt.CFrame = cframe | |
| 1835 | local msh = CFuncs["Mesh"].Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1836 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 1837 | if Type == 1 or Type == nil then | |
| 1838 | table.insert(Effects, {
| |
| 1839 | prt, | |
| 1840 | "Block1", | |
| 1841 | delay, | |
| 1842 | x3, | |
| 1843 | y3, | |
| 1844 | z3, | |
| 1845 | msh | |
| 1846 | }) | |
| 1847 | elseif Type == 2 then | |
| 1848 | table.insert(Effects, {
| |
| 1849 | prt, | |
| 1850 | "Block2", | |
| 1851 | delay, | |
| 1852 | x3, | |
| 1853 | y3, | |
| 1854 | z3, | |
| 1855 | msh | |
| 1856 | }) | |
| 1857 | end | |
| 1858 | end; | |
| 1859 | }; | |
| 1860 | ||
| 1861 | ["Cylinder"] = {
| |
| 1862 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 1863 | local prt = CFuncs["Part"].Create(workspace, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.2, 0.2, 0.2)) | |
| 1864 | prt.Anchored = true | |
| 1865 | prt.CFrame = cframe | |
| 1866 | local msh = CFuncs["Mesh"].Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1867 | game:GetService("Debris"):AddItem(prt, 2)
| |
| 1868 | Effects[#Effects + 1] = {
| |
| 1869 | prt, | |
| 1870 | "Cylinder", | |
| 1871 | delay, | |
| 1872 | x3, | |
| 1873 | y3, | |
| 1874 | z3 | |
| 1875 | } | |
| 1876 | end; | |
| 1877 | }; | |
| 1878 | ||
| 1879 | ["Sphere"] = {
| |
| 1880 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 1881 | local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 1882 | prt.Anchored = true | |
| 1883 | prt.CFrame = cframe | |
| 1884 | local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1885 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 1886 | table.insert(Effects, {
| |
| 1887 | prt, | |
| 1888 | "Cylinder", | |
| 1889 | delay, | |
| 1890 | x3, | |
| 1891 | y3, | |
| 1892 | z3, | |
| 1893 | msh | |
| 1894 | }) | |
| 1895 | end; | |
| 1896 | }; | |
| 1897 | ||
| 1898 | ["Elec"] = {
| |
| 1899 | Create = function(cff, x, y, z) | |
| 1900 | local prt = CFuncs["Part"].Create(workspace, "Neon", 0, 0, BrickColor.new("Lime green"), "Part", Vector3.new(1, 1, 1))
| |
| 1901 | prt.Anchored = true | |
| 1902 | prt.CFrame = cff * CFrame.new(math.random(-x, x), math.random(-y, y), math.random(-z, z)) | |
| 1903 | prt.CFrame = CFrame.new(prt.Position) | |
| 1904 | game:GetService("Debris"):AddItem(prt, 2)
| |
| 1905 | local xval = math.random() / 2 | |
| 1906 | local yval = math.random() / 2 | |
| 1907 | local zval = math.random() / 2 | |
| 1908 | local msh = CFuncs["Mesh"].Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(xval, yval, zval))
| |
| 1909 | table.insert(Effects, {
| |
| 1910 | prt, | |
| 1911 | "Elec", | |
| 1912 | 0.1, | |
| 1913 | x, | |
| 1914 | y, | |
| 1915 | z, | |
| 1916 | xval, | |
| 1917 | yval, | |
| 1918 | zval | |
| 1919 | }) | |
| 1920 | end; | |
| 1921 | ||
| 1922 | }; | |
| 1923 | ||
| 1924 | ["Ring"] = {
| |
| 1925 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 1926 | local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 1927 | prt.Anchored = true | |
| 1928 | prt.CFrame = cframe | |
| 1929 | local msh = CFuncs["Mesh"].Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1930 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 1931 | table.insert(Effects, {
| |
| 1932 | prt, | |
| 1933 | "Cylinder", | |
| 1934 | delay, | |
| 1935 | x3, | |
| 1936 | y3, | |
| 1937 | z3, | |
| 1938 | msh | |
| 1939 | }) | |
| 1940 | end; | |
| 1941 | }; | |
| 1942 | ||
| 1943 | ||
| 1944 | ["Wave"] = {
| |
| 1945 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 1946 | local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 1947 | prt.Anchored = true | |
| 1948 | prt.CFrame = cframe | |
| 1949 | local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1950 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 1951 | table.insert(Effects, {
| |
| 1952 | prt, | |
| 1953 | "Cylinder", | |
| 1954 | delay, | |
| 1955 | x3, | |
| 1956 | y3, | |
| 1957 | z3, | |
| 1958 | msh | |
| 1959 | }) | |
| 1960 | end; | |
| 1961 | }; | |
| 1962 | ||
| 1963 | ["Break"] = {
| |
| 1964 | Create = function(brickcolor, cframe, x1, y1, z1) | |
| 1965 | local prt = CFuncs["Part"].Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5)) | |
| 1966 | prt.Anchored = true | |
| 1967 | prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
| 1968 | local msh = CFuncs["Mesh"].Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 1969 | local num = math.random(10, 50) / 1000 | |
| 1970 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 1971 | table.insert(Effects, {
| |
| 1972 | prt, | |
| 1973 | "Shatter", | |
| 1974 | num, | |
| 1975 | prt.CFrame, | |
| 1976 | math.random() - math.random(), | |
| 1977 | 0, | |
| 1978 | math.random(50, 100) / 100 | |
| 1979 | }) | |
| 1980 | end; | |
| 1981 | }; | |
| 1982 | } | |
| 1983 | ||
| 1984 | Shoot2 = function(orgpos) | |
| 1985 | local MouseLook = CFrame.new((orgpos + mouse.Hit.p) / 2, mouse.Hit.p) | |
| 1986 | Effects["Sphere"].Create(BrickColor.new("New Yeller"), CFrame.new(orgpos), 5, 5, 5, 3, 3, 3, 0.1)
| |
| 1987 | table.insert(Effects, {
| |
| 1988 | MouseLook.lookVector, | |
| 1989 | "Shoot2", | |
| 1990 | 50, | |
| 1991 | orgpos, | |
| 1992 | 5, | |
| 1993 | 7, | |
| 1994 | 0, | |
| 1995 | 1, | |
| 1996 | 2 | |
| 1997 | }) | |
| 1998 | end | |
| 1999 | ||
| 2000 | function attackone() | |
| 2001 | attack = true | |
| 2002 | CFuncs["Sound"].Create("rbxassetid://243053454", Torso, .1, 2.8)
| |
| 2003 | for i = 0, 1, 0.025 do | |
| 2004 | swait() | |
| 2005 | PlayAnimationFromTable({
| |
| 2006 | CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2007 | CFrame.new(0, 1.4999907, 3.42726707e-007, 1, 0, 0, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2008 | CFrame.new(0.431798398, 0.400000006, -0.888215482, 0.939692736, 0.342019886, 0, 0, 0, -1, -0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2009 | CFrame.new(-0.559965074, 0.300000012, -0.828456283, 0.939692736, -0.342019886, 0, 0, 0, -1, 0.342019916, 0.939692736, 0) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2010 | CFrame.new(0.599619746, -1.99127948, 0, 0.996194661, -0.087155968, 0, 0.087155968, 0.996194661, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2011 | CFrame.new(-0.599619746, -1.99127901, 0, 0.996194661, 0.087155968, 0, -0.087155968, 0.996194661, 0, -0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2012 | }, .3, false) | |
| 2013 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.3) | |
| 2014 | end | |
| 2015 | CFuncs["Sound"].Create("rbxassetid://203691837", Barrel, .01, .3)
| |
| 2016 | CFuncs["Sound"].Create("rbxassetid://131384028", Barrel, .01, .9)
| |
| 2017 | CFuncs["Sound"].Create("rbxassetid://184718741", Barrel, .05, .9)
| |
| 2018 | Shoot2(Barrel.Position) | |
| 2019 | for i = 0, 1, 0.15 do | |
| 2020 | swait() | |
| 2021 | RootPart.Velocity = RootPart.CFrame.lookVector * -50 | |
| 2022 | PlayAnimationFromTable({
| |
| 2023 | CFrame.new(-0, -0.281125277, 0.157014638, 1, 0, -0, 0, 0.906307876, -0.422617942, 0, 0.422617942, 0.906307876) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2024 | CFrame.new(0, 1.4999938, 1.05202198e-005, 1, 0, -0, 0, 0.965925813, 0.258818924, -0, -0.258818924, 0.965925813) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2025 | CFrame.new(0.406597674, 0.817824185, -0.957423151, 0.939692974, 0.280165672, -0.196174338, -5.36441803e-007, -0.573575616, -0.819152534, -0.34201926, 0.769751906, -0.538984895) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2026 | CFrame.new(-0.506752789, 0.775180221, -0.974653006, 0.939692974, -0.280165732, 0.196174279, 5.36441803e-007, -0.573575556, -0.819152713, 0.34201926, 0.769752145, -0.538984716) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2027 | CFrame.new(0.566868722, -1.61683154, -0.13679418, 0.954536259, -0.174988821, -0.241328761, 0.172366679, 0.984509468, -0.0321052969, 0.243208498, -0.0109513998, 0.969912171) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2028 | CFrame.new(-0.545306504, -1.37044179, -0.679420352, 0.996202111, 0.0754783303, 0.0434113704, -0.0434117466, 0.862729907, -0.503797948, -0.0754781216, 0.49999994, 0.862729967) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2029 | }, .6, false) | |
| 2030 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(-30), math.rad(-20), math.rad(0)), 0.3) | |
| 2031 | end | |
| 2032 | for i = 0, 1, 0.15 do | |
| 2033 | swait() | |
| 2034 | RootPart.Velocity = RootPart.CFrame.lookVector * -100 | |
| 2035 | PlayAnimationFromTable({
| |
| 2036 | CFrame.new(-0, -0.795007467, 0.0831707418, 1, 0, -0, 0, 0.76604414, -0.642788053, 0, 0.642788053, 0.76604414) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2037 | CFrame.new(0, 1.49999774, 1.20103359e-005, 1, 0, -0, 0, 0.965925634, 0.258819878, -0, -0.258819878, 0.965925634) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2038 | CFrame.new(1.70605683, 1.21151328, -0.185158521, 0.893217862, -0.29338178, -0.340718448, -0.340719074, -0.936116338, -0.0871595442, -0.293381065, 0.193941653, -0.936116695) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2039 | CFrame.new(-1.69524968, 1.05172348, -0.252849877, 0.812758088, 0.493294626, 0.309975445, 0.582562625, -0.694268882, -0.422624737, 0.00672781467, 0.524071693, -0.851647615) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2040 | CFrame.new(0.689150453, -1.88461804, -0.0157705098, 0.954536736, -0.174989104, -0.241326213, 0.172367141, 0.984509468, -0.0321044922, 0.243205875, -0.0109517872, 0.969912887) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2041 | CFrame.new(-0.536899447, -1.34506011, -0.583059072, 0.99620223, 0.0226762109, 0.0840658173, -0.043412663, 0.966281295, 0.253803402, -0.0754759163, -0.256489068, 0.963595748) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2042 | }, .2, false) | |
| 2043 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-50), math.rad(0)), 0.3) | |
| 2044 | end | |
| 2045 | for i = 0, 1, 0.05 do | |
| 2046 | swait() | |
| 2047 | RootPart.Velocity = RootPart.CFrame.lookVector * -50 | |
| 2048 | PlayAnimationFromTable({
| |
| 2049 | CFrame.new(-0, -2.09708667, 0.108620644, 1, 0, -0, 0, 0.573575675, -0.819152594, 0, 0.819152594, 0.573575675) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2050 | CFrame.new(0, 1.53697455, -0.422635257, 1, 0, -0, 0, 0.766043842, 0.64278841, -0, -0.64278841, 0.766043842) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2051 | CFrame.new(1.57810855, 0.650130272, 0.33058399, 0.930655897, -0.284022599, -0.230674848, 0.352510452, 0.527023435, 0.773293555, -0.0980618149, -0.800985396, 0.590598404) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2052 | CFrame.new(-1.38994181, 0.87733829, 0.667137444, 0.963715255, 0.08906921, 0.251633942, -0.25866431, 0.0788001418, 0.962747812, 0.0659223944, -0.992903471, 0.0989798903) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2053 | CFrame.new(0.774198592, -1.52057803, -0.607582211, 0.954536974, -0.272207022, -0.121501081, 0.172365844, 0.83655864, -0.520057499, 0.243206039, 0.475471497, 0.845445395) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2054 | CFrame.new(-0.530096769, -1.05517173, -0.660005629, 0.99620223, 0.0226761587, 0.0840661526, -0.0434127897, 0.966280818, 0.253804684, -0.0754762068, -0.256490231, 0.96359539) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2055 | }, .3, false) | |
| 2056 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-60), math.rad(0)), 0.3) | |
| 2057 | end | |
| 2058 | for i = 0, 1, 0.13 do | |
| 2059 | swait() | |
| 2060 | PlayAnimationFromTable({
| |
| 2061 | CFrame.new(-0, -1.01349139, -0.251608461, 1, 0, 0, 0, 0.707105339, 0.707108378, 0, -0.707108378, 0.707105339) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2062 | CFrame.new(0.0127754211, 1.44207788, 0.0749337673, 1, 0, 0, 0, 0.939691544, -0.342023343, 0, 0.342023343, 0.939691544) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2063 | CFrame.new(1.62296665, 0.191783041, -0.192457974, 0.930656254, -0.329096794, 0.159920022, 0.352511466, 0.923570275, -0.150843769, -0.098055169, 0.196757287, 0.975536823) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2064 | CFrame.new(-0.870643735, 0.71258086, -0.942903101, 0.18127799, -0.372358024, -0.910213113, -0.781424284, 0.507405519, -0.363202393, 0.597088516, 0.777103186, -0.19898814) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2065 | CFrame.new(0.214147568, -1.73508716, -0.0895051956, 0.924306214, 0.282332808, -0.256800473, -0.113861978, 0.846218646, 0.520528436, 0.364271581, -0.451887846, 0.814311981) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2066 | CFrame.new(-0.535767198, -0.599929333, -0.996632636, 0.996202111, 0.0754788443, 0.0434101112, -0.0434126705, 0.862728953, -0.503799856, -0.0754773915, 0.500001788, 0.862729192) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2067 | }, .3, false) | |
| 2068 | end | |
| 2069 | attack = false | |
| 2070 | end | |
| 2071 | ||
| 2072 | --[[Attacks]]-- | |
| 2073 | ||
| 2074 | mouse.Button1Down:connect(function() | |
| 2075 | if attack == false and attacktype == 1 then | |
| 2076 | attackone() | |
| 2077 | end | |
| 2078 | end) | |
| 2079 | ||
| 2080 | mouse.KeyDown:connect(function(k) | |
| 2081 | k = k:lower() | |
| 2082 | if attack == false and k == '' then | |
| 2083 | ||
| 2084 | end | |
| 2085 | end) | |
| 2086 | ||
| 2087 | while true do | |
| 2088 | swait() | |
| 2089 | for i, v in pairs(Character:GetChildren()) do | |
| 2090 | if v:IsA("Part") then
| |
| 2091 | v.Material = "SmoothPlastic" | |
| 2092 | elseif v:IsA("Accessory") then
| |
| 2093 | v:WaitForChild("Handle").Material = "SmoothPlastic"
| |
| 2094 | end | |
| 2095 | end | |
| 2096 | Torsovelocity = (RootPart.Velocity * Vector3.new(1, 0, 1)).magnitude | |
| 2097 | velocity = RootPart.Velocity.y | |
| 2098 | sine = sine + change | |
| 2099 | local hit, pos = rayCast(RootPart.Position, (CFrame.new(RootPart.Position, RootPart.Position - Vector3.new(0, 1, 0))).lookVector, 4, Character) | |
| 2100 | if equipped == true or equipped == false then | |
| 2101 | if RootPart.Velocity.y > 1 and hit == nil then | |
| 2102 | Anim = "Jump" | |
| 2103 | if attack == false then | |
| 2104 | PlayAnimationFromTable({
| |
| 2105 | CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2106 | CFrame.new(0, 1.49221826, -0.044082582, 1, 0, 0, 0, 0.984807849, 0.173647985, 0, -0.173647985, 0.984807849) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2107 | CFrame.new(1.66304386, 0.182627335, 0.00782334805, 0.883022726, -0.392632574, 0.257119894, 0.321392894, 0.905103981, 0.2783764, -0.342019886, -0.163176134, 0.925416708) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2108 | CFrame.new(-1.66570556, 0.224230319, 0.110721856, 0.903736115, 0.408218145, -0.128915116, -0.34750703, 0.875426054, 0.33595863, 0.25000003, -0.258819014, 0.933012724) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2109 | CFrame.new(0.499999166, -1.99999452, 4.76837158e-007, 0.984807849, -5.94328526e-007, -0.173648044, 0.0449439958, 0.965925872, 0.254886925, 0.167730987, -0.258819073, 0.951251388) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2110 | CFrame.new(-0.499999404, -1.51703107, -0.129407585, 0.965925753, 6.6929374e-007, 0.258819193, -0.0669879839, 0.965925813, 0.24999994, -0.24999994, -0.258819163, 0.933012724) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2111 | }, .3, false) | |
| 2112 | end | |
| 2113 | elseif RootPart.Velocity.y < -1 and hit == nil then | |
| 2114 | Anim = "Fall" | |
| 2115 | if attack == false then | |
| 2116 | PlayAnimationFromTable({
| |
| 2117 | CFrame.new(-0, -0, -0, 1, 0, 0, 0, 1, 0, 0, 0, 1) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2118 | CFrame.new(0, 1.49221873, -0.0440826714, 1, 0, 0, 0, 0.984807849, 0.173647985, 0, -0.173647985, 0.984807849) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2119 | CFrame.new(1.76076102, 0.406842887, 0.0212866664, 0.695482016, -0.670965135, 0.257119834, 0.611573994, 0.74059701, 0.278376371, -0.377202988, -0.0363579579, 0.925416648) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2120 | CFrame.new(-1.68029141, 0.390803367, 0.155905366, 0.70961535, 0.692695498, -0.128914997, -0.625963271, 0.703777075, 0.335958213, 0.323444158, -0.157705069, 0.933012843) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2121 | CFrame.new(0.693307817, -1.96826017, -0.0605875254, 0.986561239, -0.127662987, -0.101976946, 0.137943029, 0.985269904, 0.101069227, 0.0875720233, -0.113777988, 0.989639223) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2122 | CFrame.new(-0.526552737, -1.81498528, -0.152177691, 0.965925574, 0.0449441113, 0.254888207, -0.066988036, 0.994663239, 0.0784704387, -0.250001162, -0.0928710476, 0.963781357) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2123 | }, .3, false) | |
| 2124 | end | |
| 2125 | elseif Torsovelocity < 1 and hit ~= nil then | |
| 2126 | Anim = "Idle" | |
| 2127 | if attack == false then | |
| 2128 | change = 1 | |
| 2129 | PlayAnimationFromTable({
| |
| 2130 | CFrame.new(1.22602091e-006, -0.219458103, 1.46111324e-006, 0.76604414, 0, 0.642788053, 0, 1, 0, -0.642788053, 0, 0.76604414) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2131 | CFrame.new(0, 1.49999201, 0, 0.707106233, 0, -0.707107306, 0, 1, 0, 0.707107306, 0, 0.707106233) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2132 | CFrame.new(0.571566343, -0.0739164352, -0.639066696, 0.939692855, 0.340718329, -0.0298085809, -0.241844058, 0.600305915, -0.762328327, -0.241844922, 0.723563433, 0.646503866) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2133 | CFrame.new(-0.628383756, -0.12163578, -0.696761668, 0.939692736, -0.342020065, -5.06639481e-007, 0.196173996, 0.538984895, -0.819152653, 0.280166954, 0.769751549, 0.573575616) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2134 | CFrame.new(0.624118924, -1.79798961, 0.0678238794, 0.995454907, -0.0383867361, -0.0871553123, 0.0385330059, 0.999257326, -4.09960694e-006, 0.0870907605, -0.00335427374, 0.996194839) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2135 | CFrame.new(-0.53866595, -1.82180798, 0.00821807235, 0.977763176, 0.0281341001, 0.207816422, -0.0287620034, 0.999586344, -1.4934686e-007, -0.207730502, -0.00597707182, 0.978167892) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2136 | }, .3, false) | |
| 2137 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-20), math.rad(0)), 0.3) | |
| 2138 | end | |
| 2139 | elseif Torsovelocity > 2 and hit ~= nil then | |
| 2140 | Anim = "Walk" | |
| 2141 | if attack == false then | |
| 2142 | change = 3 | |
| 2143 | PlayAnimationFromTable({
| |
| 2144 | CFrame.new(0, -0.0240751095, -0.146390602, 1, 0, 0, 0, 0.965925872, 0.258818984, 0, -0.258818984, 0.965925872) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2145 | CFrame.new(0, 1.49999237, -1.81794167e-006, 1, 0, 0, 0, 0.984807789, -0.173647881, 0, 0.173647881, 0.984807789) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2146 | CFrame.new(0.172261134, 0.427689523, -1.09730911, 0.644483984, 0.748984814, -0.153825179, 0.413525045, -0.510645986, -0.753815472, -0.643146515, 0.422211438, -0.638827145) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2147 | CFrame.new(-1.1922102, 0.363029838, -0.448653877, 0.935289383, -0.110854559, -0.33607316, -0.341521561, -0.531564534, -0.775114357, -0.0927196145, 0.839732468, -0.535025835) * CFrame.new(0, 0, 0) * CFrame.Angles(0, 0, 0), | |
| 2148 | CFrame.new(.5, -1.85 - 0.5 * math.cos(sine / 8) / 2, 0 + 1.8 * math.sin(sine / 8) / 2) * angles(math.rad(-50 * math.sin(sine / 8)), math.rad(0), math.rad(0)), | |
| 2149 | CFrame.new(-.5, -1.85 + 0.5 * math.cos(sine / 8) / 2, 0 - 1.8 * math.sin(sine / 8) / 2) * angles(math.rad(50 * math.sin(sine / 8)), math.rad(0), math.rad(0)), | |
| 2150 | }, .3, false) | |
| 2151 | FakeHandleWeld.C0 = clerp(FakeHandleWeld.C0, CFrame.new(0, 0, 0) * CFrame.Angles(math.rad(0), math.rad(-30), math.rad(0)), 0.3) | |
| 2152 | end | |
| 2153 | end | |
| 2154 | end | |
| 2155 | if 0 < #Effects then | |
| 2156 | for e = 1, #Effects do | |
| 2157 | if Effects[e] ~= nil then | |
| 2158 | local Thing = Effects[e] | |
| 2159 | if Thing ~= nil then | |
| 2160 | local Part = Thing[1] | |
| 2161 | local Mode = Thing[2] | |
| 2162 | local Delay = Thing[3] | |
| 2163 | local IncX = Thing[4] | |
| 2164 | local IncY = Thing[5] | |
| 2165 | local IncZ = Thing[6] | |
| 2166 | if Thing[2] == "Shoot" then | |
| 2167 | local Look = Thing[1] | |
| 2168 | local hit, pos = rayCast(Thing[4], Look, 15, Character) | |
| 2169 | local mag = (Thing[4] - pos).magnitude | |
| 2170 | Thing[9] = Thing[9] + 0.5 | |
| 2171 | Thing[5] = Thing[5] + 0.2 | |
| 2172 | Thing[6] = Thing[6] + 0.2 | |
| 2173 | Effects["Cylinder"].Create(BrickColor.new("New Yeller"), CFrame.new((Thing[4] + pos) / 2, pos) * angles(1.57, 0, 0), Thing[9], mag * 5, Thing[9], -0.2, 0, -0.2, 0.1)
| |
| 2174 | Thing[4] = Thing[4] + Look * 15 | |
| 2175 | Thing[3] = Thing[3] - 1 | |
| 2176 | if hit ~= nil then | |
| 2177 | Thing[3] = 0 | |
| 2178 | ref = CFuncs["Part"].Create(workspace, "Neon", 0, 1, BrickColor.new("Really red"), "Reference", Vector3.new())
| |
| 2179 | ref.Anchored = true | |
| 2180 | ref.CFrame = CFrame.new(pos) | |
| 2181 | Effects["Sphere"].Create(BrickColor.new("New Yeller"), CFrame.new(pos), 5, 5, 5, 1, 1, 1, 0.07)
| |
| 2182 | CFuncs["Sound"].Create("rbxassetid://315748949", ref, 1, 1.1)
| |
| 2183 | game:GetService("Debris"):AddItem(ref, 1)
| |
| 2184 | end | |
| 2185 | if Thing[3] <= 0 then | |
| 2186 | table.remove(Effects, e) | |
| 2187 | end | |
| 2188 | end | |
| 2189 | do | |
| 2190 | if Thing[2] == "Shoot2" then | |
| 2191 | local Look = Thing[1] | |
| 2192 | local hit, pos = rayCast(Thing[4], Look, 3, Character) | |
| 2193 | local mag = (Thing[4] - pos).magnitude | |
| 2194 | Thing[9] = Thing[9] + 0.5 | |
| 2195 | Thing[5] = Thing[5] + 0.2 | |
| 2196 | Thing[6] = Thing[6] + 0.2 | |
| 2197 | Effects["Sphere"].Create(BrickColor.new("New Yeller"), CFrame.new((Thing[4] + pos) / 2, pos), 25, 25, 25, -5, -5, -5, 0.2)
| |
| 2198 | Thing[4] = Thing[4] + Look * 3 | |
| 2199 | Thing[3] = Thing[3] + 5 | |
| 2200 | if hit ~= nil then | |
| 2201 | Thing[3] = 0 | |
| 2202 | ref = CFuncs["Part"].Create(workspace, "Neon", 0, 1, BrickColor.new("Really red"), "Reference", Vector3.new())
| |
| 2203 | ref.Anchored = true | |
| 2204 | ref.CFrame = CFrame.new(pos) | |
| 2205 | Effects["Sphere"].Create(BrickColor.new("New Yeller"), CFrame.new(pos), 25, 25, 25, 5, 5, 5, 0.01)
| |
| 2206 | Effects["Sphere"].Create(BrickColor.new("New Yeller"), CFrame.new(pos), 10, 10, 10, 15, 15, 15, 0.01)
| |
| 2207 | Effects["Block"].Create(BrickColor.new("New Yeller"), CFrame.new(pos), 10, 10, 10, 15, 15, 15, 0.01, 1)
| |
| 2208 | Effects["Wave"].Create(BrickColor.new("New Yeller"), CFrame.new(pos), 2, 2, 2, 3, 3, 3, 0.01)
| |
| 2209 | CFuncs["Sound"].Create("rbxassetid://203691837", ref, 1, .3)
| |
| 2210 | CFuncs["Sound"].Create("rbxassetid://203691885", ref, 1, .9)
| |
| 2211 | CFuncs["Sound"].Create("rbxassetid://184718741", ref, 1, .9)
| |
| 2212 | local e = Instance.new("Explosion", ref)
| |
| 2213 | e.Position = ref.Position | |
| 2214 | e.BlastRadius = 400 | |
| 2215 | e.DestroyJointRadiusPercent = 20 | |
| 2216 | e.Visible = false | |
| 2217 | e.ExplosionType = "CratersAndDebris" | |
| 2218 | game:GetService("Debris"):AddItem(ref, 10)
| |
| 2219 | end | |
| 2220 | if Thing[3] <= 0 then | |
| 2221 | table.remove(Effects, e) | |
| 2222 | end | |
| 2223 | end | |
| 2224 | do | |
| 2225 | do | |
| 2226 | if Thing[2] ~= "Shoot" and Thing[2] ~= "DecreaseStat" and Thing[2] ~= "showDamage" and Thing[2] ~= "Shoot2" then | |
| 2227 | if Thing[1].Transparency <= 1 then | |
| 2228 | if Thing[2] == "Block1" then | |
| 2229 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
| 2230 | Mesh = Thing[7] | |
| 2231 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2232 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2233 | else | |
| 2234 | if Thing[2] == "Block2" then | |
| 2235 | Thing[1].CFrame = Thing[1].CFrame | |
| 2236 | Mesh = Thing[7] | |
| 2237 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2238 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2239 | else | |
| 2240 | if Thing[2] == "Block3" then | |
| 2241 | Thing[8].C0 = CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) * Thing[9] | |
| 2242 | Mesh = Thing[7] | |
| 2243 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2244 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2245 | else | |
| 2246 | if Thing[2] == "Cylinder" then | |
| 2247 | Mesh = Thing[7] | |
| 2248 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2249 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2250 | else | |
| 2251 | if Thing[2] == "Cylinder2" then | |
| 2252 | Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, Thing[8], 0) | |
| 2253 | Mesh = Thing[7] | |
| 2254 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2255 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2256 | else | |
| 2257 | if Thing[2] == "Blood" then | |
| 2258 | Mesh = Thing[7] | |
| 2259 | Thing[1].CFrame = Thing[1].CFrame * CFrame.new(0, 0.5, 0) | |
| 2260 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 2261 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2262 | else | |
| 2263 | if Thing[2] == "Elec" then | |
| 2264 | Mesh = Thing[10] | |
| 2265 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9]) | |
| 2266 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2267 | else | |
| 2268 | if Thing[2] == "Disappear" then | |
| 2269 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 2270 | end | |
| 2271 | end | |
| 2272 | end | |
| 2273 | end | |
| 2274 | end | |
| 2275 | end | |
| 2276 | end | |
| 2277 | end | |
| 2278 | else | |
| 2279 | Part.Parent = nil | |
| 2280 | table.remove(Effects, e) | |
| 2281 | end | |
| 2282 | end | |
| 2283 | end | |
| 2284 | end | |
| 2285 | end | |
| 2286 | end | |
| 2287 | end | |
| 2288 | end | |
| 2289 | end | |
| 2290 | end |