SHOW:
|
|
- or go back to the newest paste.
| 1 | -- This script has convert to FE by who i don't know? | |
| 2 | ||
| 3 | ----------------------------------------------------- | |
| 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,game,owner = owner,game | |
| 6 | local RealPlayer = Player | |
| 7 | do | |
| 8 | print("FE Compatibility code by Mokiros | Showcase by Bacon Hair!")
| |
| 9 | local rp = RealPlayer | |
| 10 | script.Parent = rp.Character | |
| 11 | ||
| 12 | --RemoteEvent for communicating | |
| 13 | local Event = Instance.new("RemoteEvent")
| |
| 14 | Event.Name = "UserInput_Event" | |
| 15 | ||
| 16 | --Fake event to make stuff like Mouse.KeyDown work | |
| 17 | local function fakeEvent() | |
| 18 | local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
| |
| 19 | t.connect = t.Connect | |
| 20 | return t | |
| 21 | end | |
| 22 | ||
| 23 | --Creating fake input objects with fake variables | |
| 24 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
| |
| 25 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
| |
| 26 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
| |
| 27 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
| |
| 28 | end} | |
| 29 | --Merged 2 functions into one by checking amount of arguments | |
| 30 | CAS.UnbindAction = CAS.BindAction | |
| 31 | ||
| 32 | --This function will trigger the events that have been :Connect()'ed | |
| 33 | local function te(self,ev,...) | |
| 34 | local t = m[ev] | |
| 35 | if t and t._fakeEvent then | |
| 36 | for _,f in pairs(t.Functions) do | |
| 37 | f(...) | |
| 38 | end | |
| 39 | end | |
| 40 | end | |
| 41 | m.TrigEvent = te | |
| 42 | UIS.TrigEvent = te | |
| 43 | ||
| 44 | Event.OnServerEvent:Connect(function(plr,io) | |
| 45 | if plr~=rp then return end | |
| 46 | m.Target = io.Target | |
| 47 | m.Hit = io.Hit | |
| 48 | if not io.isMouse then | |
| 49 | local b = io.UserInputState == Enum.UserInputState.Begin | |
| 50 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
| 51 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
| 52 | end | |
| 53 | for _,t in pairs(CAS.Actions) do | |
| 54 | for _,k in pairs(t.Keys) do | |
| 55 | if k==io.KeyCode then | |
| 56 | t.Function(t.Name,io.UserInputState,io) | |
| 57 | end | |
| 58 | end | |
| 59 | end | |
| 60 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
| 61 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
| 62 | end | |
| 63 | end) | |
| 64 | Event.Parent = NLS([==[ | |
| 65 | local Player = game:GetService("Players").LocalPlayer
| |
| 66 | local Event = script:WaitForChild("UserInput_Event")
| |
| 67 | ||
| 68 | local Mouse = Player:GetMouse() | |
| 69 | local UIS = game:GetService("UserInputService")
| |
| 70 | local input = function(io,a) | |
| 71 | if a then return end | |
| 72 | --Since InputObject is a client-side instance, we create and pass table instead | |
| 73 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
| |
| 74 | end | |
| 75 | UIS.InputBegan:Connect(input) | |
| 76 | UIS.InputEnded:Connect(input) | |
| 77 | ||
| 78 | local h,t | |
| 79 | --Give the server mouse data 30 times every second, but only if the values changed | |
| 80 | --If player is not moving their mouse, client won't fire events | |
| 81 | while wait(1/30) do | |
| 82 | if h~=Mouse.Hit or t~=Mouse.Target then | |
| 83 | h,t=Mouse.Hit,Mouse.Target | |
| 84 | Event:FireServer({isMouse=true,Target=t,Hit=h})
| |
| 85 | end | |
| 86 | end]==],Player.Character) | |
| 87 | ||
| 88 | ----Sandboxed game object that allows the usage of client-side methods and services | |
| 89 | --Real game object | |
| 90 | local _rg = game | |
| 91 | ||
| 92 | --Metatable for fake service | |
| 93 | local fsmt = {
| |
| 94 | __index = function(self,k) | |
| 95 | local s = rawget(self,"_RealService") | |
| 96 | if s then return s[k] end | |
| 97 | end, | |
| 98 | __newindex = function(self,k,v) | |
| 99 | local s = rawget(self,"_RealService") | |
| 100 | if s then s[k]=v end | |
| 101 | end, | |
| 102 | __call = function(self,...) | |
| 103 | local s = rawget(self,"_RealService") | |
| 104 | if s then return s(...) end | |
| 105 | end | |
| 106 | } | |
| 107 | local function FakeService(t,RealService) | |
| 108 | t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService | |
| 109 | return setmetatable(t,fsmt) | |
| 110 | end | |
| 111 | ||
| 112 | --Fake game object | |
| 113 | local g = {
| |
| 114 | GetService = function(self,s) | |
| 115 | return self[s] | |
| 116 | end, | |
| 117 | Players = FakeService({
| |
| 118 | LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
| |
| 119 | },"Players"), | |
| 120 | UserInputService = FakeService(UIS,"UserInputService"), | |
| 121 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
| 122 | } | |
| 123 | rawset(g.Players,"localPlayer",g.Players.LocalPlayer) | |
| 124 | g.service = g.GetService | |
| 125 | ||
| 126 | g.RunService = FakeService({
| |
| 127 | RenderStepped = _rg:GetService("RunService").Heartbeat,
| |
| 128 | BindToRenderStep = function(self,name,_,fun) | |
| 129 | ||
| 130 | end, | |
| 131 | UnbindFromRenderStep = function(self,name) | |
| 132 | self._btrs[name]:Disconnect() | |
| 133 | end, | |
| 134 | },"RunService") | |
| 135 | ||
| 136 | setmetatable(g,{
| |
| 137 | __index=function(self,s) | |
| 138 | return _rg:GetService(s) or typeof(_rg[s])=="function" | |
| 139 | and function(_,...)return _rg[s](_rg,...)end or _rg[s] | |
| 140 | end, | |
| 141 | __newindex = fsmt.__newindex, | |
| 142 | __call = fsmt.__call | |
| 143 | }) | |
| 144 | --Changing owner to fake player object to support owner:GetMouse() | |
| 145 | game,owner = g,g.Players.LocalPlayer | |
| 146 | end | |
| 147 | ----------------------- | |
| 148 | --[[ Name : Inked Monster ]]-- | |
| 149 | ------------------------------------------------------- | |
| 150 | --A script By makhail07 | |
| 151 | ||
| 152 | --Discord Creterisk#2958 | |
| 153 | ||
| 154 | --NOTE THIS SCRIPT WAS PURELY MADE FROM MY FUCKING IMAGINATION | |
| 155 | --IF IT HAPPENS TO LOOK LIKE ANOTHER SCRIPT | |
| 156 | --DONT CALL IT A FUCKING BOOTLEG THANK YOU AND ENJOY THE SCRIPT | |
| 157 | --YOU FUCKING SKIDS, | |
| 158 | --For Those who log/decompile this, If you sell or trade this, | |
| 159 | --and I find out who you are, i will take massive action. | |
| 160 | ||
| 161 | ------------------------------------------------------- | |
| 162 | ||
| 163 | local FavIDs = {
| |
| 164 | 340106355, --Nefl Crystals | |
| 165 | 927529620, --Dimension | |
| 166 | 876981900, --Fantasy | |
| 167 | 398987889, --Ordinary Days | |
| 168 | 1117396305, --Oh wait, it's you. | |
| 169 | 885996042, --Action Winter Journey | |
| 170 | 919231299, --Sprawling Idiot Effigy | |
| 171 | 743466274, --Good Day Sunshine | |
| 172 | 727411183, --Knife Fight | |
| 173 | 1402748531, --The Earth Is Counting On You! | |
| 174 | 595230126 --Robot Language | |
| 175 | } | |
| 176 | ||
| 177 | ||
| 178 | ||
| 179 | --The reality of my life isn't real but a Universe -makhail07 | |
| 180 | wait(0.2) | |
| 181 | local plr = game:service'Players'.LocalPlayer | |
| 182 | print('Local User is '..plr.Name)
| |
| 183 | print('Inked Monster Loaded')
| |
| 184 | print('Wat')
| |
| 185 | local char = plr.Character | |
| 186 | local hum = char.Humanoid | |
| 187 | local hed = char.Head | |
| 188 | local root = char.HumanoidRootPart | |
| 189 | local rootj = root.RootJoint | |
| 190 | local tors = char.Torso | |
| 191 | local ra = char["Right Arm"] | |
| 192 | local la = char["Left Arm"] | |
| 193 | local rl = char["Right Leg"] | |
| 194 | local ll = char["Left Leg"] | |
| 195 | local neck = tors["Neck"] | |
| 196 | local mouse = plr:GetMouse() | |
| 197 | local RootCF = CFrame.fromEulerAnglesXYZ(-1.57, 0, 3.14) | |
| 198 | local RHCF = CFrame.fromEulerAnglesXYZ(0, 1.6, 0) | |
| 199 | local LHCF = CFrame.fromEulerAnglesXYZ(0, -1.6, 0) | |
| 200 | local maincolor = BrickColor.new("Institutional white")
| |
| 201 | ------------------------------------------------------- | |
| 202 | --Start Whitelist and Invincibility-- | |
| 203 | ------------------------------------------------------- | |
| 204 | ff = Instance.new("ForceField",char)
| |
| 205 | ff.Visible = false | |
| 206 | hum.Name = "Base" | |
| 207 | hum.MaxHealth = 1.0E298 | |
| 208 | hum.Health = 1.0E298 | |
| 209 | game:GetService("RunService"):BindToRenderStep("Bbae", 0, function()
| |
| 210 | if hum.Health > 0.1 and hum.Health < 1.0E298 then | |
| 211 | hum.MaxHealth = 1.0E298 | |
| 212 | hum.Health = 1.0E298 | |
| 213 | end | |
| 214 | end) | |
| 215 | ------------------------------------------------------- | |
| 216 | --End Whitelist and Invincibility-- | |
| 217 | ------------------------------------------------------- | |
| 218 | ||
| 219 | ------------------------------------------------------- | |
| 220 | --Start Good Stuff-- | |
| 221 | ------------------------------------------------------- | |
| 222 | cam = game.Workspace.CurrentCamera | |
| 223 | CF = CFrame.new | |
| 224 | angles = CFrame.Angles | |
| 225 | attack = false | |
| 226 | Euler = CFrame.fromEulerAnglesXYZ | |
| 227 | Rad = math.rad | |
| 228 | IT = Instance.new | |
| 229 | BrickC = BrickColor.new | |
| 230 | Cos = math.cos | |
| 231 | Acos = math.acos | |
| 232 | Sin = math.sin | |
| 233 | Asin = math.asin | |
| 234 | Abs = math.abs | |
| 235 | Mrandom = math.random | |
| 236 | Floor = math.floor | |
| 237 | ------------------------------------------------------- | |
| 238 | --End Good Stuff-- | |
| 239 | ------------------------------------------------------- | |
| 240 | necko = CF(0, 1, 0, -1, -0, -0, 0, 0, 1, 0, 1, 0) | |
| 241 | RSH, LSH = nil, nil | |
| 242 | RW = Instance.new("Weld")
| |
| 243 | LW = Instance.new("Weld")
| |
| 244 | RH = tors["Right Hip"] | |
| 245 | LH = tors["Left Hip"] | |
| 246 | RSH = tors["Right Shoulder"] | |
| 247 | LSH = tors["Left Shoulder"] | |
| 248 | RSH.Parent = nil | |
| 249 | LSH.Parent = nil | |
| 250 | RW.Name = "RW" | |
| 251 | RW.Part0 = tors | |
| 252 | RW.C0 = CF(1.5, 0.5, 0) | |
| 253 | RW.C1 = CF(0, 0.5, 0) | |
| 254 | RW.Part1 = ra | |
| 255 | RW.Parent = tors | |
| 256 | LW.Name = "LW" | |
| 257 | LW.Part0 = tors | |
| 258 | LW.C0 = CF(-1.5, 0.5, 0) | |
| 259 | LW.C1 = CF(0, 0.5, 0) | |
| 260 | LW.Part1 = la | |
| 261 | LW.Parent = tors | |
| 262 | Effects = {}
| |
| 263 | ------------------------------------------------------- | |
| 264 | --Start HeartBeat-- | |
| 265 | ------------------------------------------------------- | |
| 266 | ArtificialHB = Instance.new("BindableEvent", script)
| |
| 267 | ArtificialHB.Name = "Heartbeat" | |
| 268 | script:WaitForChild("Heartbeat")
| |
| 269 | ||
| 270 | frame = 1 / 60 | |
| 271 | tf = 0 | |
| 272 | allowframeloss = false | |
| 273 | tossremainder = false | |
| 274 | ||
| 275 | ||
| 276 | lastframe = tick() | |
| 277 | script.Heartbeat:Fire() | |
| 278 | ||
| 279 | ||
| 280 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 281 | tf = tf + s | |
| 282 | if tf >= frame then | |
| 283 | if allowframeloss then | |
| 284 | script.Heartbeat:Fire() | |
| 285 | lastframe = tick() | |
| 286 | else | |
| 287 | for i = 1, math.floor(tf / frame) do | |
| 288 | script.Heartbeat:Fire() | |
| 289 | end | |
| 290 | lastframe = tick() | |
| 291 | end | |
| 292 | if tossremainder then | |
| 293 | tf = 0 | |
| 294 | else | |
| 295 | tf = tf - frame * math.floor(tf / frame) | |
| 296 | end | |
| 297 | end | |
| 298 | end) | |
| 299 | ------------------------------------------------------- | |
| 300 | --End HeartBeat-- | |
| 301 | ------------------------------------------------------- | |
| 302 | ||
| 303 | ------------------------------------------------------- | |
| 304 | --Start Important Functions-- | |
| 305 | ------------------------------------------------------- | |
| 306 | function swait(num) | |
| 307 | if num == 0 or num == nil then | |
| 308 | game:service("RunService").Stepped:wait(0)
| |
| 309 | else | |
| 310 | for i = 0, num do | |
| 311 | game:service("RunService").Stepped:wait(0)
| |
| 312 | end | |
| 313 | end | |
| 314 | end | |
| 315 | function thread(f) | |
| 316 | coroutine.resume(coroutine.create(f)) | |
| 317 | end | |
| 318 | function clerp(a, b, t) | |
| 319 | local qa = {
| |
| 320 | QuaternionFromCFrame(a) | |
| 321 | } | |
| 322 | local qb = {
| |
| 323 | QuaternionFromCFrame(b) | |
| 324 | } | |
| 325 | local ax, ay, az = a.x, a.y, a.z | |
| 326 | local bx, by, bz = b.x, b.y, b.z | |
| 327 | local _t = 1 - t | |
| 328 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
| 329 | end | |
| 330 | function QuaternionFromCFrame(cf) | |
| 331 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 332 | local trace = m00 + m11 + m22 | |
| 333 | if trace > 0 then | |
| 334 | local s = math.sqrt(1 + trace) | |
| 335 | local recip = 0.5 / s | |
| 336 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
| 337 | else | |
| 338 | local i = 0 | |
| 339 | if m00 < m11 then | |
| 340 | i = 1 | |
| 341 | end | |
| 342 | if m22 > (i == 0 and m00 or m11) then | |
| 343 | i = 2 | |
| 344 | end | |
| 345 | if i == 0 then | |
| 346 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
| 347 | local recip = 0.5 / s | |
| 348 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
| 349 | elseif i == 1 then | |
| 350 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
| 351 | local recip = 0.5 / s | |
| 352 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
| 353 | elseif i == 2 then | |
| 354 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
| 355 | local recip = 0.5 / s | |
| 356 | return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
| 357 | end | |
| 358 | end | |
| 359 | end | |
| 360 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 361 | local xs, ys, zs = x + x, y + y, z + z | |
| 362 | local wx, wy, wz = w * xs, w * ys, w * zs | |
| 363 | local xx = x * xs | |
| 364 | local xy = x * ys | |
| 365 | local xz = x * zs | |
| 366 | local yy = y * ys | |
| 367 | local yz = y * zs | |
| 368 | local zz = z * zs | |
| 369 | 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)) | |
| 370 | end | |
| 371 | function QuaternionSlerp(a, b, t) | |
| 372 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
| 373 | local startInterp, finishInterp | |
| 374 | if cosTheta >= 1.0E-4 then | |
| 375 | if 1 - cosTheta > 1.0E-4 then | |
| 376 | local theta = math.acos(cosTheta) | |
| 377 | local invSinTheta = 1 / Sin(theta) | |
| 378 | startInterp = Sin((1 - t) * theta) * invSinTheta | |
| 379 | finishInterp = Sin(t * theta) * invSinTheta | |
| 380 | else | |
| 381 | startInterp = 1 - t | |
| 382 | finishInterp = t | |
| 383 | end | |
| 384 | elseif 1 + cosTheta > 1.0E-4 then | |
| 385 | local theta = math.acos(-cosTheta) | |
| 386 | local invSinTheta = 1 / Sin(theta) | |
| 387 | startInterp = Sin((t - 1) * theta) * invSinTheta | |
| 388 | finishInterp = Sin(t * theta) * invSinTheta | |
| 389 | else | |
| 390 | startInterp = t - 1 | |
| 391 | finishInterp = t | |
| 392 | end | |
| 393 | 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 | |
| 394 | end | |
| 395 | function rayCast(Position, Direction, Range, Ignore) | |
| 396 | return game:service("Workspace"):FindPartOnRay(Ray.new(Position, Direction.unit * (Range or 999.999)), Ignore)
| |
| 397 | end | |
| 398 | local RbxUtility = LoadLibrary("RbxUtility")
| |
| 399 | local Create = RbxUtility.Create | |
| 400 | ||
| 401 | ------------------------------------------------------- | |
| 402 | --Start Damage Function-- | |
| 403 | ------------------------------------------------------- | |
| 404 | function Damage(Part, hit, minim, maxim, knockback, Type, Property, Delay, HitSound, HitPitch) | |
| 405 | if hit.Parent == nil then | |
| 406 | return | |
| 407 | end | |
| 408 | local h = hit.Parent:FindFirstChildOfClass("Humanoid")
| |
| 409 | for _, v in pairs(hit.Parent:children()) do | |
| 410 | if v:IsA("Humanoid") then
| |
| 411 | h = v | |
| 412 | end | |
| 413 | end | |
| 414 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("UpperTorso") ~= nil then
| |
| 415 | ||
| 416 | hit.Parent:FindFirstChild("Head"):BreakJoints()
| |
| 417 | end | |
| 418 | ||
| 419 | if h ~= nil and hit.Parent.Name ~= char.Name and hit.Parent:FindFirstChild("Torso") ~= nil then
| |
| 420 | if hit.Parent:findFirstChild("DebounceHit") ~= nil then
| |
| 421 | if hit.Parent.DebounceHit.Value == true then | |
| 422 | return | |
| 423 | end | |
| 424 | end | |
| 425 | if insta == true then | |
| 426 | hit.Parent:FindFirstChild("Head"):BreakJoints()
| |
| 427 | end | |
| 428 | local c = Create("ObjectValue"){
| |
| 429 | Name = "creator", | |
| 430 | Value = game:service("Players").LocalPlayer,
| |
| 431 | Parent = h, | |
| 432 | } | |
| 433 | game:GetService("Debris"):AddItem(c, .5)
| |
| 434 | if HitSound ~= nil and HitPitch ~= nil then | |
| 435 | CFuncs.Sound.Create(HitSound, hit, 1, HitPitch) | |
| 436 | end | |
| 437 | local Damage = math.random(minim, maxim) | |
| 438 | local blocked = false | |
| 439 | local block = hit.Parent:findFirstChild("Block")
| |
| 440 | if block ~= nil then | |
| 441 | if block.className == "IntValue" then | |
| 442 | if block.Value > 0 then | |
| 443 | blocked = true | |
| 444 | block.Value = block.Value - 1 | |
| 445 | print(block.Value) | |
| 446 | end | |
| 447 | end | |
| 448 | end | |
| 449 | if blocked == false then | |
| 450 | h.Health = h.Health - Damage | |
| 451 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
| 452 | else | |
| 453 | h.Health = h.Health - (Damage / 2) | |
| 454 | ShowDamage((Part.CFrame * CFrame.new(0, 0, (Part.Size.Z / 2)).p + Vector3.new(0, 1.5, 0)), -Damage, 1.5, tors.BrickColor.Color) | |
| 455 | end | |
| 456 | if Type == "Knockdown" then | |
| 457 | local hum = hit.Parent.Humanoid | |
| 458 | hum.PlatformStand = true | |
| 459 | coroutine.resume(coroutine.create(function(HHumanoid) | |
| 460 | swait(1) | |
| 461 | HHumanoid.PlatformStand = false | |
| 462 | end), hum) | |
| 463 | local angle = (hit.Position - (Property.Position + Vector3.new(0, 0, 0))).unit | |
| 464 | local bodvol = Create("BodyVelocity"){
| |
| 465 | velocity = angle * knockback, | |
| 466 | P = 5000, | |
| 467 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
| 468 | Parent = hit, | |
| 469 | } | |
| 470 | local rl = Create("BodyAngularVelocity"){
| |
| 471 | P = 3000, | |
| 472 | maxTorque = Vector3.new(500000, 500000, 500000) * 50000000000000, | |
| 473 | angularvelocity = Vector3.new(math.random(-10, 10), math.random(-10, 10), math.random(-10, 10)), | |
| 474 | Parent = hit, | |
| 475 | } | |
| 476 | game:GetService("Debris"):AddItem(bodvol, .5)
| |
| 477 | game:GetService("Debris"):AddItem(rl, .5)
| |
| 478 | elseif Type == "Normal" then | |
| 479 | local vp = Create("BodyVelocity"){
| |
| 480 | P = 500, | |
| 481 | maxForce = Vector3.new(math.huge, 0, math.huge), | |
| 482 | velocity = Property.CFrame.lookVector * knockback + Property.Velocity / 1.05, | |
| 483 | } | |
| 484 | if knockback > 0 then | |
| 485 | vp.Parent = hit.Parent.Torso | |
| 486 | end | |
| 487 | game:GetService("Debris"):AddItem(vp, .5)
| |
| 488 | elseif Type == "Up" then | |
| 489 | local bodyVelocity = Create("BodyVelocity"){
| |
| 490 | velocity = Vector3.new(0, 20, 0), | |
| 491 | P = 5000, | |
| 492 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
| 493 | Parent = hit, | |
| 494 | } | |
| 495 | game:GetService("Debris"):AddItem(bodyVelocity, .5)
| |
| 496 | elseif Type == "DarkUp" then | |
| 497 | coroutine.resume(coroutine.create(function() | |
| 498 | for i = 0, 1, 0.1 do | |
| 499 | swait() | |
| 500 | Effects.Block.Create(BrickColor.new("Black"), hit.Parent.Torso.CFrame, 5, 5, 5, 1, 1, 1, .08, 1)
| |
| 501 | end | |
| 502 | end)) | |
| 503 | local bodyVelocity = Create("BodyVelocity"){
| |
| 504 | velocity = Vector3.new(0, 20, 0), | |
| 505 | P = 5000, | |
| 506 | maxForce = Vector3.new(8e+003, 8e+003, 8e+003), | |
| 507 | Parent = hit, | |
| 508 | } | |
| 509 | game:GetService("Debris"):AddItem(bodyVelocity, 1)
| |
| 510 | elseif Type == "Snare" then | |
| 511 | local bp = Create("BodyPosition"){
| |
| 512 | P = 2000, | |
| 513 | D = 100, | |
| 514 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 515 | position = hit.Parent.Torso.Position, | |
| 516 | Parent = hit.Parent.Torso, | |
| 517 | } | |
| 518 | game:GetService("Debris"):AddItem(bp, 1)
| |
| 519 | elseif Type == "Freeze" then | |
| 520 | local BodPos = Create("BodyPosition"){
| |
| 521 | P = 50000, | |
| 522 | D = 1000, | |
| 523 | maxForce = Vector3.new(math.huge, math.huge, math.huge), | |
| 524 | position = hit.Parent.Torso.Position, | |
| 525 | Parent = hit.Parent.Torso, | |
| 526 | } | |
| 527 | local BodGy = Create("BodyGyro") {
| |
| 528 | maxTorque = Vector3.new(4e+005, 4e+005, 4e+005) * math.huge , | |
| 529 | P = 20e+003, | |
| 530 | Parent = hit.Parent.Torso, | |
| 531 | cframe = hit.Parent.Torso.CFrame, | |
| 532 | } | |
| 533 | hit.Parent.Torso.Anchored = true | |
| 534 | coroutine.resume(coroutine.create(function(Part) | |
| 535 | swait(1.5) | |
| 536 | Part.Anchored = false | |
| 537 | end), hit.Parent.Torso) | |
| 538 | game:GetService("Debris"):AddItem(BodPos, 3)
| |
| 539 | game:GetService("Debris"):AddItem(BodGy, 3)
| |
| 540 | end | |
| 541 | local debounce = Create("BoolValue"){
| |
| 542 | Name = "DebounceHit", | |
| 543 | Parent = hit.Parent, | |
| 544 | Value = true, | |
| 545 | } | |
| 546 | game:GetService("Debris"):AddItem(debounce, Delay)
| |
| 547 | c = Create("ObjectValue"){
| |
| 548 | Name = "creator", | |
| 549 | Value = Player, | |
| 550 | Parent = h, | |
| 551 | } | |
| 552 | game:GetService("Debris"):AddItem(c, .5)
| |
| 553 | end | |
| 554 | end | |
| 555 | ------------------------------------------------------- | |
| 556 | --End Damage Function-- | |
| 557 | ------------------------------------------------------- | |
| 558 | ||
| 559 | ------------------------------------------------------- | |
| 560 | --Start Damage Function Customization-- | |
| 561 | ------------------------------------------------------- | |
| 562 | function ShowDamage(Pos, Text, Time, Color) | |
| 563 | local Rate = (1 / 30) | |
| 564 | local Pos = (Pos or Vector3.new(0, 0, 0)) | |
| 565 | local Text = (Text or "") | |
| 566 | local Time = (Time or 2) | |
| 567 | local Color = (Color or Color3.new(1, 0, 1)) | |
| 568 | local EffectPart = CFuncs.Part.Create(workspace, "SmoothPlastic", 0, 1, BrickColor.new(Color), "Effect", Vector3.new(0, 0, 0)) | |
| 569 | EffectPart.Anchored = true | |
| 570 | local BillboardGui = Create("BillboardGui"){
| |
| 571 | Size = UDim2.new(3, 0, 3, 0), | |
| 572 | Adornee = EffectPart, | |
| 573 | Parent = EffectPart, | |
| 574 | } | |
| 575 | local TextLabel = Create("TextLabel"){
| |
| 576 | BackgroundTransparency = 1, | |
| 577 | Size = UDim2.new(1, 0, 1, 0), | |
| 578 | Text = Text, | |
| 579 | Font = "Bodoni", | |
| 580 | TextColor3 = Color, | |
| 581 | TextScaled = true, | |
| 582 | TextStrokeColor3 = Color3.fromRGB(0,0,0), | |
| 583 | Parent = BillboardGui, | |
| 584 | } | |
| 585 | game.Debris:AddItem(EffectPart, (Time)) | |
| 586 | EffectPart.Parent = game:GetService("Workspace")
| |
| 587 | delay(0, function() | |
| 588 | local Frames = (Time / Rate) | |
| 589 | for Frame = 1, Frames do | |
| 590 | wait(Rate) | |
| 591 | local Percent = (Frame / Frames) | |
| 592 | EffectPart.CFrame = CFrame.new(Pos) + Vector3.new(0, Percent, 0) | |
| 593 | TextLabel.TextTransparency = Percent | |
| 594 | end | |
| 595 | if EffectPart and EffectPart.Parent then | |
| 596 | EffectPart:Destroy() | |
| 597 | end | |
| 598 | end) | |
| 599 | end | |
| 600 | ------------------------------------------------------- | |
| 601 | --End Damage Function Customization-- | |
| 602 | ------------------------------------------------------- | |
| 603 | ||
| 604 | function MagniDamage(Part, magni, mindam, maxdam, knock, Type) | |
| 605 | for _, c in pairs(workspace:children()) do | |
| 606 | local hum = c:findFirstChild("Humanoid")
| |
| 607 | if hum ~= nil then | |
| 608 | local head = c:findFirstChild("Head")
| |
| 609 | if head ~= nil then | |
| 610 | local targ = head.Position - Part.Position | |
| 611 | local mag = targ.magnitude | |
| 612 | if magni >= mag and c.Name ~= plr.Name then | |
| 613 | Damage(head, head, mindam, maxdam, knock, Type, root, 0.1, "http://www.roblox.com/asset/?id=0", 1.2) | |
| 614 | end | |
| 615 | end | |
| 616 | end | |
| 617 | end | |
| 618 | end | |
| 619 | ||
| 620 | ||
| 621 | CFuncs = {
| |
| 622 | Part = {
| |
| 623 | Create = function(Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
| 624 | local Part = Create("Part")({
| |
| 625 | Parent = Parent, | |
| 626 | Reflectance = Reflectance, | |
| 627 | Transparency = Transparency, | |
| 628 | CanCollide = false, | |
| 629 | Locked = true, | |
| 630 | BrickColor = BrickColor.new(tostring(BColor)), | |
| 631 | Name = Name, | |
| 632 | Size = Size, | |
| 633 | Material = Material | |
| 634 | }) | |
| 635 | RemoveOutlines(Part) | |
| 636 | return Part | |
| 637 | end | |
| 638 | }, | |
| 639 | Mesh = {
| |
| 640 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 641 | local Msh = Create(Mesh)({
| |
| 642 | Parent = Part, | |
| 643 | Offset = OffSet, | |
| 644 | Scale = Scale | |
| 645 | }) | |
| 646 | if Mesh == "SpecialMesh" then | |
| 647 | Msh.MeshType = MeshType | |
| 648 | Msh.MeshId = MeshId | |
| 649 | end | |
| 650 | return Msh | |
| 651 | end | |
| 652 | }, | |
| 653 | Mesh = {
| |
| 654 | Create = function(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 655 | local Msh = Create(Mesh)({
| |
| 656 | Parent = Part, | |
| 657 | Offset = OffSet, | |
| 658 | Scale = Scale | |
| 659 | }) | |
| 660 | if Mesh == "SpecialMesh" then | |
| 661 | Msh.MeshType = MeshType | |
| 662 | Msh.MeshId = MeshId | |
| 663 | end | |
| 664 | return Msh | |
| 665 | end | |
| 666 | }, | |
| 667 | Weld = {
| |
| 668 | Create = function(Parent, Part0, Part1, C0, C1) | |
| 669 | local Weld = Create("Weld")({
| |
| 670 | Parent = Parent, | |
| 671 | Part0 = Part0, | |
| 672 | Part1 = Part1, | |
| 673 | C0 = C0, | |
| 674 | C1 = C1 | |
| 675 | }) | |
| 676 | return Weld | |
| 677 | end | |
| 678 | }, | |
| 679 | Sound = {
| |
| 680 | Create = function(id, par, vol, pit) | |
| 681 | coroutine.resume(coroutine.create(function() | |
| 682 | local S = Create("Sound")({
| |
| 683 | Volume = vol, | |
| 684 | Pitch = pit or 1, | |
| 685 | SoundId = id, | |
| 686 | Parent = par or workspace | |
| 687 | }) | |
| 688 | wait() | |
| 689 | S:play() | |
| 690 | game:GetService("Debris"):AddItem(S, 6)
| |
| 691 | end)) | |
| 692 | end | |
| 693 | }, | |
| 694 | ParticleEmitter = {
| |
| 695 | Create = function(Parent, Color1, Color2, LightEmission, Size, Texture, Transparency, ZOffset, Accel, Drag, LockedToPart, VelocityInheritance, EmissionDirection, Enabled, LifeTime, Rate, Rotation, RotSpeed, Speed, VelocitySpread) | |
| 696 | local fp = Create("ParticleEmitter")({
| |
| 697 | Parent = Parent, | |
| 698 | Color = ColorSequence.new(Color1, Color2), | |
| 699 | LightEmission = LightEmission, | |
| 700 | Size = Size, | |
| 701 | Texture = Texture, | |
| 702 | Transparency = Transparency, | |
| 703 | ZOffset = ZOffset, | |
| 704 | Acceleration = Accel, | |
| 705 | Drag = Drag, | |
| 706 | LockedToPart = LockedToPart, | |
| 707 | VelocityInheritance = VelocityInheritance, | |
| 708 | EmissionDirection = EmissionDirection, | |
| 709 | Enabled = Enabled, | |
| 710 | Lifetime = LifeTime, | |
| 711 | Rate = Rate, | |
| 712 | Rotation = Rotation, | |
| 713 | RotSpeed = RotSpeed, | |
| 714 | Speed = Speed, | |
| 715 | VelocitySpread = VelocitySpread | |
| 716 | }) | |
| 717 | return fp | |
| 718 | end | |
| 719 | } | |
| 720 | } | |
| 721 | function RemoveOutlines(part) | |
| 722 | part.TopSurface, part.BottomSurface, part.LeftSurface, part.RightSurface, part.FrontSurface, part.BackSurface = 10, 10, 10, 10, 10, 10 | |
| 723 | end | |
| 724 | function CreatePart1(FormFactor, Parent, Material, Reflectance, Transparency, BColor, Name, Size) | |
| 725 | local Part = Create("Part")({
| |
| 726 | formFactor = FormFactor, | |
| 727 | Parent = Parent, | |
| 728 | Reflectance = Reflectance, | |
| 729 | Transparency = Transparency, | |
| 730 | CanCollide = false, | |
| 731 | Locked = true, | |
| 732 | BrickColor = BrickColor.new(tostring(BColor)), | |
| 733 | Name = Name, | |
| 734 | Size = Size, | |
| 735 | Material = Material | |
| 736 | }) | |
| 737 | RemoveOutlines(Part) | |
| 738 | return Part | |
| 739 | end | |
| 740 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
| 741 | local NEWPART = IT("Part")
| |
| 742 | NEWPART.formFactor = FORMFACTOR | |
| 743 | NEWPART.Reflectance = REFLECTANCE | |
| 744 | NEWPART.Transparency = TRANSPARENCY | |
| 745 | NEWPART.CanCollide = false | |
| 746 | NEWPART.Locked = true | |
| 747 | NEWPART.Anchored = true | |
| 748 | if ANCHOR == false then | |
| 749 | NEWPART.Anchored = false | |
| 750 | end | |
| 751 | NEWPART.BrickColor = BrickC(tostring(BRICKCOLOR)) | |
| 752 | NEWPART.Name = NAME | |
| 753 | NEWPART.Size = SIZE | |
| 754 | NEWPART.Position = tors.Position | |
| 755 | NEWPART.Material = MATERIAL | |
| 756 | NEWPART:BreakJoints() | |
| 757 | NEWPART.Parent = PARENT | |
| 758 | return NEWPART | |
| 759 | end | |
| 760 | function CreateMesh(Mesh, Part, MeshType, MeshId, OffSet, Scale) | |
| 761 | local Msh = Create(Mesh)({
| |
| 762 | Parent = Part, | |
| 763 | Offset = OffSet, | |
| 764 | Scale = Scale | |
| 765 | }) | |
| 766 | if Mesh == "SpecialMesh" then | |
| 767 | Msh.MeshType = MeshType | |
| 768 | Msh.MeshId = MeshId | |
| 769 | end | |
| 770 | return Msh | |
| 771 | end | |
| 772 | function CreateWeld(Parent, Part0, Part1, C0, C1) | |
| 773 | local Weld = Create("Weld")({
| |
| 774 | Parent = Parent, | |
| 775 | Part0 = Part0, | |
| 776 | Part1 = Part1, | |
| 777 | C0 = C0, | |
| 778 | C1 = C1 | |
| 779 | }) | |
| 780 | return Weld | |
| 781 | end | |
| 782 | ||
| 783 | ||
| 784 | ------------------------------------------------------- | |
| 785 | --Start Effect Function-- | |
| 786 | ------------------------------------------------------- | |
| 787 | EffectModel = Instance.new("Model", char)
| |
| 788 | Effects = {
| |
| 789 | Block = {
| |
| 790 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay, Type) | |
| 791 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 792 | prt.Anchored = true | |
| 793 | prt.CFrame = cframe | |
| 794 | local msh = CFuncs.Mesh.Create("BlockMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 795 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 796 | if Type == 1 or Type == nil then | |
| 797 | table.insert(Effects, {
| |
| 798 | prt, | |
| 799 | "Block1", | |
| 800 | delay, | |
| 801 | x3, | |
| 802 | y3, | |
| 803 | z3, | |
| 804 | msh | |
| 805 | }) | |
| 806 | elseif Type == 2 then | |
| 807 | table.insert(Effects, {
| |
| 808 | prt, | |
| 809 | "Block2", | |
| 810 | delay, | |
| 811 | x3, | |
| 812 | y3, | |
| 813 | z3, | |
| 814 | msh | |
| 815 | }) | |
| 816 | else | |
| 817 | table.insert(Effects, {
| |
| 818 | prt, | |
| 819 | "Block3", | |
| 820 | delay, | |
| 821 | x3, | |
| 822 | y3, | |
| 823 | z3, | |
| 824 | msh | |
| 825 | }) | |
| 826 | end | |
| 827 | end | |
| 828 | }, | |
| 829 | Sphere = {
| |
| 830 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 831 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 832 | prt.Anchored = true | |
| 833 | prt.CFrame = cframe | |
| 834 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 835 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 836 | table.insert(Effects, {
| |
| 837 | prt, | |
| 838 | "Cylinder", | |
| 839 | delay, | |
| 840 | x3, | |
| 841 | y3, | |
| 842 | z3, | |
| 843 | msh | |
| 844 | }) | |
| 845 | end | |
| 846 | }, | |
| 847 | Cylinder = {
| |
| 848 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 849 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 850 | prt.Anchored = true | |
| 851 | prt.CFrame = cframe | |
| 852 | local msh = CFuncs.Mesh.Create("CylinderMesh", prt, "", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 853 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 854 | table.insert(Effects, {
| |
| 855 | prt, | |
| 856 | "Cylinder", | |
| 857 | delay, | |
| 858 | x3, | |
| 859 | y3, | |
| 860 | z3, | |
| 861 | msh | |
| 862 | }) | |
| 863 | end | |
| 864 | }, | |
| 865 | Wave = {
| |
| 866 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 867 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 868 | prt.Anchored = true | |
| 869 | prt.CFrame = cframe | |
| 870 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://20329976", Vector3.new(0, 0, 0), Vector3.new(x1 / 60, y1 / 60, z1 / 60))
| |
| 871 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 872 | table.insert(Effects, {
| |
| 873 | prt, | |
| 874 | "Cylinder", | |
| 875 | delay, | |
| 876 | x3 / 60, | |
| 877 | y3 / 60, | |
| 878 | z3 / 60, | |
| 879 | msh | |
| 880 | }) | |
| 881 | end | |
| 882 | }, | |
| 883 | Ring = {
| |
| 884 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 885 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 886 | prt.Anchored = true | |
| 887 | prt.CFrame = cframe | |
| 888 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://3270017", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 889 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 890 | table.insert(Effects, {
| |
| 891 | prt, | |
| 892 | "Cylinder", | |
| 893 | delay, | |
| 894 | x3, | |
| 895 | y3, | |
| 896 | z3, | |
| 897 | msh | |
| 898 | }) | |
| 899 | end | |
| 900 | }, | |
| 901 | Break = {
| |
| 902 | Create = function(brickcolor, cframe, x1, y1, z1) | |
| 903 | local prt = CFuncs.Part.Create(EffectModel, "Neon", 0, 0, brickcolor, "Effect", Vector3.new(0.5, 0.5, 0.5)) | |
| 904 | prt.Anchored = true | |
| 905 | prt.CFrame = cframe * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
| 906 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "Sphere", "", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 907 | local num = math.random(10, 50) / 1000 | |
| 908 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 909 | table.insert(Effects, {
| |
| 910 | prt, | |
| 911 | "Shatter", | |
| 912 | num, | |
| 913 | prt.CFrame, | |
| 914 | math.random() - math.random(), | |
| 915 | 0, | |
| 916 | math.random(50, 100) / 100 | |
| 917 | }) | |
| 918 | end | |
| 919 | }, | |
| 920 | Spiral = {
| |
| 921 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 922 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 923 | prt.Anchored = true | |
| 924 | prt.CFrame = cframe | |
| 925 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://1051557", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 926 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 927 | table.insert(Effects, {
| |
| 928 | prt, | |
| 929 | "Cylinder", | |
| 930 | delay, | |
| 931 | x3, | |
| 932 | y3, | |
| 933 | z3, | |
| 934 | msh | |
| 935 | }) | |
| 936 | end | |
| 937 | }, | |
| 938 | Push = {
| |
| 939 | Create = function(brickcolor, cframe, x1, y1, z1, x3, y3, z3, delay) | |
| 940 | local prt = CFuncs.Part.Create(EffectModel, "SmoothPlastic", 0, 0, brickcolor, "Effect", Vector3.new()) | |
| 941 | prt.Anchored = true | |
| 942 | prt.CFrame = cframe | |
| 943 | local msh = CFuncs.Mesh.Create("SpecialMesh", prt, "FileMesh", "rbxassetid://437347603", Vector3.new(0, 0, 0), Vector3.new(x1, y1, z1))
| |
| 944 | game:GetService("Debris"):AddItem(prt, 10)
| |
| 945 | table.insert(Effects, {
| |
| 946 | prt, | |
| 947 | "Cylinder", | |
| 948 | delay, | |
| 949 | x3, | |
| 950 | y3, | |
| 951 | z3, | |
| 952 | msh | |
| 953 | }) | |
| 954 | end | |
| 955 | } | |
| 956 | } | |
| 957 | function part(formfactor ,parent, reflectance, transparency, brickcolor, name, size) | |
| 958 | local fp = IT("Part")
| |
| 959 | fp.formFactor = formfactor | |
| 960 | fp.Parent = parent | |
| 961 | fp.Reflectance = reflectance | |
| 962 | fp.Transparency = transparency | |
| 963 | fp.CanCollide = false | |
| 964 | fp.Locked = true | |
| 965 | fp.BrickColor = brickcolor | |
| 966 | fp.Name = name | |
| 967 | fp.Size = size | |
| 968 | fp.Position = tors.Position | |
| 969 | RemoveOutlines(fp) | |
| 970 | fp.Material = "SmoothPlastic" | |
| 971 | fp:BreakJoints() | |
| 972 | return fp | |
| 973 | end | |
| 974 | ||
| 975 | function mesh(Mesh,part,meshtype,meshid,offset,scale) | |
| 976 | local mesh = IT(Mesh) | |
| 977 | mesh.Parent = part | |
| 978 | if Mesh == "SpecialMesh" then | |
| 979 | mesh.MeshType = meshtype | |
| 980 | if meshid ~= "nil" then | |
| 981 | mesh.MeshId = "http://www.roblox.com/asset/?id="..meshid | |
| 982 | end | |
| 983 | end | |
| 984 | mesh.Offset = offset | |
| 985 | mesh.Scale = scale | |
| 986 | return mesh | |
| 987 | end | |
| 988 | ||
| 989 | function Magic(bonuspeed, type, pos, scale, value, color, MType) | |
| 990 | local type = type | |
| 991 | local rng = Instance.new("Part", char)
| |
| 992 | rng.Anchored = true | |
| 993 | rng.BrickColor = color | |
| 994 | rng.CanCollide = false | |
| 995 | rng.FormFactor = 3 | |
| 996 | rng.Name = "Ring" | |
| 997 | rng.Material = "Neon" | |
| 998 | rng.Size = Vector3.new(1, 1, 1) | |
| 999 | rng.Transparency = 0 | |
| 1000 | rng.TopSurface = 0 | |
| 1001 | rng.BottomSurface = 0 | |
| 1002 | rng.CFrame = pos | |
| 1003 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1004 | rngm.MeshType = MType | |
| 1005 | rngm.Scale = scale | |
| 1006 | local scaler2 = 1 | |
| 1007 | if type == "Add" then | |
| 1008 | scaler2 = 1 * value | |
| 1009 | elseif type == "Divide" then | |
| 1010 | scaler2 = 1 / value | |
| 1011 | end | |
| 1012 | coroutine.resume(coroutine.create(function() | |
| 1013 | for i = 0, 10 / bonuspeed, 0.1 do | |
| 1014 | swait() | |
| 1015 | if type == "Add" then | |
| 1016 | scaler2 = scaler2 - 0.01 * value / bonuspeed | |
| 1017 | elseif type == "Divide" then | |
| 1018 | scaler2 = scaler2 - 0.01 / value * bonuspeed | |
| 1019 | end | |
| 1020 | rng.Transparency = rng.Transparency + 0.01 * bonuspeed | |
| 1021 | rngm.Scale = rngm.Scale + Vector3.new(scaler2 * bonuspeed, scaler2 * bonuspeed, scaler2 * bonuspeed) | |
| 1022 | end | |
| 1023 | rng:Destroy() | |
| 1024 | end)) | |
| 1025 | end | |
| 1026 | ||
| 1027 | function Eviscerate(dude) | |
| 1028 | if dude.Name ~= char then | |
| 1029 | local bgf = IT("BodyGyro", dude.Head)
| |
| 1030 | bgf.CFrame = bgf.CFrame * CFrame.fromEulerAnglesXYZ(Rad(-90), 0, 0) | |
| 1031 | local val = IT("BoolValue", dude)
| |
| 1032 | val.Name = "IsHit" | |
| 1033 | local ds = coroutine.wrap(function() | |
| 1034 | dude:WaitForChild("Head"):BreakJoints()
| |
| 1035 | wait(0.5) | |
| 1036 | target = nil | |
| 1037 | coroutine.resume(coroutine.create(function() | |
| 1038 | for i, v in pairs(dude:GetChildren()) do | |
| 1039 | if v:IsA("Accessory") then
| |
| 1040 | v:Destroy() | |
| 1041 | end | |
| 1042 | if v:IsA("Humanoid") then
| |
| 1043 | v:Destroy() | |
| 1044 | end | |
| 1045 | if v:IsA("CharacterMesh") then
| |
| 1046 | v:Destroy() | |
| 1047 | end | |
| 1048 | if v:IsA("Model") then
| |
| 1049 | v:Destroy() | |
| 1050 | end | |
| 1051 | if v:IsA("Part") or v:IsA("MeshPart") then
| |
| 1052 | for x, o in pairs(v:GetChildren()) do | |
| 1053 | if o:IsA("Decal") then
| |
| 1054 | o:Destroy() | |
| 1055 | end | |
| 1056 | end | |
| 1057 | coroutine.resume(coroutine.create(function() | |
| 1058 | v.Material = "Neon" | |
| 1059 | v.CanCollide = false | |
| 1060 | local PartEmmit1 = IT("ParticleEmitter", v)
| |
| 1061 | PartEmmit1.LightEmission = 1 | |
| 1062 | PartEmmit1.Texture = "rbxassetid://284205403" | |
| 1063 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
| 1064 | PartEmmit1.Rate = 150 | |
| 1065 | PartEmmit1.Lifetime = NumberRange.new(1) | |
| 1066 | PartEmmit1.Size = NumberSequence.new({
| |
| 1067 | NumberSequenceKeypoint.new(0, 0.75, 0), | |
| 1068 | NumberSequenceKeypoint.new(1, 0, 0) | |
| 1069 | }) | |
| 1070 | PartEmmit1.Transparency = NumberSequence.new({
| |
| 1071 | NumberSequenceKeypoint.new(0, 0, 0), | |
| 1072 | NumberSequenceKeypoint.new(1, 1, 0) | |
| 1073 | }) | |
| 1074 | PartEmmit1.Speed = NumberRange.new(0, 0) | |
| 1075 | PartEmmit1.VelocitySpread = 30000 | |
| 1076 | PartEmmit1.Rotation = NumberRange.new(-500, 500) | |
| 1077 | PartEmmit1.RotSpeed = NumberRange.new(-500, 500) | |
| 1078 | local BodPoss = IT("BodyPosition", v)
| |
| 1079 | BodPoss.P = 3000 | |
| 1080 | BodPoss.D = 1000 | |
| 1081 | BodPoss.maxForce = Vector3.new(50000000000, 50000000000, 50000000000) | |
| 1082 | BodPoss.position = v.Position + Vector3.new(Mrandom(-15, 15), Mrandom(-15, 15), Mrandom(-15, 15)) | |
| 1083 | v.Color = maincolor.Color | |
| 1084 | coroutine.resume(coroutine.create(function() | |
| 1085 | for i = 0, 49 do | |
| 1086 | swait(1) | |
| 1087 | v.Transparency = v.Transparency + 0.08 | |
| 1088 | end | |
| 1089 | wait(0.5) | |
| 1090 | PartEmmit1.Enabled = false | |
| 1091 | wait(3) | |
| 1092 | v:Destroy() | |
| 1093 | dude:Destroy() | |
| 1094 | end)) | |
| 1095 | end)) | |
| 1096 | end | |
| 1097 | end | |
| 1098 | end)) | |
| 1099 | end) | |
| 1100 | ds() | |
| 1101 | end | |
| 1102 | end | |
| 1103 | ||
| 1104 | function FindNearestHead(Position, Distance, SinglePlayer) | |
| 1105 | if SinglePlayer then | |
| 1106 | return Distance > (SinglePlayer.Torso.CFrame.p - Position).magnitude | |
| 1107 | end | |
| 1108 | local List = {}
| |
| 1109 | for i, v in pairs(workspace:GetChildren()) do | |
| 1110 | if v:IsA("Model") and v:findFirstChild("Head") and v ~= char and Distance >= (v.Head.Position - Position).magnitude then
| |
| 1111 | table.insert(List, v) | |
| 1112 | end | |
| 1113 | end | |
| 1114 | return List | |
| 1115 | end | |
| 1116 | ||
| 1117 | function Aura(bonuspeed, FastSpeed, type, pos, x1, y1, z1, value, color, outerpos, MType) | |
| 1118 | local type = type | |
| 1119 | local rng = Instance.new("Part", char)
| |
| 1120 | rng.Anchored = true | |
| 1121 | rng.BrickColor = color | |
| 1122 | rng.CanCollide = false | |
| 1123 | rng.FormFactor = 3 | |
| 1124 | rng.Name = "Ring" | |
| 1125 | rng.Material = "Neon" | |
| 1126 | rng.Size = Vector3.new(1, 1, 1) | |
| 1127 | rng.Transparency = 0 | |
| 1128 | rng.TopSurface = 0 | |
| 1129 | rng.BottomSurface = 0 | |
| 1130 | rng.CFrame = pos | |
| 1131 | rng.CFrame = rng.CFrame + rng.CFrame.lookVector * outerpos | |
| 1132 | local rngm = Instance.new("SpecialMesh", rng)
| |
| 1133 | rngm.MeshType = MType | |
| 1134 | rngm.Scale = Vector3.new(x1, y1, z1) | |
| 1135 | local scaler2 = 1 | |
| 1136 | local speeder = FastSpeed | |
| 1137 | if type == "Add" then | |
| 1138 | scaler2 = 1 * value | |
| 1139 | elseif type == "Divide" then | |
| 1140 | scaler2 = 1 / value | |
| 1141 | end | |
| 1142 | coroutine.resume(coroutine.create(function() | |
| 1143 | for i = 0, 10 / bonuspeed, 0.1 do | |
| 1144 | swait() | |
| 1145 | if type == "Add" then | |
| 1146 | scaler2 = scaler2 - 0.01 * value / bonuspeed | |
| 1147 | elseif type == "Divide" then | |
| 1148 | scaler2 = scaler2 - 0.01 / value * bonuspeed | |
| 1149 | end | |
| 1150 | speeder = speeder - 0.01 * FastSpeed * bonuspeed | |
| 1151 | rng.CFrame = rng.CFrame + rng.CFrame.lookVector * speeder * bonuspeed | |
| 1152 | rng.Transparency = rng.Transparency + 0.01 * bonuspeed | |
| 1153 | rngm.Scale = rngm.Scale + Vector3.new(scaler2 * bonuspeed, scaler2 * bonuspeed, 0) | |
| 1154 | end | |
| 1155 | rng:Destroy() | |
| 1156 | end)) | |
| 1157 | end | |
| 1158 | ||
| 1159 | function SoulSteal(dude) | |
| 1160 | if dude.Name ~= char then | |
| 1161 | local bgf = IT("BodyGyro", dude.Head)
| |
| 1162 | bgf.CFrame = bgf.CFrame * CFrame.fromEulerAnglesXYZ(Rad(-90), 0, 0) | |
| 1163 | local val = IT("BoolValue", dude)
| |
| 1164 | val.Name = "IsHit" | |
| 1165 | local torso = (dude:FindFirstChild'Head' or dude:FindFirstChild'Torso' or dude:FindFirstChild'UpperTorso' or dude:FindFirstChild'LowerTorso' or dude:FindFirstChild'HumanoidRootPart') | |
| 1166 | local soulst = coroutine.wrap(function() | |
| 1167 | local soul = Instance.new("Part",dude)
| |
| 1168 | soul.Size = Vector3.new(1,1,1) | |
| 1169 | soul.CanCollide = false | |
| 1170 | soul.Anchored = false | |
| 1171 | soul.Position = torso.Position | |
| 1172 | soul.Transparency = 1 | |
| 1173 | local PartEmmit1 = IT("ParticleEmitter", soul)
| |
| 1174 | PartEmmit1.LightEmission = 1 | |
| 1175 | PartEmmit1.Texture = "rbxassetid://569507414" | |
| 1176 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
| 1177 | PartEmmit1.Rate = 250 | |
| 1178 | PartEmmit1.Lifetime = NumberRange.new(1.6) | |
| 1179 | PartEmmit1.Size = NumberSequence.new({
| |
| 1180 | NumberSequenceKeypoint.new(0, 1, 0), | |
| 1181 | NumberSequenceKeypoint.new(1, 0, 0) | |
| 1182 | }) | |
| 1183 | PartEmmit1.Transparency = NumberSequence.new({
| |
| 1184 | NumberSequenceKeypoint.new(0, 0, 0), | |
| 1185 | NumberSequenceKeypoint.new(1, 1, 0) | |
| 1186 | }) | |
| 1187 | PartEmmit1.Speed = NumberRange.new(0, 0) | |
| 1188 | PartEmmit1.VelocitySpread = 30000 | |
| 1189 | PartEmmit1.Rotation = NumberRange.new(-360, 360) | |
| 1190 | PartEmmit1.RotSpeed = NumberRange.new(-360, 360) | |
| 1191 | local BodPoss = IT("BodyPosition", soul)
| |
| 1192 | BodPoss.P = 3000 | |
| 1193 | BodPoss.D = 1000 | |
| 1194 | BodPoss.maxForce = Vector3.new(50000000000, 50000000000, 50000000000) | |
| 1195 | BodPoss.position = torso.Position + Vector3.new(Mrandom(-15, 15), Mrandom(-15, 15), Mrandom(-15, 15)) | |
| 1196 | wait(1.6) | |
| 1197 | soul.Touched:connect(function(hit) | |
| 1198 | if hit.Parent == char then | |
| 1199 | soul:Destroy() | |
| 1200 | end | |
| 1201 | end) | |
| 1202 | wait(1.2) | |
| 1203 | while soul do | |
| 1204 | swait() | |
| 1205 | PartEmmit1.Color = ColorSequence.new(maincolor.Color) | |
| 1206 | BodPoss.Position = tors.Position | |
| 1207 | end | |
| 1208 | end) | |
| 1209 | soulst() | |
| 1210 | end | |
| 1211 | end | |
| 1212 | function FaceMouse() | |
| 1213 | local Cam = workspace.CurrentCamera | |
| 1214 | return {
| |
| 1215 | CFrame.new(char.Torso.Position, Vector3.new(mouse.Hit.p.x, char.Torso.Position.y, mouse.Hit.p.z)), | |
| 1216 | Vector3.new(mouse.Hit.p.x, mouse.Hit.p.y, mouse.Hit.p.z) | |
| 1217 | } | |
| 1218 | end | |
| 1219 | ------------------------------------------------------- | |
| 1220 | --End Effect Function-- | |
| 1221 | ------------------------------------------------------- | |
| 1222 | function Cso(ID, PARENT, VOLUME, PITCH) | |
| 1223 | local NSound = nil | |
| 1224 | coroutine.resume(coroutine.create(function() | |
| 1225 | NSound = IT("Sound", PARENT)
| |
| 1226 | NSound.Volume = VOLUME | |
| 1227 | NSound.Pitch = PITCH | |
| 1228 | NSound.SoundId = "http://www.roblox.com/asset/?id="..ID | |
| 1229 | swait() | |
| 1230 | NSound:play() | |
| 1231 | game:GetService("Debris"):AddItem(NSound, 10)
| |
| 1232 | end)) | |
| 1233 | return NSound | |
| 1234 | end | |
| 1235 | function CameraEnshaking(Length, Intensity) | |
| 1236 | coroutine.resume(coroutine.create(function() | |
| 1237 | local intensity = 1 * Intensity | |
| 1238 | local rotM = 0.01 * Intensity | |
| 1239 | for i = 0, Length, 0.1 do | |
| 1240 | swait() | |
| 1241 | intensity = intensity - 0.05 * Intensity / Length | |
| 1242 | rotM = rotM - 5.0E-4 * Intensity / Length | |
| 1243 | hum.CameraOffset = Vector3.new(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) | |
| 1244 | cam.CFrame = cam.CFrame * CF(Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity)), Rad(Mrandom(-intensity, intensity))) * Euler(Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM, Rad(Mrandom(-intensity, intensity)) * rotM) | |
| 1245 | end | |
| 1246 | hum.CameraOffset = Vector3.new(0, 0, 0) | |
| 1247 | end)) | |
| 1248 | end | |
| 1249 | ||
| 1250 | local Particle = IT("ParticleEmitter",nil)
| |
| 1251 | Particle.Enabled = false | |
| 1252 | --Particle.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,1),NumberSequenceKeypoint.new(0.3,0.95),NumberSequenceKeypoint.new(1,1)})
| |
| 1253 | Particle.LightEmission = 0.5 | |
| 1254 | Particle.Rate = 150 | |
| 1255 | Particle.ZOffset = 1 | |
| 1256 | Particle.Rotation = NumberRange.new(-180, 180) | |
| 1257 | Particle.RotSpeed = NumberRange.new(-180, 180) | |
| 1258 | Particle.Texture = "http://www.roblox.com/asset/?id=284205403" | |
| 1259 | Particle.Color = ColorSequence.new(Color3.new(0,0,0),Color3.new(0,0,0)) | |
| 1260 | ||
| 1261 | function ParticleEmitter(Table) | |
| 1262 | local PRTCL = Particle:Clone() | |
| 1263 | local Speed = Table.Speed or 5 | |
| 1264 | local Drag = Table.Drag or 0 | |
| 1265 | local Size1 = Table.Size1 or 1 | |
| 1266 | local Size2 = Table.Size2 or 5 | |
| 1267 | local Lifetime1 = Table.Lifetime1 or 1 | |
| 1268 | local Lifetime2 = Table.Lifetime2 or 1.5 | |
| 1269 | local Parent = Table.Parent or tors | |
| 1270 | local Emit = Table.Emit or 100 | |
| 1271 | local Offset = Table.Offset or 360 | |
| 1272 | local Acel = Table.Acel or Vector3.new(0,-50,0) | |
| 1273 | local Enabled = Table.Enabled or false | |
| 1274 | PRTCL.Parent = Parent | |
| 1275 | PRTCL.Size = NumberSequence.new(Size1,Size2) | |
| 1276 | PRTCL.Lifetime = NumberRange.new(Lifetime1,Lifetime2) | |
| 1277 | PRTCL.Speed = NumberRange.new(Speed) | |
| 1278 | PRTCL.VelocitySpread = Offset | |
| 1279 | PRTCL.Drag = Drag | |
| 1280 | PRTCL.Acceleration = Acel | |
| 1281 | if Enabled == false then | |
| 1282 | PRTCL:Emit(Emit) | |
| 1283 | game:GetService("Debris"):AddItem(PRTCL,Lifetime2)
| |
| 1284 | else | |
| 1285 | PRTCL.Enabled = true | |
| 1286 | end | |
| 1287 | return PRTCL | |
| 1288 | end | |
| 1289 | local PRT = ParticleEmitter({Speed = 0.3, Drag = 3, Size1 = 1.1, Size2 = 0.3, Lifetime1 = 0.2, Lifetime2 = 1, Parent = rl, Emit = 900, Offset = 360, Enabled = true})
| |
| 1290 | --PRT.LockedToPart = true | |
| 1291 | local PRT = ParticleEmitter({Speed = 0.3, Drag = 3, Size1 = 1.1, Size2 = 0.3, Lifetime1 = 0.2, Lifetime2 = 1, Parent = ll, Emit = 900, Offset = 360, Enabled = true})
| |
| 1292 | --PRT.LockedToPart = true | |
| 1293 | local PRT = ParticleEmitter({Speed = 0.3, Drag = 3, Size1 = 1.1, Size2 = 0.3, Lifetime1 = 0.3, Lifetime2 = 1.5, Parent = tors, Emit = 900, Offset = 360, Enabled = true})
| |
| 1294 | --PRT.LockedToPart = true | |
| 1295 | local PRT = ParticleEmitter({Speed = 0.3, Drag = 3, Size1 = 1.1, Size2 = 0.3, Lifetime1 = 0.2, Lifetime2 = 1, Parent = ra, Emit = 900, Offset = 360, Enabled = true})
| |
| 1296 | --PRT.LockedToPart = true | |
| 1297 | local PRT = ParticleEmitter({Speed = 0.3, Drag = 3, Size1 = 1.1, Size2 = 0.3, Lifetime1 = 0.2, Lifetime2 = 1, Parent = la, Emit = 900, Offset = 360, Enabled = true})
| |
| 1298 | --PRT.LockedToPart = true | |
| 1299 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
| 1300 | local NEWWELD = IT(TYPE) | |
| 1301 | NEWWELD.Part0 = PART0 | |
| 1302 | NEWWELD.Part1 = PART1 | |
| 1303 | NEWWELD.C0 = C0 | |
| 1304 | NEWWELD.C1 = C1 | |
| 1305 | NEWWELD.Parent = PARENT | |
| 1306 | return NEWWELD | |
| 1307 | end | |
| 1308 | ||
| 1309 | function MakeForm(PART,TYPE) | |
| 1310 | local MSH = nil | |
| 1311 | if TYPE == "Cyl" then | |
| 1312 | MSH = IT("CylinderMesh",PART)
| |
| 1313 | elseif TYPE == "Ball" then | |
| 1314 | MSH = IT("SpecialMesh",PART)
| |
| 1315 | MSH.MeshType = "Sphere" | |
| 1316 | elseif TYPE == "Wedge" then | |
| 1317 | MSH = IT("SpecialMesh",PART)
| |
| 1318 | MSH.MeshType = "Wedge" | |
| 1319 | elseif TYPE == "Block" then | |
| 1320 | MSH = IT("SpecialMesh",PART)
| |
| 1321 | MSH.MeshType = "Brick" | |
| 1322 | end | |
| 1323 | return MSH | |
| 1324 | end | |
| 1325 | ||
| 1326 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
| 1327 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
| 1328 | end | |
| 1329 | ||
| 1330 | function Sink(position,radius) | |
| 1331 | for i,v in ipairs(workspace:GetChildren()) do | |
| 1332 | if v:FindFirstChild("Hit2By"..plr.Name) == nil then
| |
| 1333 | local body = v:GetChildren() | |
| 1334 | for part = 1, #body do | |
| 1335 | if(v:FindFirstChild("Hit2By"..plr.Name) == nil and (body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= char) then
| |
| 1336 | if(body[part].Position - position).Magnitude < radius then | |
| 1337 | if v.ClassName == "Model" then | |
| 1338 | v:FindFirstChildOfClass("Humanoid").Name = "Humanoid"
| |
| 1339 | if v:FindFirstChild("Humanoid") then
| |
| 1340 | local defence = Instance.new("BoolValue",v)
| |
| 1341 | defence.Name = ("Hit2By"..plr.Name)
| |
| 1342 | if v.Humanoid.Health ~= 0 then | |
| 1343 | local TORS = v:FindFirstChild("HumanoidRootPart") or v:FindFirstChild("Torso") or v:FindFirstChild("UpperTorso")
| |
| 1344 | if TORS ~= nil then | |
| 1345 | local HITFLOOR2, HITPOS2 = Raycast(TORS.Position, (CF(TORS.Position, TORS.Position + Vector3.new(0, -1, 0))).lookVector, 25 * TORS.Size.Y/2, v) | |
| 1346 | coroutine.resume(coroutine.create(function() | |
| 1347 | if HITFLOOR2 ~= nil then | |
| 1348 | TORS.Anchored = true | |
| 1349 | local Hole2 = CreatePart(3, EffectModel, "Neon", 0, 0, "Really black", "Hole", Vector3.new(TORS.Size.X*4,0,TORS.Size.X*4)) | |
| 1350 | Hole2.Color = Color3.new(0,0,0) | |
| 1351 | local MESH = MakeForm(Hole2,"Cyl") | |
| 1352 | MESH.Scale = Vector3.new(0,1,0) | |
| 1353 | Hole2.CFrame = CF(HITPOS2) | |
| 1354 | for i = 1, 10 do | |
| 1355 | swait() | |
| 1356 | MESH.Scale = MESH.Scale + Vector3.new(0.1,0,0.1) | |
| 1357 | end | |
| 1358 | --Cso("160440683", v:FindFirstChild("Head"), 10, .8)
| |
| 1359 | Cso("154955269", v:FindFirstChild("Head"), 10, 1)
| |
| 1360 | repeat | |
| 1361 | swait() | |
| 1362 | TORS.CFrame = TORS.CFrame * CF(0,-0.1,0) | |
| 1363 | --MESH.Scale = MESH.Scale + Vector3.new(0,1.6,0) | |
| 1364 | until TORS.Position.Y<position.Y-4 | |
| 1365 | v:remove() | |
| 1366 | for i = 1, 10 do | |
| 1367 | swait() | |
| 1368 | MESH.Scale = MESH.Scale - Vector3.new(0.1,0,0.1) | |
| 1369 | end | |
| 1370 | Hole2:remove() | |
| 1371 | end | |
| 1372 | end)) | |
| 1373 | end | |
| 1374 | end | |
| 1375 | end | |
| 1376 | end | |
| 1377 | --body[part].Velocity = CFrame.new(position,body[part].Position).lookVector*5*maxstrength | |
| 1378 | end | |
| 1379 | end | |
| 1380 | end | |
| 1381 | end | |
| 1382 | end | |
| 1383 | end | |
| 1384 | function Trail(Part) | |
| 1385 | local TRAIL = Part:Clone() | |
| 1386 | TRAIL.CanCollide = false | |
| 1387 | TRAIL.Anchored = true | |
| 1388 | TRAIL.Parent = EffectModel | |
| 1389 | TRAIL.Name = "Trail" | |
| 1390 | local TRANS = Part.Transparency | |
| 1391 | coroutine.resume(coroutine.create(function() | |
| 1392 | for i = 1, 20 do | |
| 1393 | swait() | |
| 1394 | TRAIL.Transparency = TRAIL.Transparency + ((1-TRANS)/20) | |
| 1395 | end | |
| 1396 | TRAIL:remove() | |
| 1397 | end)) | |
| 1398 | end | |
| 1399 | function getRegion(point,range,ignore) | |
| 1400 | return workspace:FindPartsInRegion3WithIgnoreList(Region3.new(point-Vector3.new(1,1,1)*range/2,point+Vector3.new(1,1,1)*range/2),ignore,100) | |
| 1401 | end | |
| 1402 | ||
| 1403 | function GetTorso(char) | |
| 1404 | return char:FindFirstChild'Torso' or char:FindFirstChild'UpperTorso' or char:FindFirstChild'LowerTorso' or char:FindFirstChild'HumanoidRootPart' | |
| 1405 | end | |
| 1406 | ||
| 1407 | local M = {C=math.cos,R=math.rad,S=math.sin,P=math.pi,RNG=math.random,MRS=math.randomseed,H=math.huge,RRNG = function(min,max,div) return math.rad(math.random(min,max)/(div or 1)) end}
| |
| 1408 | ||
| 1409 | NewInstance = function(instance,parent,properties) | |
| 1410 | local inst = Instance.new(instance) | |
| 1411 | inst.Parent = parent | |
| 1412 | if(properties)then | |
| 1413 | for i,v in next, properties do | |
| 1414 | pcall(function() inst[i] = v end) | |
| 1415 | end | |
| 1416 | end | |
| 1417 | return inst; | |
| 1418 | end | |
| 1419 | ||
| 1420 | function Part(parent,color,material,size,cframe,anchored,cancollide) | |
| 1421 | local part = Instance.new("Part")
| |
| 1422 | part[typeof(color) == 'BrickColor' and 'BrickColor' or 'Color'] = color or Color3.new(0,0,0) | |
| 1423 | part.Material = material or Enum.Material.SmoothPlastic | |
| 1424 | part.TopSurface,part.BottomSurface=10,10 | |
| 1425 | part.Size = size or Vector3.new(1,1,1) | |
| 1426 | part.CFrame = cframe or CF(0,0,0) | |
| 1427 | part.Anchored = anchored or true | |
| 1428 | part.CanCollide = cancollide or false | |
| 1429 | part.Parent = parent or char | |
| 1430 | return part | |
| 1431 | end | |
| 1432 | ------------------------------------------------------- | |
| 1433 | --End Important Functions-- | |
| 1434 | ------------------------------------------------------- | |
| 1435 | ||
| 1436 | ||
| 1437 | ------------------------------------------------------- | |
| 1438 | --Start Customization-- | |
| 1439 | ------------------------------------------------------- | |
| 1440 | local Player_Size = 1 | |
| 1441 | if Player_Size ~= 1 then | |
| 1442 | root.Size = root.Size * Player_Size | |
| 1443 | tors.Size = tors.Size * Player_Size | |
| 1444 | hed.Size = hed.Size * Player_Size | |
| 1445 | ra.Size = ra.Size * Player_Size | |
| 1446 | la.Size = la.Size * Player_Size | |
| 1447 | rl.Size = rl.Size * Player_Size | |
| 1448 | ll.Size = ll.Size * Player_Size | |
| 1449 | ---------------------------------------------------------------------------------- | |
| 1450 | rootj.Parent = root | |
| 1451 | neck.Parent = tors | |
| 1452 | RW.Parent = tors | |
| 1453 | LW.Parent = tors | |
| 1454 | RH.Parent = tors | |
| 1455 | LH.Parent = tors | |
| 1456 | ---------------------------------------------------------------------------------- | |
| 1457 | rootj.C0 = RootCF * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) | |
| 1458 | rootj.C1 = RootCF * CF(0 * Player_Size, 0 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) | |
| 1459 | neck.C0 = necko * CF(0 * Player_Size, 0 * Player_Size, 0 + ((1 * Player_Size) - 1)) * angles(Rad(0), Rad(0), Rad(0)) | |
| 1460 | neck.C1 = CF(0 * Player_Size, -0.5 * Player_Size, 0 * Player_Size) * angles(Rad(-90), Rad(0), Rad(180)) | |
| 1461 | RW.C0 = CF(1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) --* RIGHTSHOULDERC0 | |
| 1462 | LW.C0 = CF(-1.5 * Player_Size, 0.5 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(0), Rad(0)) --* LEFTSHOULDERC0 | |
| 1463 | ---------------------------------------------------------------------------------- | |
| 1464 | RH.C0 = CF(1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
| 1465 | LH.C0 = CF(-1 * Player_Size, -1 * Player_Size, 0 * Player_Size) * angles(Rad(0), Rad(-90), Rad(0)) * angles(Rad(0), Rad(0), Rad(0)) | |
| 1466 | RH.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)) | |
| 1467 | LH.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)) | |
| 1468 | --hat.Parent = Character | |
| 1469 | end | |
| 1470 | ---------------------------------------------------------------------------------- | |
| 1471 | local SONG = 660140936 | |
| 1472 | local SONG2 = 0 | |
| 1473 | local Music = Instance.new("Sound",tors)
| |
| 1474 | Music.Volume = 2.5 | |
| 1475 | Music.Looped = true | |
| 1476 | Music.Pitch = 1 --Pitcher | |
| 1477 | ---------------------------------------------------------------------------------- | |
| 1478 | local equipped = false | |
| 1479 | local idle = 0 | |
| 1480 | local change = 1 | |
| 1481 | local val = 0 | |
| 1482 | local toim = 0 | |
| 1483 | local idleanim = 0.4 | |
| 1484 | local sine = 0 | |
| 1485 | local Sit = 1 | |
| 1486 | local Mode = "Normal" | |
| 1487 | ---------------------------------------------------------------------------------- | |
| 1488 | hum.WalkSpeed = 16 | |
| 1489 | hum.JumpPower = 57 | |
| 1490 | --hum.Animator.Parent = nil | |
| 1491 | ---------------------------------------------------------------------------------- | |
| 1492 | local Hole = CreatePart(3, EffectModel, "Neon", 0, 0, "Really black", "Hole", Vector3.new(5,0,5)) | |
| 1493 | local MESH = MakeForm(Hole,"Cyl") | |
| 1494 | local ROBLOXIDLEANIMATION = IT("Animation")
| |
| 1495 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
| 1496 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
| 1497 | local ANIMATOR = hum.Animator | |
| 1498 | local ANIMATE = char.Animate | |
| 1499 | ------------------------------------------------------- | |
| 1500 | --End Customization-- | |
| 1501 | ------------------------------------------------------- | |
| 1502 | ||
| 1503 | ||
| 1504 | ------------------------------------------------------- | |
| 1505 | --Start Attacks N Stuff-- | |
| 1506 | ------------------------------------------------------- | |
| 1507 | function InkyWarp() | |
| 1508 | attack = true | |
| 1509 | attack = true | |
| 1510 | hum.WalkSpeed = 0 | |
| 1511 | root.Anchored = true | |
| 1512 | for i = 0, 4, 0.1 do | |
| 1513 | swait() | |
| 1514 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0 - 0.04 * Sin(sine / 24) * Player_Size, 0 + 0.04 * Sin(sine / 12) * Player_Size, 0 + 0.05 * Player_Size * Cos(sine / 12)) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(0 - 2.5 * Sin(sine / 24)), Rad(0)), 0.15) | |
| 1515 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(0), Rad(20 * Cos(sine / 12))), 0.3) | |
| 1516 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size + 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(84), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1517 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-84), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1518 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(-6 + 4.5 * Sin(sine / 12)), Rad(25 + 2.5 * Sin(sine / 12)), Rad(25 + 4.5 * Sin(sine / 12))), 0.1) | |
| 1519 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(7 + 4.5 * Sin(sine / 12)), Rad(0 + 2.5 * Sin(sine / 12)), Rad(-13 - 4.5 * Sin(sine / 12))), 0.1) | |
| 1520 | end | |
| 1521 | for i = 0, 2, 0.1 do | |
| 1522 | swait() | |
| 1523 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0 - 0.04 * Sin(sine / 24) * Player_Size, 0 + 0.04 * Sin(sine / 12) * Player_Size, -15 + 0.05 * Player_Size * Cos(sine / 12)) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(0 - 2.5 * Sin(sine / 24)), Rad(0)), 0.15) | |
| 1524 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(0), Rad(20 * Cos(sine / 12))), 0.3) | |
| 1525 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size + 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(84), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1526 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-84), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1527 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(-6 + 4.5 * Sin(sine / 12)), Rad(25 + 2.5 * Sin(sine / 12)), Rad(25 + 4.5 * Sin(sine / 12))), 0.1) | |
| 1528 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(7 + 4.5 * Sin(sine / 12)), Rad(0 + 2.5 * Sin(sine / 12)), Rad(-13 - 4.5 * Sin(sine / 12))), 0.1) | |
| 1529 | end | |
| 1530 | for i = 1, 50 do | |
| 1531 | swait() | |
| 1532 | Trail(Hole) | |
| 1533 | MESH.Scale = MESH.Scale - Vector3.new(0.02,0,0.02) | |
| 1534 | end | |
| 1535 | local ORIGINPOS = root.Position | |
| 1536 | root.CFrame = CF(Vector3.new(mouse.Hit.p.X,root.Position.Y,mouse.Hit.p.Z),ORIGINPOS) | |
| 1537 | Cso("154955269", tors, 10, .8)
| |
| 1538 | for i = 1, 50 do | |
| 1539 | swait() | |
| 1540 | MESH.Scale = MESH.Scale + Vector3.new(0.02,0,0.02) | |
| 1541 | end | |
| 1542 | for i = 0, 4, 0.1 do | |
| 1543 | swait() | |
| 1544 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0 - 0.04 * Sin(sine / 24) * Player_Size, 0 + 0.04 * Sin(sine / 12) * Player_Size, 0 + 0.05 * Player_Size * Cos(sine / 12)) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(0 - 2.5 * Sin(sine / 24)), Rad(0)), 0.15) | |
| 1545 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(0), Rad(20 * Cos(sine / 12))), 0.3) | |
| 1546 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size + 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(84), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1547 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-84), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1548 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(-6 + 4.5 * Sin(sine / 12)), Rad(25 + 2.5 * Sin(sine / 12)), Rad(25 + 4.5 * Sin(sine / 12))), 0.1) | |
| 1549 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(7 + 4.5 * Sin(sine / 12)), Rad(0 + 2.5 * Sin(sine / 12)), Rad(-13 - 4.5 * Sin(sine / 12))), 0.1) | |
| 1550 | end | |
| 1551 | attack = false | |
| 1552 | hum.WalkSpeed = 16 | |
| 1553 | root.Anchored = false | |
| 1554 | end | |
| 1555 | ||
| 1556 | ------------------------------------------------------- | |
| 1557 | --End Attacks N Stuff-- | |
| 1558 | ------------------------------------------------------- | |
| 1559 | mouse.KeyDown:connect(function(key) | |
| 1560 | if attack == false then | |
| 1561 | if key == 'z' then | |
| 1562 | InkyWarp() | |
| 1563 | elseif key == 'p' and Mode == "Normal" then | |
| 1564 | Mode = "Chase" | |
| 1565 | SONG = 1634663187 | |
| 1566 | hum.WalkSpeed = 28 | |
| 1567 | elseif key == 'p' and Mode == "Chase" then | |
| 1568 | Mode = "Normal" | |
| 1569 | SONG = 660140936 | |
| 1570 | hum.WalkSpeed = 16 | |
| 1571 | end | |
| 1572 | end | |
| 1573 | end) | |
| 1574 | ||
| 1575 | ||
| 1576 | ||
| 1577 | ||
| 1578 | ||
| 1579 | ||
| 1580 | ||
| 1581 | ||
| 1582 | ------------------------------------------------------- | |
| 1583 | --Start Animations-- | |
| 1584 | ------------------------------------------------------- | |
| 1585 | print("By Makhail07")
| |
| 1586 | coroutine.resume(coroutine.create(function() | |
| 1587 | while wait() do | |
| 1588 | if hitfloor ~= nil then | |
| 1589 | Hole.CFrame = CF(posfloor) | |
| 1590 | end | |
| 1591 | Sink(Hole.Position, Hole.Size.X/2.2 * MESH.Scale.X) | |
| 1592 | Hole.Color = Color3.new(0,0,0) | |
| 1593 | Trail(Hole) | |
| 1594 | end | |
| 1595 | end)) | |
| 1596 | while true do | |
| 1597 | swait() | |
| 1598 | sine = sine + change | |
| 1599 | ANIMATE.Parent = nil | |
| 1600 | local IDLEANIMATION = hum:LoadAnimation(ROBLOXIDLEANIMATION) | |
| 1601 | IDLEANIMATION:Play() | |
| 1602 | local torvel = (root.Velocity * Vector3.new(1, 0, 1)).magnitude | |
| 1603 | local velderp = root.Velocity.y | |
| 1604 | hitfloor, posfloor = rayCast(root.Position, CFrame.new(root.Position, root.Position - Vector3.new(0, 1, 0)).lookVector, 4 * Player_Size, char) | |
| 1605 | if equipped == true or equipped == false then | |
| 1606 | if attack == false then | |
| 1607 | idle = idle + 1 | |
| 1608 | else | |
| 1609 | idle = 0 | |
| 1610 | end | |
| 1611 | if 1 < root.Velocity.y and hitfloor == nil then | |
| 1612 | Anim = "Jump" | |
| 1613 | if attack == false then | |
| 1614 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.1 + 0.1 * Cos(sine / 20)* Player_Size) * angles(Rad(-16), Rad(0), Rad(0)), 0.15) | |
| 1615 | neck.C0 = clerp(neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(0 - 2.5 * Sin(sine / 30)), Rad(0), Rad(0)), 0.3) | |
| 1616 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -0.9 - 0.1 * Cos(sine / 20)* Player_Size, 0* Player_Size) * RHCF * angles(Rad(-6.5), Rad(0), Rad(0)), 0.15) | |
| 1617 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -.9 - 0.1 * Cos(sine / 20), -.5* Player_Size) * LHCF * angles(Rad(-6.5), Rad(0), Rad(0)), 0.15) | |
| 1618 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(25), Rad(-.6), Rad(13 + 4.5 * Sin(sine / 20))), 0.1) | |
| 1619 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(25), Rad(-.6), Rad(-13 - 4.5 * Sin(sine / 20))), 0.1) | |
| 1620 | end | |
| 1621 | elseif -1 > root.Velocity.y and hitfloor == nil then | |
| 1622 | Anim = "Fall" | |
| 1623 | if attack == false then | |
| 1624 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.1 + 0.1 * Cos(sine / 20)* Player_Size) * angles(Rad(15), Rad(0), Rad(0)), 0.15) | |
| 1625 | neck.C0 = clerp(neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(10 - 2.5 * Sin(sine / 30)), Rad(0), Rad(0)), 0.3) | |
| 1626 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -1 - 0.1 * Cos(sine / 20)* Player_Size, 0* Player_Size) * RHCF * angles(Rad(-9.5), Rad(0), Rad(20)), 0.15) | |
| 1627 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -.4 - 0.1 * Cos(sine / 20)* Player_Size, -.5* Player_Size) * LHCF * angles(Rad(-9.5), Rad(0), Rad(20)), 0.15) | |
| 1628 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(65), Rad(-.6), Rad(75 + 4.5 * Sin(sine / 20))), 0.1) | |
| 1629 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.02 * Sin(sine / 20)* Player_Size, 0* Player_Size) * angles(Rad(55), Rad(-.6), Rad(-75 - 4.5 * Sin(sine / 20))), 0.1) | |
| 1630 | end | |
| 1631 | elseif torvel < 1 and hitfloor ~= nil then | |
| 1632 | Anim = "Idle" | |
| 1633 | change = 1 | |
| 1634 | if attack == false then | |
| 1635 | if Mode == "Normal" then | |
| 1636 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0 - 0.04 * Sin(sine / 24) * Player_Size, 0 + 0.04 * Sin(sine / 12) * Player_Size, 0 + 0.05 * Player_Size * Cos(sine / 12)) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(0 - 2.5 * Sin(sine / 24)), Rad(0)), 0.15) | |
| 1637 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(25 - 6.5 * Cos(sine / 12)), Rad(0), Rad(20 * Cos(sine / 12))), 0.3) | |
| 1638 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size + 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(84), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1639 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-84), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1640 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(-6 + 4.5 * Sin(sine / 12)), Rad(25 + 2.5 * Sin(sine / 12)), Rad(25 + 4.5 * Sin(sine / 12))), 0.1) | |
| 1641 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(7 + 4.5 * Sin(sine / 12)), Rad(0 + 2.5 * Sin(sine / 12)), Rad(-13 - 4.5 * Sin(sine / 12))), 0.1) | |
| 1642 | elseif Mode == "Chase" then | |
| 1643 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0 - 0.04 * Sin(sine / 24) * Player_Size, 0 + 0.04 * Sin(sine / 12) * Player_Size, 0 + 0.05 * Player_Size * Cos(sine / 12)) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(0 - 2.5 * Sin(sine / 24)), Rad(0)), 0.15) | |
| 1644 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(-6.5 * Cos(sine / 12)), Rad(10), Rad(0)), 0.3) | |
| 1645 | RH.C0 = clerp(RH.C0, CF(1 * Player_Size, -1 * Player_Size + 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(84), Rad(0)) * angles(Rad(-6 - 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1646 | LH.C0 = clerp(LH.C0, CF(-1 * Player_Size, -1 * Player_Size - 0.06 * Sin(sine / 24) - 0.05 * Player_Size * Cos(sine / 12), -0.01 * Player_Size) * angles(Rad(0 - 2.5 * Sin(sine / 12)), Rad(-84), Rad(0)) * angles(Rad(-6 + 2.5 * Sin(sine / 24)), Rad(0), Rad(0)), 0.15) | |
| 1647 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(-6 + 4.5 * Sin(sine / 12)), Rad(25 + 2.5 * Sin(sine / 12)), Rad(5)), 0.1) | |
| 1648 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.35 + 0.15 * Cos(sine / 12)* Player_Size, 0* Player_Size) * angles(Rad(7 + 4.5 * Sin(sine / 12)), Rad(0 + 2.5 * Sin(sine / 12)), Rad(-5)), 0.1) | |
| 1649 | end | |
| 1650 | end | |
| 1651 | elseif (tors.Velocity).magnitude < 200 and hitfloor ~= nil then | |
| 1652 | Anim = "Walk" | |
| 1653 | change = 1.1 | |
| 1654 | if attack == false then | |
| 1655 | if Mode == "Normal" then | |
| 1656 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.175 + 0.13 * Cos(sine / 3.5) + -Sin(sine / 3.5) / 7* Player_Size) * angles(Rad(3 - 2.5 * Cos(sine / 3.5)), Rad(0) - root.RotVelocity.Y / 75, Rad(10 * Cos(sine / 7))), 0.15) | |
| 1657 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(0), Rad(0), Rad(0) - hed.RotVelocity.Y / 15), 0.3) | |
| 1658 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -0.8 - 0.5 * Cos(sine / 7) / 2* Player_Size, 0.6 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-10 - 25 * Cos(sine / 7)) - rl.RotVelocity.Y / 75 + -Sin(sine / 7) / 2.5, Rad(90 - 15 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 + 2 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
| 1659 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -0.8 + 0.5 * Cos(sine / 7) / 2* Player_Size, -0.6 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-10 + 25 * Cos(sine / 7)) + ll.RotVelocity.Y / 75 + Sin(sine / 7) / 2.5, Rad(-90 - 15 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 - 2 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
| 1660 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 7)* Player_Size, 0* Player_Size) * angles(Rad(57) * Cos(sine / 7) , Rad(10 * Cos(sine / 7)), Rad(10) - ra.RotVelocity.Y / 75), 0.1) | |
| 1661 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 7)* Player_Size, 0* Player_Size) * angles(Rad(-57) * Cos(sine / 7) , Rad(10 * Cos(sine / 7)) , Rad(-10) + la.RotVelocity.Y / 75), 0.1) | |
| 1662 | elseif Mode == "Chase" then | |
| 1663 | rootj.C0 = clerp(rootj.C0, RootCF * CF(0* Player_Size, 0* Player_Size, -0.175 + 0.13 * Cos(sine / 3.5) + -Sin(sine / 3.5) / 7* Player_Size) * angles(Rad(3 - 2.5 * Cos(sine / 3.5)), Rad(0) - root.RotVelocity.Y / 75, Rad(17 + 8 * Cos(sine / 7))), 0.15) | |
| 1664 | tors.Neck.C0 = clerp(tors.Neck.C0, necko* CF(0, 0, 0 + ((1* Player_Size) - 1)) * angles(Rad(0), Rad(0), Rad(-17) - hed.RotVelocity.Y / 15), 0.3) | |
| 1665 | RH.C0 = clerp(RH.C0, CF(1* Player_Size, -0.8 - 0.5 * Cos(sine / 7) / 2* Player_Size, 0.6 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-15 - 5 * Cos(sine / 7)) - rl.RotVelocity.Y / 75 + -Sin(sine / 7) / 2.5, Rad(90 - 15 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 + 2 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
| 1666 | LH.C0 = clerp(LH.C0, CF(-1* Player_Size, -0.8 + 0.5 * Cos(sine / 7) / 2* Player_Size, -0.6 * Cos(sine / 7) / 2* Player_Size) * angles(Rad(-15 + 5 * Cos(sine / 7)) + ll.RotVelocity.Y / 75 + Sin(sine / 7) / 2.5, Rad(-90 - 15 * Cos(sine / 7)), Rad(0)) * angles(Rad(0 - 2 * Cos(sine / 7)), Rad(0), Rad(0)), 0.3) | |
| 1667 | RW.C0 = clerp(RW.C0, CF(1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 7)* Player_Size, 0* Player_Size) * angles(Rad(90) , Rad(10 * Cos(sine / 7)), Rad(28) - ra.RotVelocity.Y / 75), 0.1) | |
| 1668 | LW.C0 = clerp(LW.C0, CF(-1.5* Player_Size, 0.5 + 0.05 * Sin(sine / 7)* Player_Size, 0* Player_Size) * angles(Rad(-57) * Cos(sine / 7) , Rad(10 * Cos(sine / 7)) , Rad(-10) + la.RotVelocity.Y / 75), 0.1) | |
| 1669 | end | |
| 1670 | end | |
| 1671 | end | |
| 1672 | end | |
| 1673 | for _, c in pairs(char:GetDescendants()) do | |
| 1674 | if c.ClassName == "Part" and c.Name ~= "Eye" and c.Parent ~= Effects and c.Parent.Parent ~= Effects then | |
| 1675 | c.Material = "Neon" | |
| 1676 | c.Color = Color3.new(0,0,0) | |
| 1677 | if c:FindFirstChildOfClass("SpecialMesh") then
| |
| 1678 | c:FindFirstChildOfClass("SpecialMesh").TextureId = ""
| |
| 1679 | end | |
| 1680 | if c == hed then | |
| 1681 | if c:FindFirstChild("face") then
| |
| 1682 | c.face:remove() | |
| 1683 | end | |
| 1684 | end | |
| 1685 | elseif c.ClassName == "Part" and c.Name == "Eye" then | |
| 1686 | c.Color = Color3.new(1,0,0) | |
| 1687 | c.Material = "Neon" | |
| 1688 | elseif c.ClassName == "CharacterMesh" or c.Name == "Body Colors" then | |
| 1689 | c:remove() | |
| 1690 | elseif (c.ClassName == "Shirt" or c.ClassName == "Pants") and c.Name ~= "Cloth" then | |
| 1691 | c:remove() | |
| 1692 | end | |
| 1693 | end | |
| 1694 | Music.SoundId = "rbxassetid://"..SONG | |
| 1695 | Music.Looped = true | |
| 1696 | Music.Pitch = 1 | |
| 1697 | Music.Volume = 5 | |
| 1698 | Music.Parent = tors | |
| 1699 | Music:Resume() | |
| 1700 | if 0 < #Effects then | |
| 1701 | for e = 1, #Effects do | |
| 1702 | if Effects[e] ~= nil then | |
| 1703 | local Thing = Effects[e] | |
| 1704 | if Thing ~= nil then | |
| 1705 | local Part = Thing[1] | |
| 1706 | local Mode = Thing[2] | |
| 1707 | local Delay = Thing[3] | |
| 1708 | local IncX = Thing[4] | |
| 1709 | local IncY = Thing[5] | |
| 1710 | local IncZ = Thing[6] | |
| 1711 | if 1 >= Thing[1].Transparency then | |
| 1712 | if Thing[2] == "Block1" then | |
| 1713 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) | |
| 1714 | local Mesh = Thing[1].Mesh | |
| 1715 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1716 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1717 | elseif Thing[2] == "Block2" then | |
| 1718 | Thing[1].CFrame = Thing[1].CFrame + Vector3.new(0, 0, 0) | |
| 1719 | local Mesh = Thing[7] | |
| 1720 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1721 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1722 | elseif Thing[2] == "Block3" then | |
| 1723 | Thing[1].CFrame = Thing[1].CFrame * CFrame.fromEulerAnglesXYZ(math.random(-50, 50), math.random(-50, 50), math.random(-50, 50)) + Vector3.new(0, 0.15, 0) | |
| 1724 | local Mesh = Thing[7] | |
| 1725 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1726 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1727 | elseif Thing[2] == "Cylinder" then | |
| 1728 | local Mesh = Thing[1].Mesh | |
| 1729 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1730 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1731 | elseif Thing[2] == "Blood" then | |
| 1732 | local Mesh = Thing[7] | |
| 1733 | Thing[1].CFrame = Thing[1].CFrame * Vector3.new(0, 0.5, 0) | |
| 1734 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[4], Thing[5], Thing[6]) | |
| 1735 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1736 | elseif Thing[2] == "Elec" then | |
| 1737 | local Mesh = Thing[1].Mesh | |
| 1738 | Mesh.Scale = Mesh.Scale + Vector3.new(Thing[7], Thing[8], Thing[9]) | |
| 1739 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1740 | elseif Thing[2] == "Disappear" then | |
| 1741 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1742 | elseif Thing[2] == "Shatter" then | |
| 1743 | Thing[1].Transparency = Thing[1].Transparency + Thing[3] | |
| 1744 | Thing[4] = Thing[4] * CFrame.new(0, Thing[7], 0) | |
| 1745 | Thing[1].CFrame = Thing[4] * CFrame.fromEulerAnglesXYZ(Thing[6], 0, 0) | |
| 1746 | Thing[6] = Thing[6] + Thing[5] | |
| 1747 | end | |
| 1748 | else | |
| 1749 | Part.Parent = nil | |
| 1750 | table.remove(Effects, e) | |
| 1751 | end | |
| 1752 | end | |
| 1753 | end | |
| 1754 | end | |
| 1755 | end | |
| 1756 | end | |
| 1757 | ------------------------------------------------------- | |
| 1758 | --End Animations And Script-- | |
| 1759 | ------------------------------------------------------- |