SHOW:
|
|
- or go back to the newest paste.
| 1 | ||
| 2 | ||
| 3 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
| |
| 4 | local Player,game,owner = owner,game | |
| 5 | local RealPlayer = Player | |
| 6 | do | |
| 7 | print("FE Compatibility code by retram")
| |
| 8 | local rp = RealPlayer | |
| 9 | script.Parent = rp.Character | |
| 10 | ||
| 11 | --RemoteEvent for communicating | |
| 12 | local Event = Instance.new("RemoteEvent")
| |
| 13 | Event.Name = "UserInput_Event" | |
| 14 | ||
| 15 | --Fake event to make stuff like Mouse.KeyDown work | |
| 16 | local function fakeEvent() | |
| 17 | local t = {_fakeEvent=true,Functions={},Connect=function(self,f)table.insert(self.Functions,f) end}
| |
| 18 | t.connect = t.Connect | |
| 19 | return t | |
| 20 | end | |
| 21 | ||
| 22 | --Creating fake input objects with fake variables | |
| 23 | local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent(),Button2Up=fakeEvent(),Button2Down=fakeEvent()}
| |
| 24 | local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
| |
| 25 | local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
| |
| 26 | CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
| |
| 27 | end} | |
| 28 | --Merged 2 functions into one by checking amount of arguments | |
| 29 | CAS.UnbindAction = CAS.BindAction | |
| 30 | ||
| 31 | --This function will trigger the events that have been :Connect()'ed | |
| 32 | local function te(self,ev,...) | |
| 33 | local t = m[ev] | |
| 34 | if t and t._fakeEvent then | |
| 35 | for _,f in pairs(t.Functions) do | |
| 36 | f(...) | |
| 37 | end | |
| 38 | end | |
| 39 | end | |
| 40 | m.TrigEvent = te | |
| 41 | UIS.TrigEvent = te | |
| 42 | ||
| 43 | Event.OnServerEvent:Connect(function(plr,io) | |
| 44 | if plr~=rp then return end | |
| 45 | m.Target = io.Target | |
| 46 | m.Hit = io.Hit | |
| 47 | if not io.isMouse then | |
| 48 | local b = io.UserInputState == Enum.UserInputState.Begin | |
| 49 | if io.UserInputType == Enum.UserInputType.MouseButton1 then | |
| 50 | return m:TrigEvent(b and "Button1Down" or "Button1Up") | |
| 51 | end | |
| 52 | if io.UserInputType == Enum.UserInputType.MouseButton2 then | |
| 53 | return m:TrigEvent(b and "Button2Down" or "Button2Up") | |
| 54 | end | |
| 55 | for _,t in pairs(CAS.Actions) do | |
| 56 | for _,k in pairs(t.Keys) do | |
| 57 | if k==io.KeyCode then | |
| 58 | t.Function(t.Name,io.UserInputState,io) | |
| 59 | end | |
| 60 | end | |
| 61 | end | |
| 62 | m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower()) | |
| 63 | UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false) | |
| 64 | end | |
| 65 | end) | |
| 66 | Event.Parent = NLS([==[ | |
| 67 | local Player = game:GetService("Players").LocalPlayer
| |
| 68 | local Event = script:WaitForChild("UserInput_Event")
| |
| 69 | local Mouse = Player:GetMouse() | |
| 70 | local UIS = game:GetService("UserInputService")
| |
| 71 | local input = function(io,a) | |
| 72 | if a then return end | |
| 73 | --Since InputObject is a client-side instance, we create and pass table instead | |
| 74 | Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState,Hit=Mouse.Hit,Target=Mouse.Target})
| |
| 75 | end | |
| 76 | UIS.InputBegan:Connect(input) | |
| 77 | UIS.InputEnded:Connect(input) | |
| 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 | |
| 97 | return typeof(s[k])=="function" | |
| 98 | and function(_,...)return s[k](s,...)end or s[k] | |
| 99 | end | |
| 100 | end, | |
| 101 | __newindex = function(self,k,v) | |
| 102 | local s = rawget(self,"_RealService") | |
| 103 | if s then s[k]=v end | |
| 104 | end | |
| 105 | } | |
| 106 | local function FakeService(t,RealService) | |
| 107 | t._RealService = typeof(RealService)=="string" and _rg:GetService(RealService) or RealService | |
| 108 | return setmetatable(t,fsmt) | |
| 109 | end | |
| 110 | ||
| 111 | --Fake game object | |
| 112 | local g = {
| |
| 113 | GetService = function(self,s) | |
| 114 | return rawget(self,s) or _rg:GetService(s) | |
| 115 | end, | |
| 116 | Players = FakeService({
| |
| 117 | LocalPlayer = FakeService({GetMouse=function(self)return m end},Player)
| |
| 118 | },"Players"), | |
| 119 | UserInputService = FakeService(UIS,"UserInputService"), | |
| 120 | ContextActionService = FakeService(CAS,"ContextActionService"), | |
| 121 | RunService = FakeService({
| |
| 122 | _btrs = {},
| |
| 123 | RenderStepped = _rg:GetService("RunService").Heartbeat,
| |
| 124 | BindToRenderStep = function(self,name,_,fun) | |
| 125 | self._btrs[name] = self.Heartbeat:Connect(fun) | |
| 126 | end, | |
| 127 | UnbindFromRenderStep = function(self,name) | |
| 128 | self._btrs[name]:Disconnect() | |
| 129 | end, | |
| 130 | },"RunService") | |
| 131 | } | |
| 132 | rawset(g.Players,"localPlayer",g.Players.LocalPlayer) | |
| 133 | g.service = g.GetService | |
| 134 | FakeService(g,game) | |
| 135 | --Changing owner to fake player object to support owner:GetMouse() | |
| 136 | game,owner = g,g.Players.LocalPlayer | |
| 137 | end --//====================================================\\-- | |
| 138 | --|| CREATED BY SHACKLUSTER | |
| 139 | --\\====================================================//-- | |
| 140 | ||
| 141 | wait(0.2) | |
| 142 | ||
| 143 | Player = game:GetService("Players").LocalPlayer
| |
| 144 | PlayerGui = Player.PlayerGui | |
| 145 | Cam = workspace.CurrentCamera | |
| 146 | Backpack = Player.Backpack | |
| 147 | Character = Player.Character | |
| 148 | Humanoid = Character.Humanoid | |
| 149 | Mouse = Player:GetMouse() | |
| 150 | RootPart = Character["HumanoidRootPart"] | |
| 151 | Torso = Character["Torso"] | |
| 152 | Head = Character["Head"] | |
| 153 | RightArm = Character["Right Arm"] | |
| 154 | LeftArm = Character["Left Arm"] | |
| 155 | RightLeg = Character["Right Leg"] | |
| 156 | LeftLeg = Character["Left Leg"] | |
| 157 | RootJoint = RootPart["RootJoint"] | |
| 158 | Neck = Torso["Neck"] | |
| 159 | RightShoulder = Torso["Right Shoulder"] | |
| 160 | LeftShoulder = Torso["Left Shoulder"] | |
| 161 | RightHip = Torso["Right Hip"] | |
| 162 | LeftHip = Torso["Left Hip"] | |
| 163 | local sick = Instance.new("Sound",Character)
| |
| 164 | sick.SoundId = "rbxassetid://170282324" | |
| 165 | sick.Looped = true | |
| 166 | sick.Volume = 1 | |
| 167 | ||
| 168 | IT = Instance.new | |
| 169 | CF = CFrame.new | |
| 170 | VT = Vector3.new | |
| 171 | RAD = math.rad | |
| 172 | C3 = Color3.new | |
| 173 | UD2 = UDim2.new | |
| 174 | BRICKC = BrickColor.new | |
| 175 | ANGLES = CFrame.Angles | |
| 176 | EULER = CFrame.fromEulerAnglesXYZ | |
| 177 | COS = math.cos | |
| 178 | ACOS = math.acos | |
| 179 | SIN = math.sin | |
| 180 | ASIN = math.asin | |
| 181 | ABS = math.abs | |
| 182 | MRANDOM = math.random | |
| 183 | FLOOR = math.floor | |
| 184 | ||
| 185 | --//=================================\\ | |
| 186 | --|| USEFUL VALUES | |
| 187 | --\\=================================// | |
| 188 | ||
| 189 | Animation_Speed = 3 | |
| 190 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
| 191 | local Speed = 45 | |
| 192 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 193 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 194 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
| 195 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
| 196 | local DAMAGEMULTIPLIER = 1 | |
| 197 | local ANIM = "Idle" | |
| 198 | local ATTACK = false | |
| 199 | local EQUIPPED = false | |
| 200 | local HOLD = false | |
| 201 | local COMBO = 1 | |
| 202 | local Rooted = false | |
| 203 | local SINE = 0 | |
| 204 | local KEYHOLD = false | |
| 205 | local CHANGE = 2 / Animation_Speed | |
| 206 | local WALKINGANIM = false | |
| 207 | local VALUE1 = false | |
| 208 | local VALUE2 = false | |
| 209 | local ROBLOXIDLEANIMATION = IT("Animation")
| |
| 210 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
| 211 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
| 212 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
| 213 | local WEAPONGUI = IT("ScreenGui", PlayerGui)
| |
| 214 | WEAPONGUI.Name = "Weapon GUI" | |
| 215 | local Effects = IT("Folder", Character)
| |
| 216 | Effects.Name = "Effects" | |
| 217 | local ANIMATOR = Humanoid.Animator | |
| 218 | local ANIMATE = Character.Animate | |
| 219 | local UNANCHOR = true | |
| 220 | local HITPOS = nil | |
| 221 | local HITFLOOR = nil | |
| 222 | local LEFTWINGS = {}
| |
| 223 | local RIGHTWINGS = {}
| |
| 224 | local BODY = {}
| |
| 225 | ||
| 226 | --//=================================\\ | |
| 227 | --\\=================================// | |
| 228 | ||
| 229 | ||
| 230 | --//=================================\\ | |
| 231 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
| 232 | --\\=================================// | |
| 233 | ||
| 234 | ArtificialHB = Instance.new("BindableEvent", script)
| |
| 235 | ArtificialHB.Name = "ArtificialHB" | |
| 236 | ||
| 237 | script:WaitForChild("ArtificialHB")
| |
| 238 | ||
| 239 | frame = Frame_Speed | |
| 240 | tf = 0 | |
| 241 | allowframeloss = false | |
| 242 | tossremainder = false | |
| 243 | lastframe = tick() | |
| 244 | script.ArtificialHB:Fire() | |
| 245 | ||
| 246 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 247 | tf = tf + s | |
| 248 | if tf >= frame then | |
| 249 | if allowframeloss then | |
| 250 | script.ArtificialHB:Fire() | |
| 251 | lastframe = tick() | |
| 252 | else | |
| 253 | for i = 1, math.floor(tf / frame) do | |
| 254 | script.ArtificialHB:Fire() | |
| 255 | end | |
| 256 | lastframe = tick() | |
| 257 | end | |
| 258 | if tossremainder then | |
| 259 | tf = 0 | |
| 260 | else | |
| 261 | tf = tf - frame * math.floor(tf / frame) | |
| 262 | end | |
| 263 | end | |
| 264 | end) | |
| 265 | ||
| 266 | --//=================================\\ | |
| 267 | --\\=================================// | |
| 268 | ||
| 269 | --//=================================\\ | |
| 270 | --|| SOME FUNCTIONS | |
| 271 | --\\=================================// | |
| 272 | ||
| 273 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
| 274 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
| 275 | end | |
| 276 | ||
| 277 | function PositiveAngle(NUMBER) | |
| 278 | if NUMBER >= 0 then | |
| 279 | NUMBER = 0 | |
| 280 | end | |
| 281 | return NUMBER | |
| 282 | end | |
| 283 | ||
| 284 | function NegativeAngle(NUMBER) | |
| 285 | if NUMBER <= 0 then | |
| 286 | NUMBER = 0 | |
| 287 | end | |
| 288 | return NUMBER | |
| 289 | end | |
| 290 | ||
| 291 | function Swait(NUMBER) | |
| 292 | if NUMBER == 0 or NUMBER == nil then | |
| 293 | ArtificialHB.Event:wait() | |
| 294 | else | |
| 295 | for i = 1, NUMBER do | |
| 296 | ArtificialHB.Event:wait() | |
| 297 | end | |
| 298 | end | |
| 299 | end | |
| 300 | ||
| 301 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
| 302 | local NEWMESH = IT(MESH) | |
| 303 | if MESH == "SpecialMesh" then | |
| 304 | NEWMESH.MeshType = MESHTYPE | |
| 305 | if MESHID ~= "nil" and MESHID ~= "" then | |
| 306 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
| 307 | end | |
| 308 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
| 309 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
| 310 | end | |
| 311 | end | |
| 312 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
| 313 | NEWMESH.Scale = SCALE | |
| 314 | NEWMESH.Parent = PARENT | |
| 315 | return NEWMESH | |
| 316 | end | |
| 317 | ||
| 318 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE, ANCHOR) | |
| 319 | local NEWPART = IT("Part")
| |
| 320 | NEWPART.formFactor = FORMFACTOR | |
| 321 | NEWPART.Reflectance = REFLECTANCE | |
| 322 | NEWPART.Transparency = TRANSPARENCY | |
| 323 | NEWPART.CanCollide = false | |
| 324 | NEWPART.Locked = true | |
| 325 | NEWPART.Anchored = true | |
| 326 | if ANCHOR == false then | |
| 327 | NEWPART.Anchored = false | |
| 328 | end | |
| 329 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
| 330 | NEWPART.Name = NAME | |
| 331 | NEWPART.Size = SIZE | |
| 332 | NEWPART.Position = Torso.Position | |
| 333 | NEWPART.Material = MATERIAL | |
| 334 | NEWPART:BreakJoints() | |
| 335 | NEWPART.Parent = PARENT | |
| 336 | return NEWPART | |
| 337 | end | |
| 338 | ||
| 339 | local function weldBetween(a, b) | |
| 340 | local weldd = Instance.new("ManualWeld")
| |
| 341 | weldd.Part0 = a | |
| 342 | weldd.Part1 = b | |
| 343 | weldd.C0 = CFrame.new() | |
| 344 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
| 345 | weldd.Parent = a | |
| 346 | return weldd | |
| 347 | end | |
| 348 | ||
| 349 | ||
| 350 | function QuaternionFromCFrame(cf) | |
| 351 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 352 | local trace = m00 + m11 + m22 | |
| 353 | if trace > 0 then | |
| 354 | local s = math.sqrt(1 + trace) | |
| 355 | local recip = 0.5 / s | |
| 356 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
| 357 | else | |
| 358 | local i = 0 | |
| 359 | if m11 > m00 then | |
| 360 | i = 1 | |
| 361 | end | |
| 362 | if m22 > (i == 0 and m00 or m11) then | |
| 363 | i = 2 | |
| 364 | end | |
| 365 | if i == 0 then | |
| 366 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
| 367 | local recip = 0.5 / s | |
| 368 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
| 369 | elseif i == 1 then | |
| 370 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
| 371 | local recip = 0.5 / s | |
| 372 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
| 373 | elseif i == 2 then | |
| 374 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
| 375 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
| 376 | end | |
| 377 | end | |
| 378 | end | |
| 379 | ||
| 380 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 381 | local xs, ys, zs = x + x, y + y, z + z | |
| 382 | local wx, wy, wz = w * xs, w * ys, w * zs | |
| 383 | local xx = x * xs | |
| 384 | local xy = x * ys | |
| 385 | local xz = x * zs | |
| 386 | local yy = y * ys | |
| 387 | local yz = y * zs | |
| 388 | local zz = z * zs | |
| 389 | 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)) | |
| 390 | end | |
| 391 | ||
| 392 | function QuaternionSlerp(a, b, t) | |
| 393 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
| 394 | local startInterp, finishInterp; | |
| 395 | if cosTheta >= 0.0001 then | |
| 396 | if (1 - cosTheta) > 0.0001 then | |
| 397 | local theta = ACOS(cosTheta) | |
| 398 | local invSinTheta = 1 / SIN(theta) | |
| 399 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
| 400 | finishInterp = SIN(t * theta) * invSinTheta | |
| 401 | else | |
| 402 | startInterp = 1 - t | |
| 403 | finishInterp = t | |
| 404 | end | |
| 405 | else | |
| 406 | if (1 + cosTheta) > 0.0001 then | |
| 407 | local theta = ACOS(-cosTheta) | |
| 408 | local invSinTheta = 1 / SIN(theta) | |
| 409 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
| 410 | finishInterp = SIN(t * theta) * invSinTheta | |
| 411 | else | |
| 412 | startInterp = t - 1 | |
| 413 | finishInterp = t | |
| 414 | end | |
| 415 | end | |
| 416 | 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 | |
| 417 | end | |
| 418 | ||
| 419 | function Clerp(a, b, t) | |
| 420 | local qa = {QuaternionFromCFrame(a)}
| |
| 421 | local qb = {QuaternionFromCFrame(b)}
| |
| 422 | local ax, ay, az = a.x, a.y, a.z | |
| 423 | local bx, by, bz = b.x, b.y, b.z | |
| 424 | local _t = 1 - t | |
| 425 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
| 426 | end | |
| 427 | ||
| 428 | function CreateFrame(PARENT, TRANSPARENCY, BORDERSIZEPIXEL, POSITION, SIZE, COLOR, BORDERCOLOR, NAME) | |
| 429 | local frame = IT("Frame")
| |
| 430 | frame.BackgroundTransparency = TRANSPARENCY | |
| 431 | frame.BorderSizePixel = BORDERSIZEPIXEL | |
| 432 | frame.Position = POSITION | |
| 433 | frame.Size = SIZE | |
| 434 | frame.BackgroundColor3 = COLOR | |
| 435 | frame.BorderColor3 = BORDERCOLOR | |
| 436 | frame.Name = NAME | |
| 437 | frame.Parent = PARENT | |
| 438 | return frame | |
| 439 | end | |
| 440 | ||
| 441 | function CreateLabel(PARENT, TEXT, TEXTCOLOR, TEXTFONTSIZE, TEXTFONT, TRANSPARENCY, BORDERSIZEPIXEL, STROKETRANSPARENCY, NAME) | |
| 442 | local label = IT("TextLabel")
| |
| 443 | label.BackgroundTransparency = 1 | |
| 444 | label.Size = UD2(1, 0, 1, 0) | |
| 445 | label.Position = UD2(0, 0, 0, 0) | |
| 446 | label.TextColor3 = TEXTCOLOR | |
| 447 | label.TextStrokeColor3 = BRICKC"Really red".Color | |
| 448 | label.TextStrokeTransparency = STROKETRANSPARENCY | |
| 449 | label.TextTransparency = TRANSPARENCY | |
| 450 | label.FontSize = TEXTFONTSIZE | |
| 451 | label.Font = TEXTFONT | |
| 452 | label.BorderSizePixel = BORDERSIZEPIXEL | |
| 453 | label.TextScaled = false | |
| 454 | label.Text = TEXT | |
| 455 | label.Name = NAME | |
| 456 | label.Parent = PARENT | |
| 457 | return label | |
| 458 | end | |
| 459 | ||
| 460 | function NoOutlines(PART) | |
| 461 | PART.TopSurface, PART.BottomSurface, PART.LeftSurface, PART.RightSurface, PART.FrontSurface, PART.BackSurface = 10, 10, 10, 10, 10, 10 | |
| 462 | end | |
| 463 | ||
| 464 | function CreateWeldOrSnapOrMotor(TYPE, PARENT, PART0, PART1, C0, C1) | |
| 465 | local NEWWELD = IT(TYPE) | |
| 466 | NEWWELD.Part0 = PART0 | |
| 467 | NEWWELD.Part1 = PART1 | |
| 468 | NEWWELD.C0 = C0 | |
| 469 | NEWWELD.C1 = C1 | |
| 470 | NEWWELD.Parent = PARENT | |
| 471 | return NEWWELD | |
| 472 | end | |
| 473 | ||
| 474 | local S = IT("Sound")
| |
| 475 | function CreateSound(ID, PARENT, VOLUME, PITCH, DOESLOOP) | |
| 476 | local NEWSOUND = nil | |
| 477 | coroutine.resume(coroutine.create(function() | |
| 478 | NEWSOUND = S:Clone() | |
| 479 | NEWSOUND.Parent = PARENT | |
| 480 | NEWSOUND.Volume = VOLUME | |
| 481 | NEWSOUND.Pitch = PITCH | |
| 482 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
| 483 | NEWSOUND:play() | |
| 484 | NEWSOUND.Name = "Audio" | |
| 485 | if DOESLOOP == true then | |
| 486 | NEWSOUND.Looped = true | |
| 487 | else | |
| 488 | repeat Swait() until NEWSOUND.Playing == false | |
| 489 | NEWSOUND:remove() | |
| 490 | end | |
| 491 | end)) | |
| 492 | return NEWSOUND | |
| 493 | end | |
| 494 | ||
| 495 | function CFrameFromTopBack(at, top, back) | |
| 496 | local right = top:Cross(back) | |
| 497 | 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) | |
| 498 | end | |
| 499 | ||
| 500 | --WACKYEFFECT({EffectType = "", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 1, CFrame = CF(), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(1,1,1), SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 501 | function WACKYEFFECT(Table) | |
| 502 | local TYPE = (Table.EffectType or "Sphere") | |
| 503 | local SIZE = (Table.Size or VT(1,1,1)) | |
| 504 | local ENDSIZE = (Table.Size2 or VT(0,0,0)) | |
| 505 | local TRANSPARENCY = (Table.Transparency or 0) | |
| 506 | local ENDTRANSPARENCY = (Table.Transparency2 or 1) | |
| 507 | local CFRAME = (Table.CFrame or Torso.CFrame) | |
| 508 | local MOVEDIRECTION = (Table.MoveToPos or nil) | |
| 509 | local ROTATION1 = (Table.RotationX or 0) | |
| 510 | local ROTATION2 = (Table.RotationY or 0) | |
| 511 | local ROTATION3 = (Table.RotationZ or 0) | |
| 512 | local MATERIAL = (Table.Material or "Neon") | |
| 513 | local COLOR = (Table.Color or C3(1,1,1)) | |
| 514 | local TIME = (Table.Time or 45) | |
| 515 | local SOUNDID = (Table.SoundID or nil) | |
| 516 | local SOUNDPITCH = (Table.SoundPitch or nil) | |
| 517 | local SOUNDVOLUME = (Table.SoundVolume or nil) | |
| 518 | coroutine.resume(coroutine.create(function() | |
| 519 | local PLAYSSOUND = false | |
| 520 | local SOUND = nil | |
| 521 | local EFFECT = CreatePart(3, Effects, MATERIAL, 0, TRANSPARENCY, BRICKC("Pearl"), "Effect", VT(1,1,1), true)
| |
| 522 | if SOUNDID ~= nil and SOUNDPITCH ~= nil and SOUNDVOLUME ~= nil then | |
| 523 | PLAYSSOUND = true | |
| 524 | SOUND = CreateSound(SOUNDID, EFFECT, SOUNDVOLUME, SOUNDPITCH, false) | |
| 525 | end | |
| 526 | EFFECT.Color = COLOR | |
| 527 | local MSH = nil | |
| 528 | if TYPE == "Sphere" then | |
| 529 | MSH = CreateMesh("SpecialMesh", EFFECT, "Sphere", "", "", SIZE, VT(0,0,0))
| |
| 530 | elseif TYPE == "Block" then | |
| 531 | MSH = IT("BlockMesh",EFFECT)
| |
| 532 | MSH.Scale = VT(SIZE.X,SIZE.X,SIZE.X) | |
| 533 | elseif TYPE == "Box" then | |
| 534 | MSH = IT("BlockMesh",EFFECT)
| |
| 535 | MSH.Scale = SIZE | |
| 536 | elseif TYPE == "Wave" then | |
| 537 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "20329976", "", SIZE, VT(0,0,-SIZE.X/8))
| |
| 538 | elseif TYPE == "Ring" then | |
| 539 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "559831844", "", VT(SIZE.X,SIZE.X,0.1), VT(0,0,0))
| |
| 540 | elseif TYPE == "Slash" then | |
| 541 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662586858", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
| |
| 542 | elseif TYPE == "Round Slash" then | |
| 543 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "662585058", "", VT(SIZE.X/10,0,SIZE.X/10), VT(0,0,0))
| |
| 544 | elseif TYPE == "Swirl" then | |
| 545 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "1051557", "", SIZE, VT(0,0,0))
| |
| 546 | elseif TYPE == "Skull" then | |
| 547 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "4770583", "", SIZE, VT(0,0,0))
| |
| 548 | elseif TYPE == "Crystal" then | |
| 549 | MSH = CreateMesh("SpecialMesh", EFFECT, "FileMesh", "9756362", "", SIZE, VT(0,0,0))
| |
| 550 | end | |
| 551 | if MSH ~= nil then | |
| 552 | local MOVESPEED = nil | |
| 553 | if MOVEDIRECTION ~= nil then | |
| 554 | MOVESPEED = (CFRAME.p - MOVEDIRECTION).Magnitude/TIME | |
| 555 | end | |
| 556 | local GROWTH = SIZE - ENDSIZE | |
| 557 | local TRANS = TRANSPARENCY - ENDTRANSPARENCY | |
| 558 | if TYPE == "Block" then | |
| 559 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
| 560 | else | |
| 561 | EFFECT.CFrame = CFRAME | |
| 562 | end | |
| 563 | for LOOP = 1, TIME do | |
| 564 | Swait() | |
| 565 | MSH.Scale = MSH.Scale - GROWTH/TIME | |
| 566 | if TYPE == "Wave" then | |
| 567 | MSH.Offset = VT(0,0,-MSH.Scale.X/8) | |
| 568 | end | |
| 569 | EFFECT.Transparency = EFFECT.Transparency - TRANS/TIME | |
| 570 | if TYPE == "Block" then | |
| 571 | EFFECT.CFrame = CFRAME*ANGLES(RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360)),RAD(MRANDOM(0,360))) | |
| 572 | else | |
| 573 | EFFECT.CFrame = EFFECT.CFrame*ANGLES(RAD(ROTATION1),RAD(ROTATION2),RAD(ROTATION3)) | |
| 574 | end | |
| 575 | if MOVEDIRECTION ~= nil then | |
| 576 | local ORI = EFFECT.Orientation | |
| 577 | EFFECT.CFrame = CF(EFFECT.Position,MOVEDIRECTION)*CF(0,0,-MOVESPEED) | |
| 578 | EFFECT.Orientation = ORI | |
| 579 | end | |
| 580 | end | |
| 581 | if PLAYSSOUND == false then | |
| 582 | EFFECT:remove() | |
| 583 | else | |
| 584 | repeat Swait() until SOUND.Playing == false | |
| 585 | EFFECT:remove() | |
| 586 | end | |
| 587 | else | |
| 588 | if PLAYSSOUND == false then | |
| 589 | EFFECT:remove() | |
| 590 | else | |
| 591 | repeat Swait() until SOUND.Playing == false | |
| 592 | EFFECT:remove() | |
| 593 | end | |
| 594 | end | |
| 595 | end)) | |
| 596 | end | |
| 597 | ||
| 598 | function Shatter(Part) | |
| 599 | if Part.Transparency == 0 then | |
| 600 | local SOUNDPART = CreatePart(3, Effects, "Neon", 0, 1, Part.BrickColor, "OOF", VT(0,0,0)) | |
| 601 | Debris:AddItem(SOUNDPART,5) | |
| 602 | CreateSound("84005018", SOUNDPART, 3, MRANDOM(8,12)/10, false)
| |
| 603 | local SIZE = Part.Size.X + Part.Size.Y + Part.Size.Z | |
| 604 | local SIZESET = SIZE/4 | |
| 605 | local XOffset = Part.Size.X*1.5/SIZESET | |
| 606 | local YOffset = Part.Size.Y*1.5/SIZESET | |
| 607 | local ZOffset = Part.Size.Z*1.5/SIZESET | |
| 608 | for x = 1, math.ceil(XOffset) do | |
| 609 | for y = 1, math.ceil(YOffset) do | |
| 610 | for z = 1, math.ceil(ZOffset) do | |
| 611 | local SHARD = CreatePart(3, Effects, "Neon", 0, 0, Part.BrickColor, "Shard", VT(SIZE,SIZE,SIZE)/10, false) | |
| 612 | SHARD.CanCollide = true | |
| 613 | SHARD.CFrame = Part.CFrame*CF((Part.Size.X/2-x/4),(Part.Size.Y/2-y/4),(Part.Size.Z/2-z/4)) | |
| 614 | SHARD.Velocity = VT(MRANDOM(-15,15),MRANDOM(-15,15),MRANDOM(-15,15))*3 | |
| 615 | Debris:AddItem(SHARD,MRANDOM(10,25)/3) | |
| 616 | end | |
| 617 | end | |
| 618 | end | |
| 619 | end | |
| 620 | Part:remove() | |
| 621 | end | |
| 622 | ||
| 623 | function MakeForm(PART,TYPE) | |
| 624 | if TYPE == "Cyl" then | |
| 625 | local MSH = IT("CylinderMesh",PART)
| |
| 626 | elseif TYPE == "Ball" then | |
| 627 | local MSH = IT("SpecialMesh",PART)
| |
| 628 | MSH.MeshType = "Sphere" | |
| 629 | elseif TYPE == "Wedge" then | |
| 630 | local MSH = IT("SpecialMesh",PART)
| |
| 631 | MSH.MeshType = "Wedge" | |
| 632 | end | |
| 633 | end | |
| 634 | ||
| 635 | Debris = game:GetService("Debris")
| |
| 636 | ||
| 637 | function CastProperRay(StartPos, EndPos, Distance, Ignore) | |
| 638 | local DIRECTION = CF(StartPos,EndPos).lookVector | |
| 639 | return Raycast(StartPos, DIRECTION, Distance, Ignore) | |
| 640 | end | |
| 641 | ||
| 642 | function turnto(position) | |
| 643 | RootPart.CFrame=CFrame.new(RootPart.CFrame.p,VT(position.X,RootPart.Position.Y,position.Z)) * CFrame.new(0, 0, 0) | |
| 644 | end | |
| 645 | ||
| 646 | --//=================================\\ | |
| 647 | --|| WEAPON CREATION | |
| 648 | --\\=================================// | |
| 649 | ||
| 650 | local Back = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Wing", VT(1,1,0.35),false) | |
| 651 | CreateWeldOrSnapOrMotor("Weld", Torso, Torso, Back, CF(0, 0.5, 1.2) * ANGLES(RAD(0),RAD(0),RAD(45)), CF(0, 0, 0))
| |
| 652 | ||
| 653 | local ANGLE = 35 | |
| 654 | for i = 1, 5 do | |
| 655 | local Wing = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Wing", VT(0.15,2+(i/2),0.15),false) | |
| 656 | local WingWeld = CreateWeldOrSnapOrMotor("Weld", Wing, Torso, Wing, CF(0, 1, 0) * ANGLES(RAD(90), RAD(0), RAD(0)) * CF(0,1,0) * ANGLES(RAD(0), RAD(0), RAD(90)) * ANGLES(RAD(ANGLE), RAD(0), RAD(0)) * CF(0,3+(i/10),0) , CF(0, 0, 0))
| |
| 657 | local Wing2 = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Wing", VT(0.25,1,0.25),false) | |
| 658 | CreateWeldOrSnapOrMotor("Weld", Wing, Wing, Wing2, CF(0, 2+(i/2), 0) * ANGLES(RAD(25), RAD(0), RAD(0)), CF(0, 1, 0))
| |
| 659 | ANGLE = ANGLE - 15 | |
| 660 | table.insert(LEFTWINGS,WingWeld) | |
| 661 | end | |
| 662 | ANGLE = 35 | |
| 663 | for i = 1, 5 do | |
| 664 | local Wing = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Wing", VT(0.15,2+(i/2),0.15),false) | |
| 665 | local WingWeld = CreateWeldOrSnapOrMotor("Weld", Wing, Torso, Wing, CF(0, 1, 0) * ANGLES(RAD(90), RAD(0), RAD(0)) * CF(0,1,0) * ANGLES(RAD(0), RAD(0), RAD(-90)) * ANGLES(RAD(ANGLE), RAD(0), RAD(0)) * CF(0,3+(i/10),0) , CF(0, 0, 0))
| |
| 666 | local Wing2 = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Wing", VT(0.25,1,0.25),false) | |
| 667 | CreateWeldOrSnapOrMotor("Weld", Wing, Wing, Wing2, CF(0, 2+(i/2), 0) * ANGLES(RAD(25), RAD(0), RAD(0)), CF(0, 1, 0))
| |
| 668 | ANGLE = ANGLE - 15 | |
| 669 | table.insert(RIGHTWINGS,WingWeld) | |
| 670 | end | |
| 671 | local Eye = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Eye", VT(0.3,0.3,0.3),false) | |
| 672 | local EyeWeld = CreateWeldOrSnapOrMotor("Weld", Head, Head, Eye, CF(0,0.2,0) * ANGLES(RAD(-5),RAD(25),RAD(0)) * CF(0,0,-0.45), CF(0,0,0))
| |
| 673 | local Eye2 = CreatePart(3, Character, "Neon", 0, 0.5, "Really red", "Eye", VT(0.5,0.5,0.29),false) | |
| 674 | local EyeWeld2 = CreateWeldOrSnapOrMotor("Weld", Head, Head, Eye2, CF(0,0.2,0) * ANGLES(RAD(-5),RAD(25),RAD(0)) * CF(0,0,-0.45), CF(0,0,0))
| |
| 675 | ||
| 676 | local Eye3 = CreatePart(3, Character, "Neon", 0, 0, "Really red", "Eye", VT(0.1,0.1,0.31),false) | |
| 677 | local EyeWeld3 = CreateWeldOrSnapOrMotor("Weld", Head, Head, Eye3, CF(0,0.2,0) * ANGLES(RAD(-5),RAD(-25),RAD(0)) * CF(0,0,-0.45), CF(0,0,0))
| |
| 678 | ||
| 679 | local SKILLTEXTCOLOR = BRICKC"Really red".Color | |
| 680 | local SKILLFONT = "SciFi" | |
| 681 | local SKILLTEXTSIZE = 6 | |
| 682 | ||
| 683 | local naeeym2 = Instance.new("BillboardGui",Character)
| |
| 684 | naeeym2.AlwaysOnTop = true | |
| 685 | naeeym2.Size = UDim2.new(5,35,2,15) | |
| 686 | naeeym2.StudsOffset = Vector3.new(0,1.2,0) | |
| 687 | naeeym2.Adornee = Character.Head | |
| 688 | naeeym2.Name = "Name" | |
| 689 | naeeym2.PlayerToHideFrom = Player | |
| 690 | local tecks2 = Instance.new("TextLabel",naeeym2)
| |
| 691 | tecks2.BackgroundTransparency = 1 | |
| 692 | tecks2.TextScaled = true | |
| 693 | tecks2.BorderSizePixel = 0 | |
| 694 | tecks2.Text = "Cyber Monarch" | |
| 695 | tecks2.Font = SKILLFONT | |
| 696 | tecks2.TextSize = 30 | |
| 697 | tecks2.TextStrokeTransparency = 0 | |
| 698 | tecks2.TextColor3 = C3(0,0,0) | |
| 699 | tecks2.TextStrokeColor3 = BRICKC"Really red".Color | |
| 700 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
| 701 | tecks2.Parent = naeeym2 | |
| 702 | ||
| 703 | for _, c in pairs(Character:GetChildren()) do | |
| 704 | if c.ClassName == "Part" then | |
| 705 | table.insert(BODY,{c,Character})
| |
| 706 | for _, q in pairs(c:GetChildren()) do | |
| 707 | if q.ClassName == "Motor6D" or q.ClassName == "Weld" or q.ClassName == "ManualWeld" then | |
| 708 | table.insert(BODY,{q,c})
| |
| 709 | end | |
| 710 | end | |
| 711 | end | |
| 712 | end | |
| 713 | ||
| 714 | function refit() | |
| 715 | Character.Parent = workspace | |
| 716 | for e = 1, #BODY do | |
| 717 | if BODY[e] ~= nil then | |
| 718 | local STUFF = BODY[e] | |
| 719 | local PART = STUFF[1] | |
| 720 | local PARENT = STUFF[2] | |
| 721 | PART.Parent = PARENT | |
| 722 | end | |
| 723 | end | |
| 724 | end | |
| 725 | ||
| 726 | Humanoid.HealthChanged:connect(function() | |
| 727 | Humanoid.Parent = nil | |
| 728 | Humanoid.MaxHealth = "inf" | |
| 729 | Humanoid.Health = "inf" | |
| 730 | refit() | |
| 731 | Humanoid.Parent = Character | |
| 732 | end) | |
| 733 | ||
| 734 | Humanoid.Died:connect(function() | |
| 735 | Humanoid.Parent = nil | |
| 736 | Humanoid.MaxHealth = "inf" | |
| 737 | Humanoid.Health = "inf" | |
| 738 | refit() | |
| 739 | Humanoid.Parent = Character | |
| 740 | end) | |
| 741 | ||
| 742 | local SKILL1FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 1 Frame") | |
| 743 | local SKILL2FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.80, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 2 Frame") | |
| 744 | local SKILL3FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.23, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 3 Frame") | |
| 745 | local SKILL4FRAME = CreateFrame(WEAPONGUI, 0.75, 2, UD2(0.50, 0, 0.90, 0), UD2(0.26, 0, 0.07, 0), C3(0,0,0), C3(0, 0, 0), "Skill 4 Frame") | |
| 746 | ||
| 747 | local SKILL1TEXT = CreateLabel(SKILL1FRAME, "[Z] Cyber Out-Burst", C3(50/255, 0/255, 0/255), SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 1") | |
| 748 | local SKILL2TEXT = CreateLabel(SKILL2FRAME, "[B] Techno Beam", C3(50/255, 0/255, 0/255), SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 2") | |
| 749 | local SKILL3TEXT = CreateLabel(SKILL3FRAME, "[C] Techno Warp", C3(50/255, 0/255, 0/255), SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 3") | |
| 750 | local SKILL4TEXT = CreateLabel(SKILL4FRAME, "[V] Cyber Smash", C3(50/255, 0/255, 0/255), SKILLTEXTSIZE, SKILLFONT, 0, 2, 0.7, "Text 4") | |
| 751 | ||
| 752 | --//=================================\\ | |
| 753 | --|| DAMAGING | |
| 754 | --\\=================================// | |
| 755 | ||
| 756 | function killnearest(position,range,EFFECT) | |
| 757 | for i,v in ipairs(workspace:GetChildren()) do | |
| 758 | local body = v:GetChildren() | |
| 759 | for part = 1, #body do | |
| 760 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
| 761 | local SIZE = body[part].Size.Magnitude | |
| 762 | if(body[part].Position - position).Magnitude < range + SIZE/2 then | |
| 763 | if v.ClassName == "Model" then | |
| 764 | if v:FindFirstChildOfClass("Humanoid") ~= nil then
| |
| 765 | if v:FindFirstChildOfClass("Humanoid").Health > 0 then
| |
| 766 | v:BreakJoints() | |
| 767 | if EFFECT == "Glitch" then | |
| 768 | coroutine.resume(coroutine.create(function() | |
| 769 | local ORIGINPOS = body[part].CFrame | |
| 770 | local SIZE = body[part].Size | |
| 771 | for i = 1, 100 do | |
| 772 | Swait() | |
| 773 | local PART = body[part] | |
| 774 | PART.Anchored = true | |
| 775 | PART.Size = SIZE*MRANDOM(5,15)/10 | |
| 776 | PART.CFrame = ORIGINPOS*CF(MRANDOM(-15,15)/15,MRANDOM(-15,15)/15,MRANDOM(-15,15)/15) | |
| 777 | end | |
| 778 | body[part]:remove() | |
| 779 | end)) | |
| 780 | elseif EFFECT == "Shatter" then | |
| 781 | for _, c in pairs(v:GetChildren()) do | |
| 782 | if c.ClassName == "Part" or c.ClassName == "MeshPart" then | |
| 783 | Shatter(c) | |
| 784 | end | |
| 785 | end | |
| 786 | end | |
| 787 | end | |
| 788 | end | |
| 789 | end | |
| 790 | end | |
| 791 | end | |
| 792 | end | |
| 793 | end | |
| 794 | end | |
| 795 | ||
| 796 | --//=================================\\ | |
| 797 | --|| ATTACK FUNCTIONS AND STUFF | |
| 798 | --\\=================================// | |
| 799 | ||
| 800 | function CyberOutburst() | |
| 801 | if HITFLOOR ~= nil then | |
| 802 | ATTACK = true | |
| 803 | Rooted = true | |
| 804 | for i=0, 2, 0.1 / Animation_Speed do | |
| 805 | Swait() | |
| 806 | WACKYEFFECT({EffectType = "Box", Size = VT(1,1,1), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0, CFrame = Torso.CFrame*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)))*CF(0,15,0), MoveToPos = Torso.Position, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 807 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 808 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 809 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 810 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 811 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 812 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 813 | end | |
| 814 | for i=0, 2, 0.1 / Animation_Speed do | |
| 815 | Swait() | |
| 816 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 817 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 818 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 819 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 820 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 821 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 822 | end | |
| 823 | WACKYEFFECT({EffectType = "Block", Size = VT(1,1,1), Size2 = VT(25,25,25), Transparency = 0.25, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = C3(0,0,0), SoundID = 178452241, SoundPitch = 0.6, SoundVolume = 6})
| |
| 824 | WACKYEFFECT({EffectType = "Block", Size = VT(1,1,1), Size2 = VT(35,35,35), Transparency = 0.5, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = 178452241, SoundPitch = 0.8, SoundVolume = 4})
| |
| 825 | WACKYEFFECT({EffectType = "Block", Size = VT(1,1,1), Size2 = VT(40,40,40), Transparency = 0.75, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = 178452241, SoundPitch = 1, SoundVolume = 2})
| |
| 826 | for i=0, 0.4, 0.1 / Animation_Speed do | |
| 827 | Swait() | |
| 828 | killnearest(Torso.Position,45,"Glitch") | |
| 829 | WACKYEFFECT({Time = 75, EffectType = "Box", Size = VT(1,1,1), Size2 = VT(5,5,5), Transparency = 0, Transparency2 = 1, CFrame = Torso.CFrame, MoveToPos = Torso.CFrame*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)))*CF(0,15,0).p, RotationX = MRANDOM(-5,5), RotationY = MRANDOM(-5,5), RotationZ = MRANDOM(-5,5), Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 830 | WACKYEFFECT({Time = 45, EffectType = "Box", Size = VT(1,1,1), Size2 = VT(10,10,10), Transparency = 0, Transparency2 = 1, CFrame = CF(HITPOS), MoveToPos = CF(HITPOS)*ANGLES(RAD(0),RAD(MRANDOM(-180,180)),RAD(0))*CF(0,0,55).p, RotationX = MRANDOM(-5,5), RotationY = MRANDOM(-5,5), RotationZ = MRANDOM(-5,5), Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 831 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(-25 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 832 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 833 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(-35), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(12 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 834 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(-35), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 835 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(20.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 836 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(20.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 837 | end | |
| 838 | ATTACK = false | |
| 839 | Rooted = false | |
| 840 | end | |
| 841 | end | |
| 842 | ||
| 843 | function Technobeam() | |
| 844 | ATTACK = true | |
| 845 | Rooted = false | |
| 846 | local GYRO = IT("BodyGyro",RootPart)
| |
| 847 | GYRO.D = 100 | |
| 848 | GYRO.P = 2000 | |
| 849 | GYRO.MaxTorque = VT(0,4000000,0) | |
| 850 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
| 851 | CreateSound("93724183", RightArm, 5, 1, false)
| |
| 852 | for i=1, 35 do | |
| 853 | Swait() | |
| 854 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 1, Transparency2 = 0.25, CFrame = RightArm.CFrame*CF(0,-5,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6})
| |
| 855 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
| 856 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
| 857 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 858 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(90), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 859 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 860 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 861 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 862 | end | |
| 863 | local BEAM = CreatePart(3, Effects, "Neon", 0, 1, "Really red", "Lazer", VT(0,0,0)) | |
| 864 | local LOOP = CreateSound("415700134", RightArm, 5, 1, false)
| |
| 865 | local TOCH = BEAM.Touched:Connect(function(hit) | |
| 866 | if hit.Anchored == false and hit.Parent ~= Head and hit.Parent ~= Character and hit.Parent ~= Effects then | |
| 867 | Shatter(hit) | |
| 868 | end | |
| 869 | end) | |
| 870 | local I = 0 | |
| 871 | repeat | |
| 872 | Swait() | |
| 873 | I = I + 1 | |
| 874 | if I <= 10 then | |
| 875 | BEAM.Transparency = BEAM.Transparency - 0.1 | |
| 876 | end | |
| 877 | local STARTPOS = RightArm.CFrame*CF(0,-4,0).p | |
| 878 | local ENDHIT,ENDPOS = CastProperRay(STARTPOS,Mouse.Hit.p,650,Character) | |
| 879 | local DISTANCE = (STARTPOS - ENDPOS).Magnitude | |
| 880 | BEAM.CFrame = CF(STARTPOS,ENDPOS)*CF(0,0,-DISTANCE/2)*ANGLES(RAD(0),RAD(0),RAD(I*5)) | |
| 881 | BEAM.Size = VT(2,2,DISTANCE) | |
| 882 | WACKYEFFECT({Time = 5, EffectType = "Box", Size = VT(1,1,1), Size2 = VT(1,1,1), Transparency = 0, Transparency2 = 1, CFrame = CF(ENDPOS), MoveToPos = CF(ENDPOS)*ANGLES(RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)),RAD(MRANDOM(-180,180)))*CF(0,15,0).p, RotationX = MRANDOM(-5,5), RotationY = MRANDOM(-5,5), RotationZ = MRANDOM(-5,5), Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 883 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 0.25, CFrame = RightArm.CFrame*CF(0,-4,0), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6})
| |
| 884 | WACKYEFFECT({Time = 5, EffectType = "Block", Size = VT(5,5,5), Size2 = VT(0,0,0), Transparency = 0, Transparency2 = 0.25, CFrame = CF(ENDPOS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = nil, SoundPitch = 0.6, SoundVolume = 6})
| |
| 885 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
| 886 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
| 887 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 888 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(90), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 889 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 890 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 891 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 892 | if ENDHIT ~= nil then | |
| 893 | if ENDHIT.Anchored == false and ENDHIT.Parent ~= Effects then | |
| 894 | Shatter(ENDHIT) | |
| 895 | end | |
| 896 | end | |
| 897 | until LOOP.Playing == false | |
| 898 | GYRO:remove() | |
| 899 | BEAM:remove() | |
| 900 | ATTACK = false | |
| 901 | Rooted = false | |
| 902 | end | |
| 903 | ||
| 904 | function Technowarp() | |
| 905 | local FRAME = RootPart.Position | |
| 906 | for i = 1, 6 do | |
| 907 | WACKYEFFECT({Time = 15, EffectType = "Box", Size = VT(2,0,2), Size2 = VT(0,35,0), Transparency = 0.5, Transparency2 = 0.5, CFrame = CF(Torso.Position)*ANGLES(RAD(0),RAD(i*(360/5)),RAD(0))*CF(6,0,0), MoveToPos = nil, RotationX = 0, RotationY = 15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = 1177785010, SoundPitch = 1, SoundVolume = 2})
| |
| 908 | end | |
| 909 | RootPart.CFrame = CF(Mouse.Hit.p+VT(0,6,0),VT(FRAME.X,RootPart.Position.Y,FRAME.Z)) | |
| 910 | for i = 1, 6 do | |
| 911 | WACKYEFFECT({Time = 15, EffectType = "Box", Size = VT(2,0,2), Size2 = VT(0,35,0), Transparency = 0.5, Transparency2 = 0.5, CFrame = CF(Torso.Position)*ANGLES(RAD(0),RAD(i*(360/5)),RAD(0))*CF(6,0,0), MoveToPos = nil, RotationX = 0, RotationY = 15, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = 1177785010, SoundPitch = 1, SoundVolume = 2})
| |
| 912 | end | |
| 913 | end | |
| 914 | ||
| 915 | function CyberSmash() | |
| 916 | ATTACK = true | |
| 917 | Rooted = false | |
| 918 | local GYRO = IT("BodyGyro",RootPart)
| |
| 919 | GYRO.D = 100 | |
| 920 | GYRO.P = 2000 | |
| 921 | GYRO.MaxTorque = VT(0,4000000,0) | |
| 922 | GYRO.cframe = CF(RootPart.Position,Mouse.Hit.p) | |
| 923 | local SMASH = CreatePart(3, Effects, "Neon", 0, 1, "Really red", "Block", VT(25,25,25)) | |
| 924 | SMASH.CanCollide = true | |
| 925 | SMASH.Color = C3(0,0,0) | |
| 926 | local EF = Instance.new("SelectionBox",SMASH)
| |
| 927 | EF.Adornee = SMASH | |
| 928 | EF.Color = BrickColor.new("Really red")
| |
| 929 | EF.LineThickness = 0.2 | |
| 930 | EF.Transparency = 1 | |
| 931 | coroutine.resume(coroutine.create(function() | |
| 932 | for i = 1, 20 do | |
| 933 | Swait() | |
| 934 | SMASH.Transparency = SMASH.Transparency - 0.05 | |
| 935 | EF.Transparency = SMASH.Transparency | |
| 936 | end | |
| 937 | end)) | |
| 938 | repeat | |
| 939 | SMASH.CFrame = CF(Mouse.Hit.p)*CF(0,35,0) | |
| 940 | Swait() | |
| 941 | GYRO.cframe = CF(RootPart.Position,SMASH.Position) | |
| 942 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(-15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
| 943 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 944 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(130), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 945 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 946 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 947 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 948 | until HOLD == true and SMASH.Transparency < 0.99 | |
| 949 | for i = 1, 25 do | |
| 950 | Swait() | |
| 951 | SMASH.CFrame = SMASH.CFrame*CF(0,15/25,0) | |
| 952 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(-25 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
| 953 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 954 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.75 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(160), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 955 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 956 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 957 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 958 | end | |
| 959 | local TOCH = SMASH.Touched:Connect(function(hit) | |
| 960 | if hit.Anchored == false and hit.Parent ~= Head and hit.Parent ~= Character and hit.Parent ~= Effects then | |
| 961 | Shatter(hit) | |
| 962 | end | |
| 963 | end) | |
| 964 | local n0 = nil | |
| 965 | local HITFLOOR,HITPOS = Raycast(SMASH.Position, (CF(SMASH.Position, SMASH.Position + VT(0, -1, 0))).lookVector, 25000, Character) | |
| 966 | if HITFLOOR ~= nil then | |
| 967 | if HITFLOOR.Anchored == false and HITFLOOR.Parent ~= workspace then | |
| 968 | if HITFLOOR.Parent:FindFirstChildOfClass("Humanoid") or HITFLOOR.Parent.Parent:FindFirstChildOfClass("Humanoid") then
| |
| 969 | if HITFLOOR.Parent.ClassName == "Model" then | |
| 970 | HITFLOOR.Parent:BreakJoints() | |
| 971 | elseif HITFLOOR.Parent.Parent.ClassName == "Model" then | |
| 972 | HITFLOOR.Parent.Parent:BreakJoints() | |
| 973 | end | |
| 974 | end | |
| 975 | local POS = HITPOS | |
| 976 | n0,HITPOS = Raycast(POS, (CF(POS, POS + VT(0, -1, 0))).lookVector, 25000, HITFLOOR.Parent) | |
| 977 | end | |
| 978 | end | |
| 979 | killnearest(HITPOS,SMASH.Size.X/1.3,"Shatter") | |
| 980 | SMASH.CFrame = CF(HITPOS+VT(0,SMASH.Size.Y/2,0)) | |
| 981 | WACKYEFFECT({Time = 25, EffectType = "Box", Size = VT(24,0,24), Size2 = VT(75,2,75), Transparency = 0, Transparency2 = 1, CFrame = CF(HITPOS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = SKILLTEXTCOLOR, SoundID = 130972023, SoundPitch = 1, SoundVolume = 10})
| |
| 982 | for i = 1, 25 do | |
| 983 | Swait() | |
| 984 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(25 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(45)), 1 / Animation_Speed) | |
| 985 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-45 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 986 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1.5, 0.5 + 0.025 * COS(SINE / 12), -0.5) * ANGLES(RAD(30), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(45 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 987 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1.5, 0.5 + 0.025 * COS(SINE / 12), 0) * ANGLES(RAD(0), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(-12 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 988 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 989 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 990 | end | |
| 991 | coroutine.resume(coroutine.create(function() | |
| 992 | wait(0.2) | |
| 993 | TOCH:disconnect() | |
| 994 | wait(1.8) | |
| 995 | for i = 1, 100 do | |
| 996 | Swait() | |
| 997 | SMASH.Transparency = i/100 | |
| 998 | end | |
| 999 | for i = 1, 10 do | |
| 1000 | Swait() | |
| 1001 | EF.Transparency = EF.Transparency + 0.1 | |
| 1002 | end | |
| 1003 | SMASH:remove() | |
| 1004 | end)) | |
| 1005 | GYRO:remove() | |
| 1006 | ATTACK = false | |
| 1007 | Rooted = false | |
| 1008 | end | |
| 1009 | ||
| 1010 | --//=================================\\ | |
| 1011 | --|| ASSIGN THINGS TO KEYS | |
| 1012 | --\\=================================// | |
| 1013 | ||
| 1014 | function MouseDown(Mouse) | |
| 1015 | HOLD = true | |
| 1016 | if ATTACK == false then | |
| 1017 | end | |
| 1018 | end | |
| 1019 | ||
| 1020 | function MouseUp(Mouse) | |
| 1021 | HOLD = false | |
| 1022 | end | |
| 1023 | ||
| 1024 | function KeyDown(Key) | |
| 1025 | if Key ~= "w" and Key ~= "a" and Key ~= "s" and Key ~= "d" then | |
| 1026 | KEYHOLD = true | |
| 1027 | if Key == "z" and ATTACK == false then | |
| 1028 | CyberOutburst() | |
| 1029 | end | |
| 1030 | ||
| 1031 | if Key == "b" and ATTACK == false then | |
| 1032 | Technobeam() | |
| 1033 | end | |
| 1034 | ||
| 1035 | if Key == "c" and ATTACK == false then | |
| 1036 | Technowarp() | |
| 1037 | end | |
| 1038 | ||
| 1039 | if Key == "v" and ATTACK == false then | |
| 1040 | CyberSmash() | |
| 1041 | end | |
| 1042 | ||
| 1043 | if Key == "t" then | |
| 1044 | local TAUNT = CreateSound("132392118", Head, 10, 0.8)
| |
| 1045 | TAUNT.TimePosition = 1.1 | |
| 1046 | end | |
| 1047 | end | |
| 1048 | end | |
| 1049 | ||
| 1050 | function KeyUp(Key) | |
| 1051 | if Key ~= "w" and Key ~= "a" and Key ~= "s" and Key ~= "d" then | |
| 1052 | KEYHOLD = false | |
| 1053 | end | |
| 1054 | end | |
| 1055 | ||
| 1056 | Mouse.Button1Down:connect(function(NEWKEY) | |
| 1057 | MouseDown(NEWKEY) | |
| 1058 | end) | |
| 1059 | Mouse.Button1Up:connect(function(NEWKEY) | |
| 1060 | MouseUp(NEWKEY) | |
| 1061 | end) | |
| 1062 | Mouse.KeyDown:connect(function(NEWKEY) | |
| 1063 | KeyDown(NEWKEY) | |
| 1064 | end) | |
| 1065 | Mouse.KeyUp:connect(function(NEWKEY) | |
| 1066 | KeyUp(NEWKEY) | |
| 1067 | end) | |
| 1068 | ||
| 1069 | --//=================================\\ | |
| 1070 | --\\=================================// | |
| 1071 | ||
| 1072 | ||
| 1073 | function unanchor() | |
| 1074 | if UNANCHOR == true then | |
| 1075 | g = Character:GetChildren() | |
| 1076 | for i = 1, #g do | |
| 1077 | if g[i].ClassName == "Part" then | |
| 1078 | g[i].Anchored = false | |
| 1079 | end | |
| 1080 | end | |
| 1081 | end | |
| 1082 | end | |
| 1083 | ||
| 1084 | ||
| 1085 | --//=================================\\ | |
| 1086 | --|| WRAP THE WHOLE SCRIPT UP | |
| 1087 | --\\=================================// | |
| 1088 | ||
| 1089 | Humanoid.Changed:connect(function(Jump) | |
| 1090 | if Jump == "Jump" and (Disable_Jump == true) then | |
| 1091 | Humanoid.Jump = false | |
| 1092 | end | |
| 1093 | end) | |
| 1094 | ||
| 1095 | Humanoid.HipHeight = 2 | |
| 1096 | ||
| 1097 | while true do | |
| 1098 | Swait() | |
| 1099 | refit() | |
| 1100 | Character.Parent = workspace | |
| 1101 | Humanoid.Parent = Character | |
| 1102 | ANIMATE.Parent = nil | |
| 1103 | local IDLEANIMATION = Humanoid:LoadAnimation(ROBLOXIDLEANIMATION) | |
| 1104 | IDLEANIMATION:Play() | |
| 1105 | SINE = SINE + CHANGE | |
| 1106 | local TORSOVELOCITY = (RootPart.Velocity * VT(1, 0, 1)).magnitude | |
| 1107 | local TORSOVERTICALVELOCITY = RootPart.Velocity.y | |
| 1108 | HITFLOOR,HITPOS = Raycast(RootPart.Position, (CF(RootPart.Position, RootPart.Position + VT(0, -1, 0))).lookVector, 25, Character) | |
| 1109 | local WALKSPEEDVALUE = 6 / (Humanoid.WalkSpeed / 16) | |
| 1110 | EyeWeld3.C1 = Clerp(EyeWeld3.C1,CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-SINE*2)), 1 / Animation_Speed) | |
| 1111 | EyeWeld2.C1 = Clerp(EyeWeld2.C1,CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(-SINE*2)), 1 / Animation_Speed) | |
| 1112 | EyeWeld.C1 = Clerp(EyeWeld.C1,CF(0, 0, 0) * ANGLES(RAD(0), RAD(0), RAD(SINE*2)), 1 / Animation_Speed) | |
| 1113 | for LW = 1, #LEFTWINGS do | |
| 1114 | if LEFTWINGS[LW] ~= nil then | |
| 1115 | LEFTWINGS[LW].C1 = Clerp(LEFTWINGS[LW].C1, CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(2.5 * SIN(SINE / 12)), RAD(0), RAD(-3 + 3 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 1116 | end | |
| 1117 | end | |
| 1118 | for RW = 1, #RIGHTWINGS do | |
| 1119 | if RIGHTWINGS[RW] ~= nil then | |
| 1120 | RIGHTWINGS[RW].C1 = Clerp(RIGHTWINGS[RW].C1, CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(2.5 * SIN(SINE / 12)), RAD(0), RAD(3 - 3 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 1121 | end | |
| 1122 | end | |
| 1123 | if ATTACK == false then | |
| 1124 | if TORSOVELOCITY < 1 then | |
| 1125 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(4 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 1126 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(15 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(0 - 4 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 1127 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 1128 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 1129 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 1130 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-7.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 1131 | elseif TORSOVELOCITY > 1 then | |
| 1132 | RootJoint.C0 = Clerp(RootJoint.C0,ROOTC0 * CF(0, 0, 0 + 0.25 * COS(SINE / 12)) * ANGLES(RAD(15 + 2.5 * SIN(SINE / 12)), RAD(0), RAD(2.5 + 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 1133 | Neck.C0 = Clerp(Neck.C0, NECKC0 * CF(0, 0, 0 + ((1) - 1)) * ANGLES(RAD(-10 + 4.5 * SIN(SINE / 12)), RAD(0), RAD(-2.5 - 2.5 * SIN(SINE / 12))), 1 / Animation_Speed) | |
| 1134 | RightShoulder.C0 = Clerp(RightShoulder.C0, CF(1, 0.5 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(0), RAD(0 - 7.5 * SIN(SINE / 12)), RAD(-90 + 7.5 * SIN(SINE / 12))) * RIGHTSHOULDERC0, 1 / Animation_Speed) | |
| 1135 | LeftShoulder.C0 = Clerp(LeftShoulder.C0, CF(-1, 0 + 0.025 * COS(SINE / 12), -1) * ANGLES(RAD(25), RAD(0 + 7.5 * SIN(SINE / 12)), RAD(90 - 7.5 * SIN(SINE / 12))) * LEFTSHOULDERC0, 1 / Animation_Speed) | |
| 1136 | RightHip.C0 = Clerp(RightHip.C0, CF(1, -1, -0.01) * ANGLES(RAD(-25-2.5 * SIN(SINE / 12)), RAD(75), RAD(0)) * ANGLES(RAD(-8 - 5.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 1137 | LeftHip.C0 = Clerp(LeftHip.C0, CF(-1, -0.5, -0.5) * ANGLES(RAD(-2.5 * SIN(SINE / 12)), RAD(-90), RAD(0)) * ANGLES(RAD(-8 - 2.5 * SIN(SINE / 12)), RAD(0), RAD(0)), 1 / Animation_Speed) | |
| 1138 | end | |
| 1139 | end | |
| 1140 | for _, c in pairs(Character:GetChildren()) do | |
| 1141 | if c.ClassName == "Part" and c.Name ~= "Eye" then | |
| 1142 | c.Material = "Neon" | |
| 1143 | if c:FindFirstChildOfClass("ParticleEmitter") then
| |
| 1144 | c:FindFirstChildOfClass("ParticleEmitter"):remove()
| |
| 1145 | end | |
| 1146 | if c ~= Head and c ~= RootPart and c:FindFirstChild("BoxEffect") == nil then
| |
| 1147 | local EF = Instance.new("SelectionBox",c)
| |
| 1148 | EF.Adornee = c | |
| 1149 | EF.Color = BrickColor.new("Really red")
| |
| 1150 | EF.LineThickness = 0.01 | |
| 1151 | EF.Transparency = 0 | |
| 1152 | EF.Name = "BoxEffect" | |
| 1153 | end | |
| 1154 | c.Color = C3(0,0,0) | |
| 1155 | if c == Head then | |
| 1156 | --[[if c:FindFirstChild("Dominus") == nil then
| |
| 1157 | local M = CreateMesh("SpecialMesh", c, "FileMesh", "162384581", "162384608", VT(1,1,1)*1.1, VT(0,0,0))
| |
| 1158 | M.Name = "Dominus" | |
| 1159 | end]]-- | |
| 1160 | if c:FindFirstChild("face") then
| |
| 1161 | c.face:remove() | |
| 1162 | end | |
| 1163 | end | |
| 1164 | elseif c.ClassName == "Shirt" or c.ClassName == "Pants" or c.ClassName == "CharacterMesh" or c.ClassName == "Accessory" or c.Name == "Body Colors" then | |
| 1165 | c:remove() | |
| 1166 | end | |
| 1167 | end | |
| 1168 | if HITFLOOR ~= nil and MRANDOM(1,6) == 1 then | |
| 1169 | local POSITION = CF(HITPOS)*ANGLES(RAD(0),RAD(MRANDOM(0,360)),RAD(0))*CF(MRANDOM(5,15),0,0).p | |
| 1170 | local BOXFLOOR,BOXPOS = Raycast(POSITION+VT(0,1,0), (CF(POSITION, POSITION + VT(0, -1, 0))).lookVector, 5, Character) | |
| 1171 | if BOXFLOOR ~= nil then | |
| 1172 | WACKYEFFECT({EffectType = "Box", Size = VT(2,0,2), Size2 = VT(0,15,0), Transparency = 0.5, Transparency2 = 0.5, CFrame = CF(BOXPOS), MoveToPos = nil, RotationX = 0, RotationY = 0, RotationZ = 0, Material = "Neon", Color = BRICKC"Really red".Color, SoundID = nil, SoundPitch = nil, SoundVolume = nil})
| |
| 1173 | end | |
| 1174 | end | |
| 1175 | unanchor() | |
| 1176 | Humanoid.MaxHealth = "inf" | |
| 1177 | Humanoid.Health = "inf" | |
| 1178 | if Rooted == false then | |
| 1179 | Disable_Jump = false | |
| 1180 | Humanoid.WalkSpeed = Speed | |
| 1181 | elseif Rooted == true then | |
| 1182 | Disable_Jump = true | |
| 1183 | Humanoid.WalkSpeed = 0 | |
| 1184 | end | |
| 1185 | for _, c in pairs(workspace:GetChildren()) do | |
| 1186 | if c.ClassName == "Model" and c:FindFirstChild("Humanoid") and c ~= Character then
| |
| 1187 | end | |
| 1188 | end | |
| 1189 | script.Parent = WEAPONGUI | |
| 1190 | Humanoid.Name = "Monarch" | |
| 1191 | sick.Parent = Effects | |
| 1192 | sick.Pitch = 0.85 | |
| 1193 | sick.Playing = true | |
| 1194 | for _, q in pairs(Head:GetChildren()) do | |
| 1195 | if q.ClassName == "Sound" and q.Name ~= "Audio" then | |
| 1196 | q:remove() | |
| 1197 | end | |
| 1198 | end | |
| 1199 | Humanoid.DisplayDistanceType = "None" | |
| 1200 | end | |
| 1201 | ||
| 1202 | --//=================================\\ | |
| 1203 | --\\=================================// | |
| 1204 | ||
| 1205 | ||
| 1206 | ||
| 1207 | ||
| 1208 | ||
| 1209 | --//====================================================\\-- | |
| 1210 | --|| END OF SCRIPT | |
| 1211 | --\\====================================================//-- |