--[[ patchma hub made by MyWorld - continued by Emper due to MyWorld quitting optimize the optimized IDs of paid accessories: -for arms 18641142410,18641077392,11159410305,11263254795 or 14255556501,14255554762 or 12344545199,12344591101 or 13839976999,13831200263 -for legs 18641187217,18641157833,14768693948,14768701869 or 11159483910,12652786974 or 17401151565,17387616772 -for torso 18641046146, 14255528083 or 13421786478 or 14768678294 or anything else that covers ur torso. examples: 14532301415,13423624885,11502853991,14053485259,13779879140,14443132226,17163407577,16297156693,17180496303,17171230401 can be same stuff but different colors there are 156 ways to make a rig with the ids above IDs of free accessories: 3033910400,3409612660,3438342658,3398308134,4324158403,3822880197,4154538250,3443038622,4819740796 accessories for Immortality Lord: head: 17375337078 or 17270164442 body: 17270178857,17270001635,17269952801,17269983359,17269998373 wings: 17270231731,17270225913 sword: 17326812233,17326800544 ]] --no need to get and index the library tables with function names every time the script uses them local osclock=os.clock local tspawn=task.spawn local twait=task.wait local schar=string.char local ssub=string.sub local sfind=string.find local supper=string.upper local mrandom=math.random local sin=math.sin local cos=math.cos local abs=math.abs local rad=math.rad local min=math.min local clamp=math.clamp local tinsert=table.insert local tclear=table.clear local tclone=table.clone local tfind=table.find local tunpack=table.unpack --the script doesnt have to read global varaibles every time to get them --why not have them saved in local varaibles for faster access times local next=next local pcall=pcall local xpcall=xpcall local type=type local typeof=typeof local game=game local i=Instance.new local v2=Vector2.new local v3=Vector3.new local c3=Color3.new local cf=CFrame.new local cfl=CFrame.lookAt local angles=CFrame.Angles local u2=UDim2.new local e=Enum local rp=RaycastParams.new local cs=ColorSequence.new local csk=ColorSequenceKeypoint.new local sine=osclock() local deltaTime=0 local v3_0=v3(0,0,0) local v3_101=v3(1,0,1) local v3_010=v3(0,1,0) local v3_001=v3(0,0,1) local cf_0=cf(0,0,0) local v3_xz=v3_101*10 local v3_xzL=v3_101*250.1 local v3_net=v3_010*25.01 --not "local function rs" to not assign debug names local rs=function(l) l=l or mrandom(8,15) local s="" for i=1,l do if mrandom(1,2)==1 then s=s..schar(mrandom(65,90)) else s=s..schar(mrandom(97,122)) end end return s end --it runs even faster if u call __index and __newindex of metatables of userdata directly local getMetamethodFromErrorStack=function(userdata,f,test) local ret=nil xpcall(f,function() ret=debug.info(2,"f") end,userdata,nil,0) if (type(ret)~="function") or not test(ret) then return f end return ret end local insSet=getMetamethodFromErrorStack(game,function(a,b,c) a[b]=c end,function(f) local a=i("Folder") local b=rs() f(a,"Name",b) return a.Name==b end) local insGet=getMetamethodFromErrorStack(game,function(a,b) return a[b] end,function(f) local a=i("Folder") local b=rs() a.Name=b return f(a,"Name")==b end) local cfGet=getMetamethodFromErrorStack(cf_0,function(a,b) return a[b] end,function(f) return f(cf(1,2,3),"Position")==v3(1,2,3) end) local cfMul=getMetamethodFromErrorStack(cf_0,function(a,b) return a*b end,function(f) return angles(1,2,3)*angles(1,2,3)==f(angles(1,2,3),angles(1,2,3)) end) local cfAdd=getMetamethodFromErrorStack(cf_0,function(a,b) return a+b end,function(f) return cf(1,2,3)+v3(1,2,3)==f(cf(1,2,3),v3(1,2,3)) end) local v3Get=getMetamethodFromErrorStack(v3_0,function(a,b) return a[b] end,function(f) return v3(1,2,3).Unit==f(v3(1,2,3),"Unit") end) --multiplying and adding vector3 is faster if you use the * and + operators --no need to index instances every time to call their functions local Clone=insGet(game,"Clone") local ClearAllChildren=insGet(game,"ClearAllChildren") local Destroy=insGet(game,"Destroy") local IsA=insGet(game,"IsA") local FindFirstChildOfClass=insGet(game,"FindFirstChildOfClass") local FindFirstChildWhichIsA=insGet(game,"FindFirstChildWhichIsA") local GetChildren=insGet(game,"GetChildren") local GetDescendants=insGet(game,"GetDescendants") local IsDescendantOf=insGet(game,"IsDescendantOf") local GetPropertyChangedSignal=insGet(game,"GetPropertyChangedSignal") --findfirstchildofclass faster than getservice local plrs=FindFirstChildOfClass(game,"Players") local rus=FindFirstChildOfClass(game,"RunService") local ws=FindFirstChildOfClass(game,"Workspace") local uis=FindFirstChildOfClass(game,"UserInputService") local gs=FindFirstChildOfClass(game,"GuiService") local sg=FindFirstChildOfClass(game,"StarterGui") local lp=insGet(plrs,"LocalPlayer") local pg=FindFirstChildOfClass(lp,"PlayerGui") local mouse=insGet(lp,"GetMouse")(lp) local stepped=insGet(rus,"Stepped") local heartbeat=insGet(rus,"Heartbeat") local renderstepped=insGet(rus,"RenderStepped") local GetPlayers=insGet(plrs,"GetPlayers") local SetCoreGuiEnabled=insGet(sg,"SetCoreGuiEnabled") local GetCoreGuiEnabled=insGet(sg,"GetCoreGuiEnabled") local Raycast=insGet(ws,"Raycast") local Connect=heartbeat.Connect local Disconnect=Connect(GetPropertyChangedSignal(game,"CreatorId"),type).Disconnect local Wait=heartbeat.Wait local GetMouseLocation=insGet(uis,"GetMouseLocation") local GetFocusedTextBox=insGet(uis,"GetFocusedTextBox") local GetMouseDelta=insGet(uis,"GetMouseDelta") local IsMouseButtonPressed=insGet(uis,"IsMouseButtonPressed") local IsKeyDown=insGet(uis,"IsKeyDown") local Inverse=cfGet(cf_0,"Inverse") local Lerp=cfGet(cf_0,"Lerp") local guiTheme={ guiTitle="patchma hub (E.U.)", windowTitleColor=c3(0,0,1), windowTopColor=c3(0,0,0), windowBottomColor=c3(0,0,0.584314), windowMinimizedSize={X=220,Y=22}, windowRegularSize={X=220,Y=290}, buttonsTextColor=c3(0.0941177,0.317647,0.878431), labelsTextColor=c3(0.560784,0.560784,0.560784), listTopColor=c3(0,0,0), listBottomColor=c3(0.0705882,0.0705882,0.0705882) } local accessorylimbs={ {meshid="11263221350",textureid="11263219250",C0=angles(1.5707963267948966,0,1.5707963267948966),Name="Left Arm"}, {meshid="11159370334",textureid="11159284657",C0=angles(-1.5707963267948966,0,1.5707963267948966),Name="Right Arm"}, {meshid="14255522247",textureid="",C0=angles(1.5707963267948966,0,1.5707963267948966),Name="Left Arm"}, {meshid="14255522247",textureid="",C0=angles(-1.5707963267948966,0,1.5707963267948966),Name="Right Arm"}, {meshid="17374767929",textureid="",C0=angles(1.5707963267948966,0,1.5707963267948966),Name="Left Arm"}, {meshid="17374767929",textureid="",C0=angles(-1.5707963267948966,0,1.5707963267948966),Name="Right Arm"}, {meshid="12344207333",textureid="",C0=angles(2,0,0),Name="Left Arm"}, {meshid="12344206657",textureid="",C0=angles(2,0,0),Name="Right Arm"}, {meshid="13831073174",textureid="",C0=cfMul(cf(0.017,0,-0.23),angles(-1.4835298641951802,-0.15707963267948966,2.199114857512855)),Name="Left Arm"}, {meshid="13839903766",textureid="",C0=cfMul(cf(0,-0.62,-0.01),angles(1.6580627893946132,0.15707963267948966,-2.199114857512855)),Name="Right Arm"}, {meshid="11159370334",textureid="11159285454",C0=angles(1.5707963267948966,0,1.5707963267948966),Name="Left Leg"}, {meshid="12652772399",textureid="12652775021",C0=cf(0,-0.125,0),Name="Right Leg"}, {meshid="14768684979",textureid="",C0=angles(0,0,1.5707963267948966),Name="Left Leg"}, {meshid="14768684979",textureid="",C0=angles(0,0,1.5707963267948966),Name="Right Leg"}, {meshid="17387586286",textureid="",C0=angles(1.5707963267948966,0,1.5707963267948966),Name="Left Leg"}, {meshid="17387586286",textureid="",C0=angles(-1.5707963267948966,0,1.5707963267948966),Name="Right Leg"}, {meshid="14768666349",textureid="",C0=cf_0,Name="Torso"}, {meshid="14241018198",textureid="",C0=cf_0,Name="Torso"}, {meshid="13421774668",textureid="",C0=cf_0,Name="Torso"}, {meshid="4324138105",textureid="4324138210",C0=cfMul(angles(-1.6144295580947547,1.5707963267948966,0),cf(-0.125,0.3,0)),Name="Left Arm"}, {meshid="4154474745",textureid="4154474807",C0=cfMul(angles(1.5271630954950384,-1.5707963267948966,0),cf(-0.125,-0.3,0)),Name="Left Arm"}, {meshid="3030546036",textureid="3650191503",C0=cfMul(angles(1.5271630954950384,1.5707963267948966,0),cf(0.125,-0.3,0)),Name="Right Arm"}, {meshid="3030546036",textureid="3443321249",C0=cfMul(angles(-1.6144295580947547,-1.5707963267948966,0),cf(0.125,0.3,0)),Name="Right Arm"}, {meshid="3030546036",textureid="3360974849",C0=cfMul(angles(1.5271630954950384,1.5707963267948966,0),cf(-0.125,-0.35,0)),Name="Left Leg"}, {meshid="3030546036",textureid="3360978739",C0=cfMul(angles(-1.6144295580947547,-1.5707963267948966,0),cf(-0.125,0.3,0)),Name="Left Leg"}, {meshid="3030546036",textureid="3033898741",C0=cfMul(angles(1.5271630954950384,-1.5707963267948966,0),cf(0.125,-0.35,0)),Name="Right Leg"}, {meshid="3030546036",textureid="3409604993",C0=cfMul(angles(-1.6144295580947547,1.5707963267948966,0),cf(0.125,0.3,0)),Name="Right Leg"}, {meshid="4819720316",textureid="4819722776",C0=angles(0,0,0.2617993877991494),Name="Torso"}, -- the noob rig: {meshid="18640899369",textureid="18640899481",C0=cf_0,Name="Torso"}, {meshid="18640914129",textureid="18640914168",C0=cf_0,Name="Left Arm"}, {meshid="18640901641",textureid="18640901676",C0=cf_0,Name="Right Leg"}, {meshid="18640914129",textureid="18640914168",C0=cf_0,Name="Right Arm"}, {meshid="18640901641",textureid="18640901676",C0=cf_0,Name="Left Leg"}, } local gp=function(p,n,cl) for i,v in next,GetChildren(p) do if IsA(v,cl) and (insGet(v,"Name")==n) then return v end end return nil end local timegp=function(p,n,c,t) t=osclock()+t while t>osclock() do for i,v in next,GetChildren(p) do if IsA(v,c) and (insGet(v,"Name")==n) then return v end end Wait(stepped) end return nil end local makeplaceholder=function(v) if typeof(v)~="Instance" then return nil end if not insGet(v,"Archivable") then insSet(v,"Archivable",true) end v=Clone(v) for i,v in next,GetChildren(v) do if IsA(v,"SpecialMesh") then insSet(v,"Name",rs()) ClearAllChildren(v) else Destroy(v) end end insSet(v,"Name",rs()) insSet(v,"Anchored",true) insSet(v,"CanCollide",false) insSet(v,"Transparency",0.25) insSet(v,"Parent",ws) return v end local emptyfunction=function() end local i1=i("Frame") local i2=i("Frame") local i3=i("Frame") local i4=i("ScrollingFrame") local i5=i("UIListLayout") local i6=i("UIGradient") local i7=i("TextBox") local i8=i("TextButton") local i9=i("UIGradient") local i10=i("ScreenGui") insSet(i1,"AnchorPoint",v2(0.5,0)) insSet(i1,"Active",true) insSet(i1,"BorderSizePixel",0) insSet(i1,"ClipsDescendants",true) insSet(i1,"Position",u2(0.5,0,0.5,guiTheme.windowRegularSize.Y/-2)) insSet(i1,"Size",u2(0,guiTheme.windowRegularSize.X,0,guiTheme.windowRegularSize.Y)) insSet(i1,"Name",rs()) insSet(i1,"Parent",i10) insSet(i2,"BackgroundColor3",c3(1,1,1)) insSet(i2,"BorderSizePixel",0) insSet(i2,"Size",u2(0,guiTheme.windowRegularSize.X,0,guiTheme.windowRegularSize.Y)) insSet(i2,"Name",rs()) insSet(i2,"Parent",i1) insSet(i3,"BackgroundColor3",c3(1,1,1)) insSet(i3,"BorderSizePixel",0) insSet(i3,"Position",u2(0,5,0,guiTheme.windowMinimizedSize.Y-2)) insSet(i3,"Size",u2(1,-10,0,guiTheme.windowRegularSize.Y-guiTheme.windowMinimizedSize.Y-3)) insSet(i3,"Name",rs()) insSet(i3,"Parent",i2) insSet(i4,"Active",true) insSet(i4,"BackgroundTransparency",1) insSet(i4,"BorderSizePixel",0) insSet(i4,"Size",u2(1,-3,1,0)) insSet(i4,"AutomaticCanvasSize",e.AutomaticSize.Y) insSet(i4,"CanvasSize",u2(0,0,0,0)) insSet(i4,"ScrollBarThickness",7) insSet(i4,"Name",rs()) insSet(i4,"Parent",i3) insSet(i5,"Name",rs()) insSet(i5,"Parent",i4) insSet(i5,"SortOrder",e.SortOrder.LayoutOrder) insSet(i6,"Name",rs()) insSet(i6,"Parent",i3) insSet(i6,"Color",cs({csk(0,guiTheme.listTopColor),csk(1,guiTheme.listBottomColor)})) insSet(i6,"Rotation",90) insSet(i7,"Font",e.Font.SourceSans) insSet(i7,"FontSize",e.FontSize.Size18) insSet(i7,"ClearTextOnFocus",false) insSet(i7,"Text",guiTheme.guiTitle) insSet(i7,"TextColor3",guiTheme.windowTitleColor) insSet(i7,"TextSize",16) insSet(i7,"AnchorPoint",v2(0.5,0)) insSet(i7,"BackgroundTransparency",1) insSet(i7,"Position",u2(0.5,0,0,guiTheme.windowMinimizedSize.Y/2)) insSet(i7,"Name",rs()) insSet(i7,"Parent",i2) insSet(i8,"AnchorPoint",v2(1,0)) insSet(i8,"BackgroundTransparency",1) insSet(i8,"Position",u2(1,0,0,0)) insSet(i8,"Size",u2(0,40,0,guiTheme.windowMinimizedSize.Y)) insSet(i8,"Name",rs()) insSet(i8,"Parent",i2) insSet(i8,"Font",e.Font.SourceSans) insSet(i8,"FontSize",e.FontSize.Size18) insSet(i8,"Text","-") insSet(i8,"TextColor3",c3(1,1,1)) insSet(i8,"TextSize",16) insSet(i9,"Name",rs()) insSet(i9,"Parent",i2) insSet(i9,"Color",cs({csk(0,guiTheme.windowTopColor),csk(1,guiTheme.windowBottomColor)})) insSet(i9,"Rotation",90) insSet(i10,"ZIndexBehavior",e.ZIndexBehavior.Sibling) insSet(i10,"IgnoreGuiInset",true) insSet(i10,"ResetOnSpawn",false) insSet(i10,"DisplayOrder",2147483647) insSet(i10,"Name",rs()) local guimin=false local minloop=false local i1X=guiTheme.windowRegularSize.X local i1Y=guiTheme.windowRegularSize.Y local i1Xdest=i1X local i1Ydest=i1Y Connect(insGet(i8,"MouseButton1Click"),function() guimin = not guimin if guimin then i1Xdest=guiTheme.windowMinimizedSize.X i1Ydest=guiTheme.windowMinimizedSize.Y else i1Xdest=guiTheme.windowRegularSize.X i1Ydest=guiTheme.windowRegularSize.Y end if minloop then return end minloop=true insSet(i3,"Visible",true) sine=osclock() local lastsine=sine while true do sine=osclock() local deltaTime=(sine-lastsine)*10 lastsine=sine local difX=i1Xdest-i1X local difY=i1Ydest-i1Y if (abs(difY)<=1) and (abs(difX)<=1) then i1X=i1Xdest i1Y=i1Ydest insSet(i1,"Size",u2(0,i1X,0,i1Y)) break end i1X=i1X+difX*deltaTime i1Y=i1Y+difY*deltaTime insSet(i1,"Size",u2(0,i1X,0,i1Y)) twait() end insSet(i3,"Visible",not guimin) minloop=false end) local Draggable=function(window,obj) local MB1enum = e.UserInputType.MouseButton1 local TOUCHenum = e.UserInputType.Touch obj = obj or window local activeEntered = 0 local mouseStart = nil local dragStart = nil local inputbegancon = nil local rendersteppedcon = nil local inputendedcon = nil local inputendedf=function(a) a=insGet(a,"UserInputType") if (a==MB1enum) or (a==TOUCHenum) then Disconnect(rendersteppedcon) Disconnect(inputendedcon) end end local rendersteppedf=function() local off = GetMouseLocation(uis)-mouseStart insSet(window,"Position",dragStart+u2(0,off.X,0,off.Y)) end local inputbeganf=function(a) a=insGet(a,"UserInputType") if ((a==MB1enum) or (a==TOUCHenum)) and (activeEntered==0) and not GetFocusedTextBox(uis) then mouseStart=GetMouseLocation(uis) dragStart=insGet(window,"Position") if rendersteppedcon then Disconnect(rendersteppedcon) end rendersteppedcon = Connect(renderstepped,rendersteppedf) if inputendedcon then Disconnect(inputendedcon) end inputendedcon = Connect(insGet(uis,"InputEnded"),inputendedf) end end Connect(insGet(obj,"MouseEnter"),function() if inputbegancon then Disconnect(inputbegancon) end inputbegancon = Connect(insGet(uis,"InputBegan"),inputbeganf) end) Connect(insGet(obj,"MouseLeave"),function() Disconnect(inputbegancon) end) local ondes=function(d) if IsA(d,"GuiObject") then local thisEntered = false local thisAdded = false local con0 = Connect(insGet(d,"MouseEnter"),function() thisEntered = true if (not thisAdded) and insGet(d,"Active") then activeEntered = activeEntered + 1 thisAdded = true end end) local con1 = Connect(insGet(d,"MouseLeave"),function() thisEntered = false if thisAdded then activeEntered = activeEntered - 1 thisAdded = false end end) local con2 = Connect(GetPropertyChangedSignal(d,"Active"),function() if thisEntered then if thisAdded and not insGet(d,"Active") then activeEntered = activeEntered - 1 thisAdded = false elseif insGet(d,"Active") and not thisAdded then activeEntered = activeEntered + 1 thisAdded = true end end end) local con3 = nil con3 = Connect(insGet(d,"AncestryChanged"),function() if not IsDescendantOf(d,window) then if thisEntered then activeEntered = activeEntered - 1 end Disconnect(con0) Disconnect(con1) Disconnect(con2) Disconnect(con3) end end) end end Connect(insGet(window,"DescendantAdded"),ondes) for i,v in next,GetDescendants(window) do ondes(v) end end local btn=function(txt, f) local i1=i("TextBox") local i2=i("TextButton") insSet(i1,"Font",e.Font.SourceSans) insSet(i1,"FontSize",e.FontSize.Size14) insSet(i1,"Text",txt) insSet(i1,"ClearTextOnFocus",false) insSet(i1,"Position",u2(0.5,0,0.5,0)) insSet(i1,"TextColor3",guiTheme.buttonsTextColor) insSet(i1,"Name",rs()) insSet(i1,"Parent",i2) insSet(i2,"BackgroundTransparency",1) insSet(i2,"TextTransparency",1) insSet(i2,"Size",u2(1,0,0,14)) insSet(i2,"Name",rs()) if f then Connect(insGet(i2,"MouseButton1Click"),f) end insSet(i2,"Parent",i4) return i1 end local lbl=function(txt) local i1=i("TextBox") local i2=i("Frame") insSet(i1,"Font",e.Font.SourceSans) insSet(i1,"FontSize",e.FontSize.Size14) insSet(i1,"Text",txt) insSet(i1,"ClearTextOnFocus",false) insSet(i1,"TextColor3",guiTheme.labelsTextColor) insSet(i1,"Position",u2(0.5,0,0.5)) insSet(i1,"BackgroundTransparency",1) insSet(i1,"Name",rs()) insSet(i1,"Parent",i2) insSet(i2,"Size",u2(1,0,0,14)) insSet(i2,"BackgroundTransparency",1) insSet(i2,"Name",rs()) insSet(i2,"Parent",i4) return i1 end Draggable(i1) lbl("made by MyWorld") lbl("continued by Emper") lbl("discord.gg/QMy5f6DrbH") local allowshiftlock=nil local ctrltp=nil local placeholders=nil local clickfling=nil local highlightflingtargets=nil local discharscripts=nil local flingchangestate=nil local respawntp=nil local breakjointsmethod=nil local simrad=false local hidedeatheffect=nil local c=nil local stopreanimate=function() if c then c=nil return true end return false end local reanimate=function() --[[ FDless reanimate by MyWorld aka no client sided instances "what else do i optimize here" ]] local novoid = true --prevents parts from going under workspace.FallenPartsDestroyHeight if you control them local speedlimit = 3000 --makes your parts move slower if the magnitude of their velocity is higher than this local retVelTime = 0.51 --time that claimed parts have velocity to reclaim in case u lose them local walkSpeed = 16 --your walkspeed (can be changed at runtime) local jumpPower = 50 --your jump power (can be changed at runtime) local gravity = 196.2 --how fast the characters velocity decreases while falling (can be changed at runtime) local ctrlclicktp = ctrltp --makes you teleport where u point ur mouse cursor at when click and hold ctrl down local clickfling = clickfling --makes you fling the person you clicked when its available to do so local flingvel = v3(15000,16000,15000) --the rotation velocity that ur character will have while flinging if stopreanimate() then return end c=insGet(lp,"Character") if not (c and IsDescendantOf(c,ws)) then return nil, "no character found" end local rootpart=gp(c,"HumanoidRootPart","BasePart") or gp(c,"Torso","BasePart") or gp(c,"UpperTorso","BasePart") or timegp(c,"HumanoidRootPart","BasePart",0.5) or FindFirstChildWhichIsA(c,"BasePart") if not rootpart then return nil, "no basepart found" end local cam=nil --theres a way to have ws.currentcamera nil on heartbeat and still have the game run normally local refcam=function() local newcam=insGet(ws,"CurrentCamera") while not newcam do Wait(GetPropertyChangedSignal(ws,"CurrentCamera")) newcam=insGet(ws,"CurrentCamera") end cam=newcam en