SHOW:
|
|
- or go back to the newest paste.
| 1 | if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
| |
| 2 | ||
| 3 | local Player,game,owner = owner,game | |
| 4 | ||
| 5 | local RealPlayer = Player | |
| 6 | ||
| 7 | do print("FE Compatibility code V3 by Desered_ROBLOX")local RealPlayer=RealPlayer;script.Parent=RealPlayer.Character;local a=function(b)b[1].f[b[2]]=nil end;local c={__index={disconnect=a,Disconnect=a}}local d={__index={Connect=function(b,e)local f=tostring(math.random(0,10000))while b.f[f]do f=tostring(math.random(0,10000))end;b.f[f]=e;return setmetatable({b,f},c)end}}d.__index.connect=d.__index.Connect;local function g()return setmetatable({f={}},d)end;local h={Hit=CFrame.new(),KeyUp=g(),KeyDown=g(),Button1Up=g(),Button1Down=g(),Button2Up=g(),Button2Down=g()}h.keyUp=h.KeyUp;h.keyDown=h.KeyDown;local i={InputBegan=g(),InputEnded=g()}local CAS={Actions={},BindAction=function(self,j,k,l,...)CAS.Actions[j]=k and{Name=j,Function=k,Keys={...}}or nil end}CAS.UnbindAction=CAS.BindAction;local function m(self,n,...)for o,e in pairs(self[n].f)do e(...)end end;h.T=m;i.T=m;local p=Instance.new("RemoteEvent")p.Name="UserInput_Event"p.OnServerEvent:Connect(function(q,r)if q~=RealPlayer then return end;h.Target=r.e;h.Hit=r.d;if not r.f then local s=r.c==Enum.UserInputState.Begin;if r.b==Enum.UserInputType.MouseButton1 then return h:T(s and"Button1Down"or"Button1Up")end;if r.b==Enum.UserInputType.MouseButton2 then return h:T(s and"Button2Down"or"Button2Up")end;for o,t in pairs(CAS.Actions)do for o,u in pairs(t.Keys)do if u==r.a then t.Function(t.Name,r.c,r)end end end;h:T(s and"KeyDown"or"KeyUp",r.a.Name:lower())i:T(s and"InputBegan"or"InputEnded",r,false)end end)p.Parent=NLS([==[local a=script:WaitForChild("UserInput_Event")local b=owner:GetMouse()local c=game:GetService("UserInputService")local d=function(e,f)if f then return end;a:FireServer({a=e.KeyCode,b=e.UserInputType,c=e.UserInputState,d=b.Hit,e=b.Target})end;c.InputBegan:Connect(d)c.InputEnded:Connect(d)local g,h;local i=game:GetService("RunService").Heartbeat;while true do if g~=b.Hit or h~=b.Target then g,h=b.Hit,b.Target;a:FireServer({f=1,Target=h,d=g})end;for j=1,2 do i:Wait()end end]==],script)local v=game;local w={__index=function(self,u)local x=rawget(self,"_RealService")if x then return typeof(x[u])=="function"and function(o,...)return x[u](x,...)end or x[u]end end,__newindex=function(self,u,y)local x=rawget(self,"_RealService")if x then x[u]=y end end}local function z(t,A)t._RealService=typeof(A)=="string"and v:GetService(A)or A;return setmetatable(t,w)end;local B={GetService=function(self,x)return rawget(self,x)or v:GetService(x)end,Players=z({LocalPlayer=z({GetMouse=function(self)return h end},Player)},"Players"),UserInputService=z(i,"UserInputService"),ContextActionService=z(CAS,"ContextActionService"),RunService=z({_btrs={},RenderStepped=v:GetService("RunService").Heartbeat,BindToRenderStep=function(self,j,o,k)self._btrs[j]=self.Heartbeat:Connect(k)end,UnbindFromRenderStep=function(self,j)self._btrs[j]:Disconnect()end},"RunService")}rawset(B.Players,"localPlayer",B.Players.LocalPlayer)B.service=B.GetService;z(B,game)game,owner=B,B.Players.LocalPlayer end
| |
| 8 | --//====================================================\\-- | |
| 9 | --|| CREATED BY SHACKLUSTER | |
| 10 | --\\====================================================//-- | |
| 11 | ||
| 12 | ||
| 13 | ||
| 14 | wait(0.2) | |
| 15 | ||
| 16 | ||
| 17 | ||
| 18 | Player = game:GetService("Players").LocalPlayer
| |
| 19 | PlayerGui = Player.PlayerGui | |
| 20 | Cam = workspace.CurrentCamera | |
| 21 | Backpack = Player.Backpack | |
| 22 | Character = Player.Character | |
| 23 | Humanoid = Character.Humanoid | |
| 24 | Mouse = Player:GetMouse() | |
| 25 | RootPart = Character["HumanoidRootPart"] | |
| 26 | Torso = Character["Torso"] | |
| 27 | Head = Character["Head"] | |
| 28 | RightArm = Character["Right Arm"] | |
| 29 | LeftArm = Character["Left Arm"] | |
| 30 | RightLeg = Character["Right Leg"] | |
| 31 | LeftLeg = Character["Left Leg"] | |
| 32 | RootJoint = RootPart["RootJoint"] | |
| 33 | Neck = Torso["Neck"] | |
| 34 | RightShoulder = Torso["Right Shoulder"] | |
| 35 | LeftShoulder = Torso["Left Shoulder"] | |
| 36 | RightHip = Torso["Right Hip"] | |
| 37 | LeftHip = Torso["Left Hip"] | |
| 38 | local sick = Instance.new("Sound",Character)
| |
| 39 | sick.SoundId = "rbxassetid://142748120" | |
| 40 | sick.Looped = true | |
| 41 | sick.Pitch = 1 | |
| 42 | sick.Volume = 5 | |
| 43 | sick:Play() | |
| 44 | Humanoid.DisplayDistanceType = "None" | |
| 45 | - | naeeym2.PlayerToHideFrom = Player |
| 45 | + | |
| 46 | local naeeym2 = Instance.new("BillboardGui",Character)
| |
| 47 | naeeym2.AlwaysOnTop = true | |
| 48 | naeeym2.Size = UDim2.new(5,35,2,35) | |
| 49 | naeeym2.StudsOffset = Vector3.new(0,1,0) | |
| 50 | naeeym2.Adornee = Character.Head | |
| 51 | naeeym2.Name = "Name" | |
| 52 | local tecks2 = Instance.new("TextLabel",naeeym2)
| |
| 53 | tecks2.BackgroundTransparency = 1 | |
| 54 | tecks2.TextScaled = true | |
| 55 | tecks2.BorderSizePixel = 0 | |
| 56 | tecks2.Text = "SMILE" | |
| 57 | tecks2.Font = "Antique" | |
| 58 | tecks2.TextSize = 30 | |
| 59 | tecks2.TextStrokeTransparency = 0.5 | |
| 60 | tecks2.TextColor3 = Color3.new(0,0,0) | |
| 61 | tecks2.TextStrokeColor3 = Color3.new(0,0,0) | |
| 62 | tecks2.Size = UDim2.new(1,0,0.5,0) | |
| 63 | tecks2.Parent = naeeym2 | |
| 64 | ||
| 65 | IT = Instance.new | |
| 66 | CF = CFrame.new | |
| 67 | VT = Vector3.new | |
| 68 | RAD = math.rad | |
| 69 | C3 = Color3.new | |
| 70 | UD2 = UDim2.new | |
| 71 | BRICKC = BrickColor.new | |
| 72 | ANGLES = CFrame.Angles | |
| 73 | EULER = CFrame.fromEulerAnglesXYZ | |
| 74 | COS = math.cos | |
| 75 | ACOS = math.acos | |
| 76 | SIN = math.sin | |
| 77 | ASIN = math.asin | |
| 78 | ABS = math.abs | |
| 79 | MRANDOM = math.random | |
| 80 | FLOOR = math.floor | |
| 81 | ||
| 82 | local sound = IT("Sound")
| |
| 83 | ||
| 84 | function CreateMesh(MESH, PARENT, MESHTYPE, MESHID, TEXTUREID, SCALE, OFFSET) | |
| 85 | local NEWMESH = IT(MESH) | |
| 86 | if MESH == "SpecialMesh" then | |
| 87 | NEWMESH.MeshType = MESHTYPE | |
| 88 | if MESHID ~= "nil" and MESHID ~= "" then | |
| 89 | NEWMESH.MeshId = "http://www.roblox.com/asset/?id="..MESHID | |
| 90 | end | |
| 91 | if TEXTUREID ~= "nil" and TEXTUREID ~= "" then | |
| 92 | NEWMESH.TextureId = "http://www.roblox.com/asset/?id="..TEXTUREID | |
| 93 | end | |
| 94 | end | |
| 95 | NEWMESH.Offset = OFFSET or VT(0, 0, 0) | |
| 96 | NEWMESH.Scale = SCALE | |
| 97 | NEWMESH.Parent = PARENT | |
| 98 | return NEWMESH | |
| 99 | end | |
| 100 | ||
| 101 | function CreatePart(FORMFACTOR, PARENT, MATERIAL, REFLECTANCE, TRANSPARENCY, BRICKCOLOR, NAME, SIZE) | |
| 102 | local NEWPART = IT("Part")
| |
| 103 | NEWPART.formFactor = FORMFACTOR | |
| 104 | NEWPART.Reflectance = REFLECTANCE | |
| 105 | NEWPART.Transparency = TRANSPARENCY | |
| 106 | NEWPART.CanCollide = false | |
| 107 | NEWPART.Locked = true | |
| 108 | NEWPART.BrickColor = BRICKC(tostring(BRICKCOLOR)) | |
| 109 | NEWPART.Name = NAME | |
| 110 | NEWPART.Size = SIZE | |
| 111 | NEWPART.Position = Torso.Position | |
| 112 | NEWPART.Material = MATERIAL | |
| 113 | NEWPART:BreakJoints() | |
| 114 | NEWPART.Parent = PARENT | |
| 115 | return NEWPART | |
| 116 | end | |
| 117 | ||
| 118 | local EyeSizes={
| |
| 119 | NumberSequenceKeypoint.new(0,1,0), | |
| 120 | NumberSequenceKeypoint.new(1,0.2,0) | |
| 121 | } | |
| 122 | local EyeTrans={
| |
| 123 | NumberSequenceKeypoint.new(0,0.8,0), | |
| 124 | NumberSequenceKeypoint.new(1,1,0) | |
| 125 | } | |
| 126 | local PE=Instance.new("ParticleEmitter")
| |
| 127 | PE.LightEmission=0 | |
| 128 | PE.Size=NumberSequence.new(EyeSizes) | |
| 129 | PE.Transparency=NumberSequence.new(EyeTrans) | |
| 130 | PE.Lifetime=NumberRange.new(0.35,0.35,0.35) | |
| 131 | PE.Rotation=NumberRange.new(0,360) | |
| 132 | PE.Rate=15 | |
| 133 | PE.Acceleration = Vector3.new(0,75,0) | |
| 134 | PE.Drag = 5 | |
| 135 | PE.Enabled = false | |
| 136 | PE.Speed = NumberRange.new(0,0,0) | |
| 137 | PE.Texture="http://www.roblox.com/asset/?id=1179557490" | |
| 138 | PE.ZOffset = 0 | |
| 139 | PE.Name = "Inferno" | |
| 140 | ||
| 141 | function particles(art) | |
| 142 | local particle = PE:Clone() | |
| 143 | particle.Parent = art | |
| 144 | particle.Enabled = true | |
| 145 | end | |
| 146 | ||
| 147 | --//=================================\\ | |
| 148 | --|| CUSTOMIZATION | |
| 149 | --\\=================================// | |
| 150 | ||
| 151 | Class_Name = "SMILE" | |
| 152 | Weapon_Name = "Add-ons" | |
| 153 | ||
| 154 | Custom_Colors = {
| |
| 155 | Custom_Color_1 = BRICKC("Institutional white"); --1st color for the weapon.
| |
| 156 | Custom_Color_2 = BRICKC("Institutional white"); --2nd color for the weapon.
| |
| 157 | ||
| 158 | Custom_Color_3 = BRICKC("Institutional white"); --Color for the abilities.
| |
| 159 | Custom_Color_4 = BRICKC("Institutional white"); --Color for the secondary bar.
| |
| 160 | Custom_Color_5 = BRICKC("Institutional white"); --Color for the mana bar.
| |
| 161 | Custom_Color_6 = BRICKC("Institutional white"); --Color for the health bar.
| |
| 162 | Custom_Color_7 = BRICKC("Institutional white"); --Color for the stun bar.
| |
| 163 | ||
| 164 | Custom_Color_8 = BRICKC("Institutional white"); --Background for the mana bar.
| |
| 165 | Custom_Color_9 = BRICKC("Institutional white"); --Background for the secondary mana bar.
| |
| 166 | Custom_Color_10 = BRICKC("Institutional white"); --Background for the stun bar.
| |
| 167 | Custom_Color_11 = BRICKC("Institutional white"); --Background for the health bar.
| |
| 168 | Custom_Color_12 = BRICKC("Institutional white"); --Background for the abilities.
| |
| 169 | } | |
| 170 | ||
| 171 | ||
| 172 | Player_Size = 1 --Size of the player. | |
| 173 | Animation_Speed = 3 | |
| 174 | Frame_Speed = 1 / 60 -- (1 / 30) OR (1 / 60) | |
| 175 | ||
| 176 | local Speed = 16 | |
| 177 | local Effects2 = {}
| |
| 178 | ||
| 179 | --//=================================\\ | |
| 180 | --|| END OF CUSTOMIZATION | |
| 181 | --\\=================================// | |
| 182 | ||
| 183 | local function weldBetween(a, b) | |
| 184 | local weldd = Instance.new("ManualWeld")
| |
| 185 | weldd.Part0 = a | |
| 186 | weldd.Part1 = b | |
| 187 | weldd.C0 = CFrame.new() | |
| 188 | weldd.C1 = b.CFrame:inverse() * a.CFrame | |
| 189 | weldd.Parent = a | |
| 190 | return weldd | |
| 191 | end | |
| 192 | ||
| 193 | function createaccessory(attachmentpart,mesh,texture,scale,offset,color) | |
| 194 | local acs = Instance.new("Part")
| |
| 195 | acs.CanCollide = false | |
| 196 | acs.Anchored = false | |
| 197 | acs.Size = Vector3.new(0,0,0) | |
| 198 | acs.CFrame = attachmentpart.CFrame | |
| 199 | acs.Parent = Character | |
| 200 | acs.BrickColor = color | |
| 201 | local meshs = Instance.new("SpecialMesh")
| |
| 202 | meshs.MeshId = mesh | |
| 203 | meshs.TextureId = texture | |
| 204 | meshs.Parent = acs | |
| 205 | meshs.Scale = scale | |
| 206 | meshs.Offset = offset | |
| 207 | weldBetween(attachmentpart,acs) | |
| 208 | end | |
| 209 | ||
| 210 | function createbodypart(TYPE,COLOR,PART,OFFSET,SIZE) | |
| 211 | if TYPE == "Gem" then | |
| 212 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0)) | |
| 213 | acs.Anchored = false | |
| 214 | acs.CanCollide = false | |
| 215 | acs.CFrame = PART.CFrame | |
| 216 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "9756362", "", SIZE, OFFSET)
| |
| 217 | weldBetween(PART,acs) | |
| 218 | elseif TYPE == "Skull" then | |
| 219 | local acs = CreatePart(3, Character, "Plastic", 0, 0, COLOR, "Part", VT(0,0,0)) | |
| 220 | acs.Anchored = false | |
| 221 | acs.CanCollide = false | |
| 222 | acs.CFrame = PART.CFrame | |
| 223 | local acs2 = CreateMesh("SpecialMesh", acs, "FileMesh", "4770583", "", SIZE, OFFSET)
| |
| 224 | weldBetween(PART,acs) | |
| 225 | elseif TYPE == "Eye" then | |
| 226 | local acs = CreatePart(3, Character, "Neon", 0, 0, COLOR, "Part", VT(0,0,0)) | |
| 227 | acs.Anchored = false | |
| 228 | acs.CanCollide = false | |
| 229 | acs.CFrame = PART.CFrame | |
| 230 | local acs2 = CreateMesh("SpecialMesh", acs, "Sphere", "", "", SIZE, OFFSET)
| |
| 231 | weldBetween(PART,acs) | |
| 232 | end | |
| 233 | end | |
| 234 | ||
| 235 | --//=================================\\ | |
| 236 | --|| USEFUL VALUES | |
| 237 | --\\=================================// | |
| 238 | ||
| 239 | local ROOTC0 = CF(0, 0, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 240 | local NECKC0 = CF(0, 1, 0) * ANGLES(RAD(-90), RAD(0), RAD(180)) | |
| 241 | local RIGHTSHOULDERC0 = CF(-0.5, 0, 0) * ANGLES(RAD(0), RAD(90), RAD(0)) | |
| 242 | local LEFTSHOULDERC0 = CF(0.5, 0, 0) * ANGLES(RAD(0), RAD(-90), RAD(0)) | |
| 243 | local CO1 = 0 | |
| 244 | local CO2 = 0 | |
| 245 | local CO3 = 0 | |
| 246 | local CO4 = 0 | |
| 247 | local CHANGEDEFENSE = 0 | |
| 248 | local CHANGEDAMAGE = 0 | |
| 249 | local CHANGEMOVEMENT = 0 | |
| 250 | local ANIM = "Idle" | |
| 251 | local ATTACK = false | |
| 252 | local EQUIPPED = false | |
| 253 | local HOLD = false | |
| 254 | local COMBO = 1 | |
| 255 | local LASTPOINT = nil | |
| 256 | local BLCF = nil | |
| 257 | local SCFR = nil | |
| 258 | local STAGGERHITANIM = false | |
| 259 | local STAGGERANIM = false | |
| 260 | local STUNANIM = false | |
| 261 | local CRITCHANCENUMBER = 0 | |
| 262 | local IDLENUMBER = 0 | |
| 263 | local DONUMBER = 0 | |
| 264 | local HANDIDLE = false | |
| 265 | local SINE = 0 | |
| 266 | local CHANGE = 2 / Animation_Speed | |
| 267 | local WALKINGANIM = false | |
| 268 | local WALK = 0 | |
| 269 | local DISABLEJUMPING = false | |
| 270 | local HASBEENBLOCKED = false | |
| 271 | local STUNDELAYNUMBER = 0 | |
| 272 | local MANADELAYNUMBER = 0 | |
| 273 | local OTHERWORLD = false | |
| 274 | local SECONDARYMANADELAYNUMBER = 0 | |
| 275 | local ROBLOXIDLEANIMATION = IT("Animation")
| |
| 276 | ROBLOXIDLEANIMATION.Name = "Roblox Idle Animation" | |
| 277 | ROBLOXIDLEANIMATION.AnimationId = "http://www.roblox.com/asset/?id=180435571" | |
| 278 | --ROBLOXIDLEANIMATION.Parent = Humanoid | |
| 279 | local WEAPONGUI = IT("ScreenGui", nil)
| |
| 280 | WEAPONGUI.Name = "Weapon GUI" | |
| 281 | local WEAPONTOOL = IT("HopperBin", nil)
| |
| 282 | WEAPONTOOL.Name = Weapon_Name | |
| 283 | local Weapon = IT("Model")
| |
| 284 | Weapon.Name = Weapon_Name | |
| 285 | local Effects = IT("Folder", Weapon)
| |
| 286 | Effects.Name = "Effects" | |
| 287 | local ANIMATOR = Humanoid.Animator | |
| 288 | local ANIMATE = Character.Animate | |
| 289 | local HITPLAYERSOUNDS = {--[["199149137", "199149186", "199149221", "199149235", "199149269", "199149297"--]]"263032172", "263032182", "263032200", "263032221", "263032252", "263033191"}
| |
| 290 | local HITARMORSOUNDS = {"199149321", "199149338", "199149367", "199149409", "199149452"}
| |
| 291 | local HITWEAPONSOUNDS = {"199148971", "199149025", "199149072", "199149109", "199149119"}
| |
| 292 | local HITBLOCKSOUNDS = {"199148933", "199148947"}
| |
| 293 | local UNANCHOR = true | |
| 294 | ||
| 295 | --//=================================\\ | |
| 296 | --\\=================================// | |
| 297 | ||
| 298 | ||
| 299 | ||
| 300 | ||
| 301 | --//=================================\\ | |
| 302 | --|| SAZERENOS' ARTIFICIAL HEARTBEAT | |
| 303 | --\\=================================// | |
| 304 | ||
| 305 | ArtificialHB = Instance.new("BindableEvent", script)
| |
| 306 | ArtificialHB.Name = "ArtificialHB" | |
| 307 | ||
| 308 | script:WaitForChild("ArtificialHB")
| |
| 309 | ||
| 310 | frame = Frame_Speed | |
| 311 | tf = 0 | |
| 312 | allowframeloss = false | |
| 313 | tossremainder = false | |
| 314 | lastframe = tick() | |
| 315 | script.ArtificialHB:Fire() | |
| 316 | ||
| 317 | game:GetService("RunService").Heartbeat:connect(function(s, p)
| |
| 318 | tf = tf + s | |
| 319 | if tf >= frame then | |
| 320 | if allowframeloss then | |
| 321 | script.ArtificialHB:Fire() | |
| 322 | lastframe = tick() | |
| 323 | else | |
| 324 | for i = 1, math.floor(tf / frame) do | |
| 325 | script.ArtificialHB:Fire() | |
| 326 | end | |
| 327 | lastframe = tick() | |
| 328 | end | |
| 329 | if tossremainder then | |
| 330 | tf = 0 | |
| 331 | else | |
| 332 | tf = tf - frame * math.floor(tf / frame) | |
| 333 | end | |
| 334 | end | |
| 335 | end) | |
| 336 | ||
| 337 | --//=================================\\ | |
| 338 | --\\=================================// | |
| 339 | ||
| 340 | ||
| 341 | ||
| 342 | ||
| 343 | ||
| 344 | --//=================================\\ | |
| 345 | --|| SOME FUNCTIONS | |
| 346 | --\\=================================// | |
| 347 | ||
| 348 | function Raycast(POSITION, DIRECTION, RANGE, IGNOREDECENDANTS) | |
| 349 | return workspace:FindPartOnRay(Ray.new(POSITION, DIRECTION.unit * RANGE), IGNOREDECENDANTS) | |
| 350 | end | |
| 351 | ||
| 352 | function PositiveAngle(NUMBER) | |
| 353 | if NUMBER >= 0 then | |
| 354 | NUMBER = 0 | |
| 355 | end | |
| 356 | return NUMBER | |
| 357 | end | |
| 358 | ||
| 359 | function NegativeAngle(NUMBER) | |
| 360 | if NUMBER <= 0 then | |
| 361 | NUMBER = 0 | |
| 362 | end | |
| 363 | return NUMBER | |
| 364 | end | |
| 365 | ||
| 366 | function Swait(NUMBER) | |
| 367 | if NUMBER == 0 or NUMBER == nil then | |
| 368 | ArtificialHB.Event:wait() | |
| 369 | else | |
| 370 | for i = 1, NUMBER do | |
| 371 | ArtificialHB.Event:wait() | |
| 372 | end | |
| 373 | end | |
| 374 | end | |
| 375 | ||
| 376 | function QuaternionFromCFrame(cf) | |
| 377 | local mx, my, mz, m00, m01, m02, m10, m11, m12, m20, m21, m22 = cf:components() | |
| 378 | local trace = m00 + m11 + m22 | |
| 379 | if trace > 0 then | |
| 380 | local s = math.sqrt(1 + trace) | |
| 381 | local recip = 0.5 / s | |
| 382 | return (m21 - m12) * recip, (m02 - m20) * recip, (m10 - m01) * recip, s * 0.5 | |
| 383 | else | |
| 384 | local i = 0 | |
| 385 | if m11 > m00 then | |
| 386 | i = 1 | |
| 387 | end | |
| 388 | if m22 > (i == 0 and m00 or m11) then | |
| 389 | i = 2 | |
| 390 | end | |
| 391 | if i == 0 then | |
| 392 | local s = math.sqrt(m00 - m11 - m22 + 1) | |
| 393 | local recip = 0.5 / s | |
| 394 | return 0.5 * s, (m10 + m01) * recip, (m20 + m02) * recip, (m21 - m12) * recip | |
| 395 | elseif i == 1 then | |
| 396 | local s = math.sqrt(m11 - m22 - m00 + 1) | |
| 397 | local recip = 0.5 / s | |
| 398 | return (m01 + m10) * recip, 0.5 * s, (m21 + m12) * recip, (m02 - m20) * recip | |
| 399 | elseif i == 2 then | |
| 400 | local s = math.sqrt(m22 - m00 - m11 + 1) | |
| 401 | local recip = 0.5 / s return (m02 + m20) * recip, (m12 + m21) * recip, 0.5 * s, (m10 - m01) * recip | |
| 402 | end | |
| 403 | end | |
| 404 | end | |
| 405 | ||
| 406 | function QuaternionToCFrame(px, py, pz, x, y, z, w) | |
| 407 | local xs, ys, zs = x + x, y + y, z + z | |
| 408 | local wx, wy, wz = w * xs, w * ys, w * zs | |
| 409 | local xx = x * xs | |
| 410 | local xy = x * ys | |
| 411 | local xz = x * zs | |
| 412 | local yy = y * ys | |
| 413 | local yz = y * zs | |
| 414 | local zz = z * zs | |
| 415 | 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)) | |
| 416 | end | |
| 417 | ||
| 418 | function QuaternionSlerp(a, b, t) | |
| 419 | local cosTheta = a[1] * b[1] + a[2] * b[2] + a[3] * b[3] + a[4] * b[4] | |
| 420 | local startInterp, finishInterp; | |
| 421 | if cosTheta >= 0.0001 then | |
| 422 | if (1 - cosTheta) > 0.0001 then | |
| 423 | local theta = ACOS(cosTheta) | |
| 424 | local invSinTheta = 1 / SIN(theta) | |
| 425 | startInterp = SIN((1 - t) * theta) * invSinTheta | |
| 426 | finishInterp = SIN(t * theta) * invSinTheta | |
| 427 | else | |
| 428 | startInterp = 1 - t | |
| 429 | finishInterp = t | |
| 430 | end | |
| 431 | else | |
| 432 | if (1 + cosTheta) > 0.0001 then | |
| 433 | local theta = ACOS(-cosTheta) | |
| 434 | local invSinTheta = 1 / SIN(theta) | |
| 435 | startInterp = SIN((t - 1) * theta) * invSinTheta | |
| 436 | finishInterp = SIN(t * theta) * invSinTheta | |
| 437 | else | |
| 438 | startInterp = t - 1 | |
| 439 | finishInterp = t | |
| 440 | end | |
| 441 | end | |
| 442 | 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 | |
| 443 | end | |
| 444 | ||
| 445 | function Clerp(a, b, t) | |
| 446 | local qa = {QuaternionFromCFrame(a)}
| |
| 447 | local qb = {QuaternionFromCFrame(b)}
| |
| 448 | local ax, ay, az = a.x, a.y, a.z | |
| 449 | local bx, by, bz = b.x, b.y, b.z | |
| 450 | local _t = 1 - t | |
| 451 | return QuaternionToCFrame(_t * ax + t * bx, _t * ay + t * by, _t * az + t * bz, QuaternionSlerp(qa, qb, t)) | |
| 452 | end | |
| 453 | ||
| 454 | ||
| 455 | function CreateSound(ID, PARENT, VOLUME, PITCH) | |
| 456 | coroutine.resume(coroutine.create(function() | |
| 457 | local NEWSOUND = IT("Sound", PARENT)
| |
| 458 | NEWSOUND.Volume = VOLUME | |
| 459 | NEWSOUND.Pitch = PITCH | |
| 460 | NEWSOUND.SoundId = "http://www.roblox.com/asset/?id="..ID | |
| 461 | Swait() | |
| 462 | NEWSOUND:play() | |
| 463 | game:GetService("Debris"):AddItem(NEWSOUND, 10)
| |
| 464 | end)) | |
| 465 | end | |
| 466 | ||
| 467 | local decal = IT("Decal")
| |
| 468 | ||
| 469 | function CreatePentagram(size,doesrotate,rotatedirection,waitt,cframe,offset,doeskill) | |
| 470 | local sinkhole = IT("Part",workspace)
| |
| 471 | if doeskill == true then | |
| 472 | local hit = sinkhole.Touched:Connect(function(hit) | |
| 473 | if hit.Parent ~= Character and hit.Parent:FindFirstChild("Humanoid") then
| |
| 474 | kill(hit.Parent,true) | |
| 475 | hit.Parent:remove() | |
| 476 | end | |
| 477 | end) | |
| 478 | end | |
| 479 | sinkhole.Size = VT(size,0,size) | |
| 480 | - | local decal = decal:Clone() |
| 480 | + | |
| 481 | sinkhole.Material = "Neon" | |
| 482 | sinkhole.Color = C3(1,0,0) | |
| 483 | sinkhole.Anchored = true | |
| 484 | sinkhole.CanCollide = false | |
| 485 | sinkhole.Transparency = 1 | |
| 486 | decal.Parent = sinkhole | |
| 487 | decal.Face = "Top" | |
| 488 | decal.Texture = "http://www.roblox.com/asset/?id=818983932" | |
| 489 | coroutine.resume(coroutine.create(function(PART) | |
| 490 | for i = 1, waitt do | |
| 491 | Swait() | |
| 492 | if doesrotate == true then | |
| 493 | sinkhole.CFrame = sinkhole.CFrame * CFrame.fromEulerAnglesXYZ(0, rotatedirection, 0) | |
| 494 | end | |
| 495 | if i > waitt-11 then | |
| 496 | decal.Transparency = decal.Transparency + 0.1 | |
| 497 | end | |
| 498 | end | |
| 499 | sinkhole:remove() | |
| 500 | end)) | |
| 501 | return sinkhole | |
| 502 | end | |
| 503 | ||
| 504 | Weapon.Parent = Character | |
| 505 | ||
| 506 | Humanoid.Died:connect(function() | |
| 507 | workspace:ClearAllChildren() | |
| 508 | end) | |
| 509 | ||
| 510 | --//=================================\\ | |
| 511 | --\\=================================// | |
| 512 | ||
| 513 | ||
| 514 | --//=================================\\ | |
| 515 | --|| DAMAGING | |
| 516 | --\\=================================// | |
| 517 | ||
| 518 | function kill(target,extratrue) | |
| 519 | if OTHERWORLD == false or extratrue == true then | |
| 520 | f = target:GetChildren() | |
| 521 | for i = 1, #f do | |
| 522 | if f[i].ClassName == "Part" or f[i].ClassName == "MeshPart" then | |
| 523 | local effect = f[i]:Clone() | |
| 524 | effect.Color = C3(1,1,1) | |
| 525 | effect.Material = "Neon" | |
| 526 | effect.Parent = workspace | |
| 527 | effect.Anchored = true | |
| 528 | effect.CanCollide = false | |
| 529 | local hit = effect.Touched:Connect(function(hit) | |
| 530 | if hit.Parent ~= Character and hit.Parent:FindFirstChild("Humanoid") then
| |
| 531 | kill(hit.Parent) | |
| 532 | hit.Parent:remove() | |
| 533 | end | |
| 534 | end) | |
| 535 | m = effect:GetChildren() | |
| 536 | for j = 1, #m do | |
| 537 | if m[j].ClassName ~= "SpecialMesh" and m[j].ClassName ~= "BlockMesh" then | |
| 538 | m[j]:remove() | |
| 539 | end | |
| 540 | end | |
| 541 | table.insert(Effects2,{effect,"Disappear",0.01,1,1,1,15})
| |
| 542 | end | |
| 543 | end | |
| 544 | target:remove() | |
| 545 | end | |
| 546 | end | |
| 547 | ||
| 548 | --//=================================\\ | |
| 549 | --|| ATTACK FUNCTIONS AND STUFF | |
| 550 | --\\=================================// | |
| 551 | ||
| 552 | local hit = Torso.Touched:Connect(function(hit) | |
| 553 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 554 | kill(hit.Parent) | |
| 555 | end | |
| 556 | end) | |
| 557 | local hit = RightArm.Touched:Connect(function(hit) | |
| 558 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 559 | kill(hit.Parent) | |
| 560 | end | |
| 561 | end) | |
| 562 | local hit = LeftArm.Touched:Connect(function(hit) | |
| 563 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 564 | kill(hit.Parent) | |
| 565 | end | |
| 566 | end) | |
| 567 | local hit = RightLeg.Touched:Connect(function(hit) | |
| 568 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 569 | kill(hit.Parent) | |
| 570 | end | |
| 571 | end) | |
| 572 | local hit = LeftLeg.Touched:Connect(function(hit) | |
| 573 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 574 | kill(hit.Parent) | |
| 575 | end | |
| 576 | end) | |
| 577 | local hit = Head.Touched:Connect(function(hit) | |
| 578 | if hit.Parent:FindFirstChild("Humanoid") then
| |
| 579 | kill(hit.Parent) | |
| 580 | end | |
| 581 | end) | |
| 582 | ||
| 583 | function Warp() | |
| 584 | ATTACK = true | |
| 585 | local originalcframe = RootPart.CFrame | |
| 586 | RootPart.CFrame = CF(VT(Mouse.Hit.p.X,Mouse.Hit.p.Y+(RootPart.Size.Y+1.5),Mouse.Hit.Z),originalcframe.p) | |
| 587 | if OTHERWORLD == false then | |
| 588 | local penta = CreatePentagram(15,false,0,100,CF(RootPart.Position),-3.2) | |
| 589 | CreateSound("971126018", penta, 2, 1)
| |
| 590 | end | |
| 591 | ATTACK = false | |
| 592 | end | |
| 593 | ||
| 594 | function burnchildren(v) | |
| 595 | local get = v:GetChildren() | |
| 596 | for i = 1, #get do | |
| 597 | local child = get[i] | |
| 598 | if child.ClassName == "Part" or child.ClassName == "MeshPart" then | |
| 599 | particles(child) | |
| 600 | child.Color = C3(0,0,0) | |
| 601 | elseif child.ClassName == "CharacterMesh" then | |
| 602 | child.OverlayTextureId = "99174105" | |
| 603 | elseif child.ClassName == "Hat" or child.ClassName == "Accessory" then | |
| 604 | child.Handle.Color = C3(0,0,0) | |
| 605 | child.Handle.Mesh.TextureId = "" | |
| 606 | particles(child.Handle) | |
| 607 | end | |
| 608 | end | |
| 609 | end | |
| 610 | ||
| 611 | function dragnearest(position,range) | |
| 612 | for i,v in ipairs(workspace:GetChildren()) do | |
| 613 | if game.Players:FindFirstChild(v.Name) == nil then | |
| 614 | local body = v:GetChildren() | |
| 615 | for part = 1, #body do | |
| 616 | if((body[part].ClassName == "Part" or body[part].ClassName == "MeshPart") and v ~= Character) then | |
| 617 | if(body[part].Position - position).Magnitude < range then | |
| 618 | v.Parent = Cam | |
| 619 | burnchildren(v) | |
| 620 | if v:FindFirstChild("Humanoid") then
| |
| 621 | v.Humanoid:remove() | |
| 622 | end | |
| 623 | end | |
| 624 | end | |
| 625 | end | |
| 626 | if v.ClassName == "Part" then | |
| 627 | if v.Anchored == false and (v.Position - position).Magnitude < range then | |
| 628 | v.Parent = Cam | |
| 629 | particles(v) | |
| 630 | v.Color = C3(0,0,0) | |
| 631 | end | |
| 632 | end | |
| 633 | end | |
| 634 | end | |
| 635 | end | |
| 636 | ||
| 637 | function Drag() | |
| 638 | local penta = CreatePentagram(25,true,0.3,100,CF(Mouse.Hit.p),0) | |
| 639 | CreateSound("971126018", penta, 2, 1, false)
| |
| 640 | dragnearest(penta.Position,15) | |
| 641 | end | |
| 642 | ||
| 643 | --//=================================\\ | |
| 644 | --|| ASSIGN THINGS TO KEYS | |
| 645 | --\\=================================// | |
| 646 | ||
| 647 | local light2 = nil | |
| 648 | ||
| 649 | function MouseDown(Mouse) | |
| 650 | HOLD = true | |
| 651 | if OTHERWORLD then | |
| 652 | repeat | |
| 653 | Swait() | |
| 654 | CreatePentagram(15,false,0,12,CF(RootPart.Position),-2.8,true) | |
| 655 | until HOLD == false | |
| 656 | end | |
| 657 | end | |
| 658 | ||
| 659 | function MouseUp(Mouse) | |
| 660 | HOLD = false | |
| 661 | end | |
| 662 | ||
| 663 | function KeyDown(Key) | |
| 664 | if Key == "e" then | |
| 665 | Warp() | |
| 666 | end | |
| 667 | if Key == "h" then | |
| 668 | camchild = Cam:GetChildren() | |
| 669 | for child = 1, #camchild do | |
| 670 | if camchild[child] ~= Character and camchild[child].Name ~= "ColorCorrection" then | |
| 671 | camchild[child].Parent = workspace | |
| 672 | end | |
| 673 | end | |
| 674 | end | |
| 675 | if Key == "q" then | |
| 676 | Drag() | |
| 677 | end | |
| 678 | if Key == "r" and ATTACK == false then | |
| 679 | if OTHERWORLD == false then | |
| 680 | OTHERWORLD = true | |
| 681 | light2 = IT("ColorCorrectionEffect",Cam)
| |
| 682 | light2.Brightness = -0.300 | |
| 683 | light2.Contrast = 1 | |
| 684 | light2.Saturation = -2 | |
| 685 | local penta = CreatePentagram(25,false,0,50,CF(RootPart.Position),-2.8) | |
| 686 | CreateSound("971126018", penta, 2, 1.5)
| |
| 687 | Character.Parent = Cam | |
| 688 | elseif OTHERWORLD == true then | |
| 689 | OTHERWORLD = false | |
| 690 | local penta = CreatePentagram(25,false,0,50,CF(RootPart.Position),-2.8) | |
| 691 | CreateSound("971126018", penta, 2, 1.5)
| |
| 692 | light2:remove() | |
| 693 | Character.Parent = workspace | |
| 694 | end | |
| 695 | end | |
| 696 | if Key == "g" and OTHERWORLD == true and ATTACK == false then | |
| 697 | ATTACK = true | |
| 698 | local del = 35 | |
| 699 | for i =1, 35 do | |
| 700 | Swait(del) | |
| 701 | del = del - 1 | |
| 702 | local head = IT("Part",workspace)
| |
| 703 | head.Size = VT(0.2,0.2,0.2) | |
| 704 | head.CFrame = Head.CFrame * CF(math.random(-700,700),0,math.random(-700,700)) | |
| 705 | head.Transparency = 1 | |
| 706 | head.CanCollide = false | |
| 707 | head.Anchored = true | |
| 708 | CreateSound("305685800", head, 10, 2)
| |
| 709 | coroutine.resume(coroutine.create(function() | |
| 710 | for i = 1, 100 do | |
| 711 | Swait() | |
| 712 | end | |
| 713 | if head then | |
| 714 | head:remove() | |
| 715 | end | |
| 716 | end)) | |
| 717 | end | |
| 718 | Swait(100) | |
| 719 | CreateSound("305685800", workspace, 10, 0.8)
| |
| 720 | Swait(250) | |
| 721 | ATTACK = false | |
| 722 | end | |
| 723 | if Key == "t" and ATTACK == false then | |
| 724 | if OTHERWORLD == false then | |
| 725 | CreateSound("305685800", Head, 5, 2)
| |
| 726 | elseif OTHERWORLD == true then | |
| 727 | local head = IT("Part",workspace)
| |
| 728 | head.Size = VT(0.2,0.2,0.2) | |
| 729 | head.CFrame = Head.CFrame | |
| 730 | head.Transparency = 1 | |
| 731 | head.CanCollide = false | |
| 732 | head.Anchored = true | |
| 733 | CreateSound("305685800", head, 5, 2)
| |
| 734 | coroutine.resume(coroutine.create(function() | |
| 735 | for i = 1, 100 do | |
| 736 | Swait() | |
| 737 | if head then | |
| 738 | head.CFrame = Head.CFrame | |
| 739 | end | |
| 740 | end | |
| 741 | if head then | |
| 742 | head:remove() | |
| 743 | end | |
| 744 | end)) | |
| 745 | end | |
| 746 | end | |
| 747 | end | |
| 748 | ||
| 749 | function KeyUp(Key) | |
| 750 | end | |
| 751 | ||
| 752 | Mouse.Button1Down:connect(function(NEWKEY) | |
| 753 | MouseDown(NEWKEY) | |
| 754 | end) | |
| 755 | Mouse.Button1Up:connect(function(NEWKEY) | |
| 756 | MouseUp(NEWKEY) | |
| 757 | end) | |
| 758 | Mouse.KeyDown:connect(function(NEWKEY) | |
| 759 | KeyDown(NEWKEY) | |
| 760 | end) | |
| 761 | Mouse.KeyUp:connect(function(NEWKEY) | |
| 762 | KeyUp(NEWKEY) | |
| 763 | end) | |
| 764 | ||
| 765 | --//=================================\\ | |
| 766 | --\\=================================// | |
| 767 | ||
| 768 | ||
| 769 | function unanchor() | |
| 770 | if UNANCHOR == true then | |
| 771 | g = Character:GetChildren() | |
| 772 | for i = 1, #g do | |
| 773 | if g[i].ClassName == "Part" then | |
| 774 | g[i].Anchored = false | |
| 775 | end | |
| 776 | end | |
| 777 | end | |
| 778 | end | |
| 779 | ||
| 780 | ||
| 781 | --//=================================\\ | |
| 782 | --|| WRAP THE WHOLE SCRIPT UP | |
| 783 | --\\=================================// | |
| 784 | ||
| 785 | while true do | |
| 786 | Swait() | |
| 787 | ||
| 788 | if #Effects2>0 then | |
| 789 | for e=1,#Effects2 do | |
| 790 | if Effects2[e]~=nil then | |
| 791 | local Thing=Effects2[e] | |
| 792 | if Thing~=nil then | |
| 793 | local Part=Thing[1] | |
| 794 | local Mode=Thing[2] | |
| 795 | local Delay=Thing[3] | |
| 796 | local IncX=Thing[4] | |
| 797 | local IncY=Thing[5] | |
| 798 | local IncZ=Thing[6] | |
| 799 | local Part2=Thing[8] | |
| 800 | if Thing[1].Transparency<=1 then | |
| 801 | if Thing[2]=="Block1" then | |
| 802 | Thing[1].CFrame=Thing[1].CFrame | |
| 803 | Mesh=Thing[1].Mesh | |
| 804 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
| 805 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 806 | elseif Thing[2]=="Cylinder" then | |
| 807 | Mesh=Thing[1].Mesh | |
| 808 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
| 809 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 810 | elseif Thing[2]=="Blood" then | |
| 811 | Mesh=Thing[7] | |
| 812 | Thing[1].CFrame=Thing[1].CFrame*CF(0,.5,0) | |
| 813 | Mesh.Scale=Mesh.Scale+VT(Thing[4],Thing[5],Thing[6]) | |
| 814 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 815 | elseif Thing[2]=="Elec" then | |
| 816 | Mesh=Thing[1].Mesh | |
| 817 | Mesh.Scale=Mesh.Scale+VT(Thing[7],Thing[8],Thing[9]) | |
| 818 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 819 | elseif Thing[2]=="Disappear" then | |
| 820 | Thing[1].Transparency=Thing[1].Transparency+Thing[3] | |
| 821 | end | |
| 822 | else | |
| 823 | Part.Parent=nil | |
| 824 | table.remove(Effects2,e) | |
| 825 | end | |
| 826 | end | |
| 827 | end | |
| 828 | end | |
| 829 | end | |
| 830 | unanchor() | |
| 831 | Humanoid.MaxHealth = "inf" | |
| 832 | Humanoid.Health = "inf" | |
| 833 | q = Character:GetChildren() | |
| 834 | for u = 1, #q do | |
| 835 | if q[u].ClassName == "Accessory" or q[u].ClassName == "Hat" then | |
| 836 | q[u]:remove() | |
| 837 | elseif q[u].ClassName == "Shirt" then | |
| 838 | q[u]:Destroy() | |
| 839 | elseif q[u].ClassName == "Pants" then | |
| 840 | q[u]:Destroy() | |
| 841 | elseif q[u].ClassName == "CharacterMesh" then | |
| 842 | q[u]:remove() | |
| 843 | elseif q[u].ClassName == "ShirtGraphic" then | |
| 844 | q[u]:remove() | |
| 845 | elseif q[u].ClassName == "Part" and q[u].Name ~= "HumanoidRootPart" then | |
| 846 | q[u].Color = Color3.new(200/255, 200/255, 200/255) | |
| 847 | if OTHERWORLD == false then | |
| 848 | q[u].Transparency = 0 | |
| 849 | Humanoid.WalkSpeed = 16 | |
| 850 | sick.Parent = Character | |
| 851 | sick.Pitch = 0.8 | |
| 852 | elseif OTHERWORLD == true then | |
| 853 | Humanoid.WalkSpeed = 75 | |
| 854 | sick.Parent = workspace | |
| 855 | sick.Pitch = 0.3 | |
| 856 | end | |
| 857 | end | |
| 858 | end | |
| 859 | if Head:FindFirstChild("Mesh") then
| |
| 860 | local mesh = Head.Mesh | |
| 861 | if mesh.ClassName == "SpecialMesh" then | |
| 862 | mesh:remove() | |
| 863 | local m = IT("BlockMesh",Head)
| |
| 864 | - | tecks2.Text = "CRY" |
| 864 | + | |
| 865 | end | |
| 866 | if Head:FindFirstChild("face") then
| |
| 867 | if math.random(1,50) == 1 then | |
| 868 | Head.face.Texture = "rbxassetid://291716137" | |
| 869 | tecks2.Text = ":>" | |
| 870 | else | |
| 871 | Head.face.Texture = "rbxassetid://2120932" | |
| 872 | tecks2.Text = "SMILE" | |
| 873 | end | |
| 874 | end | |
| 875 | if sick == nil then | |
| 876 | local sick = Instance.new("Sound",Character)
| |
| 877 | sick.SoundId = "rbxassetid://142748120" | |
| 878 | sick.Looped = true | |
| 879 | sick.Pitch = 0.9 | |
| 880 | sick.Volume = 5 | |
| 881 | sick:Play() | |
| 882 | end | |
| 883 | if OTHERWORLD == false then | |
| 884 | CreatePentagram(7,false,0,15,CF(RootPart.Position),-2.8,true) | |
| 885 | end | |
| 886 | end | |
| 887 | ||
| 888 | --//=================================\\ | |
| 889 | --\\=================================// | |
| 890 | ||
| 891 | ||
| 892 | ||
| 893 | ||
| 894 | ||
| 895 | --//====================================================\\-- | |
| 896 | --|| END OF SCRIPT | |
| 897 | --\\====================================================//-- |