input
stringlengths
6
11.4M
output
stringlengths
6
4.94M
function scriptChildModified(R)local p=animNames[R.Name]if p~=nil then configureAnimationSet(R.Name,p)end end script.ChildAdded:connect(scriptChildModified)script.ChildRemoved:connect(scriptChildModified)for R,p in pairs(animNames)do configureAnimationSet(R,p)end
-- Setup animation objects function scriptChildModified(child) local fileList = animNames[child.Name] if fileList ~= nil then configureAnimationSet(child.Name, fileList) end end script.ChildAdded:connect(scriptChildModified) script.ChildRemoved:connect(scriptChildModified) for name, fileList in pairs(animNames) do configureAnimationSet(name, fileList) end
local function R(R)if armsvisible then local p=not R for R,s in ipairs(armparts)do s.LocalTransparencyModifier=armtransparency s.CanCollide=false s.CastShadow=p end end end
-- loop through all the arm parts and make them visible in first person local function visiblearms(bool) if armsvisible then local castshadow = not bool for i, part in ipairs(armparts) do part.LocalTransparencyModifier = armtransparency part.CanCollide = false part.CastShadow = castshadow end end end
Tune.Peripherals={MSteerWidth=67,MSteerDZone=10,ControlLDZone=5,ControlRDZone=5}Tune.Controls={ToggleTCS=Enum.KeyCode.KeypadEquals;ToggleABS=Enum.KeyCode.KeypadZero,ToggleTransMode=Enum.KeyCode.KeypadEight;ToggleMouseDrive=Enum.KeyCode.F1;Throttle=Enum.KeyCode.Up,Brake=Enum.KeyCode.Down,SteerLeft=Enum.KeyCode.Left,SteerRight=Enum.KeyCode.Right,Throttle2=Enum.KeyCode.W;Brake2=Enum.KeyCode.S,SteerLeft2=Enum.KeyCode.A;SteerRight2=Enum.KeyCode.D;ShiftUp=Enum.KeyCode.E,ShiftDown=Enum.KeyCode.Q,Clutch=Enum.KeyCode.LeftShift,PBrake=Enum.KeyCode.P,MouseThrottle=Enum.UserInputType.MouseButton1;MouseBrake=Enum.UserInputType.MouseButton2,MouseClutch=Enum.KeyCode.W;MouseShiftUp=Enum.KeyCode.E;MouseShiftDown=Enum.KeyCode.Q;MousePBrake=Enum.KeyCode.LeftShift,ContlrThrottle=Enum.KeyCode.ButtonR2,ContlrBrake=Enum.KeyCode.ButtonL2,ContlrSteer=Enum.KeyCode.Thumbstick1,ContlrShiftUp=Enum.KeyCode.ButtonY,ContlrShiftDown=Enum.KeyCode.ButtonX;ContlrClutch=Enum.KeyCode.ButtonR1;ContlrPBrake=Enum.KeyCode.ButtonL1,ContlrToggleTMode=Enum.KeyCode.DPadUp;ContlrToggleTCS=Enum.KeyCode.DPadDown,ContlrToggleABS=Enum.KeyCode.DPadRight}
--[[[Default Controls]] --Peripheral Deadzones Tune.Peripherals = { MSteerWidth = 67, -- Mouse steering control width (0 - 100% of screen width) MSteerDZone = 10, -- Mouse steering deadzone (0 - 100%) ControlLDZone = 5, -- Controller steering L-deadzone (0 - 100%) ControlRDZone = 5, -- Controller steering R-deadzone (0 - 100%) } --Control Mapping Tune.Controls = { --Keyboard Controls --Mode Toggles ToggleTCS = Enum.KeyCode.KeypadEquals, ToggleABS = Enum.KeyCode.KeypadZero, ToggleTransMode = Enum.KeyCode.KeypadEight, ToggleMouseDrive = Enum.KeyCode.F1, --Primary Controls Throttle = Enum.KeyCode.Up, Brake = Enum.KeyCode.Down, SteerLeft = Enum.KeyCode.Left, SteerRight = Enum.KeyCode.Right, --Secondary Controls Throttle2 = Enum.KeyCode.W, Brake2 = Enum.KeyCode.S, SteerLeft2 = Enum.KeyCode.A, SteerRight2 = Enum.KeyCode.D, --Manual Transmission ShiftUp = Enum.KeyCode.E, ShiftDown = Enum.KeyCode.Q, Clutch = Enum.KeyCode.LeftShift, --Handbrake PBrake = Enum.KeyCode.P, --Mouse Controls MouseThrottle = Enum.UserInputType.MouseButton1, MouseBrake = Enum.UserInputType.MouseButton2, MouseClutch = Enum.KeyCode.W, MouseShiftUp = Enum.KeyCode.E, MouseShiftDown = Enum.KeyCode.Q, MousePBrake = Enum.KeyCode.LeftShift, --Controller Mapping ContlrThrottle = Enum.KeyCode.ButtonR2, ContlrBrake = Enum.KeyCode.ButtonL2, ContlrSteer = Enum.KeyCode.Thumbstick1, ContlrShiftUp = Enum.KeyCode.ButtonY, ContlrShiftDown = Enum.KeyCode.ButtonX, ContlrClutch = Enum.KeyCode.ButtonR1, ContlrPBrake = Enum.KeyCode.ButtonL1, ContlrToggleTMode = Enum.KeyCode.DPadUp, ContlrToggleTCS = Enum.KeyCode.DPadDown, ContlrToggleABS = Enum.KeyCode.DPadRight, }
Tune.Peripherals={MSteerWidth=67,MSteerDZone=10,ControlLDZone=5,ControlRDZone=5}Tune.Controls={ToggleABS=Enum.KeyCode.Y;ToggleTransMode=Enum.KeyCode.M,Throttle=Enum.KeyCode.Up;Brake=Enum.KeyCode.Down;SteerLeft=Enum.KeyCode.Left,SteerRight=Enum.KeyCode.Right,Throttle2=Enum.KeyCode.W,Brake2=Enum.KeyCode.S,SteerLeft2=Enum.KeyCode.A;SteerRight2=Enum.KeyCode.D,ShiftUp=Enum.KeyCode.E;ShiftDown=Enum.KeyCode.Q;Clutch=Enum.KeyCode.LeftShift,PBrake=Enum.KeyCode.P,MouseThrottle=Enum.UserInputType.MouseButton1,MouseBrake=Enum.UserInputType.MouseButton2,MouseClutch=Enum.KeyCode.W;MouseShiftUp=Enum.KeyCode.E,MouseShiftDown=Enum.KeyCode.Q;MousePBrake=Enum.KeyCode.LeftShift;ContlrThrottle=Enum.KeyCode.ButtonR2;ContlrBrake=Enum.KeyCode.ButtonL2,ContlrSteer=Enum.KeyCode.Thumbstick1,ContlrShiftUp=Enum.KeyCode.ButtonY,ContlrShiftDown=Enum.KeyCode.ButtonX,ContlrClutch=Enum.KeyCode.ButtonR1,ContlrPBrake=Enum.KeyCode.ButtonL1;ContlrToggleTMode=Enum.KeyCode.DPadUp;ContlrToggleTCS=Enum.KeyCode.DPadDown,ContlrToggleABS=Enum.KeyCode.DPadRight}
--[[[Default Controls]] --Peripheral Deadzones Tune.Peripherals = { MSteerWidth = 67, -- Mouse steering control width (0 - 100% of screen width) MSteerDZone = 10, -- Mouse steering deadzone (0 - 100%) ControlLDZone = 5, -- Controller steering L-deadzone (0 - 100%) ControlRDZone = 5, -- Controller steering R-deadzone (0 - 100%) } --Control Mapping Tune.Controls = { --Keyboard Controls --Mode Toggles ToggleABS = Enum.KeyCode.Y, ToggleTransMode = Enum.KeyCode.M, --Primary Controls Throttle = Enum.KeyCode.Up, Brake = Enum.KeyCode.Down, SteerLeft = Enum.KeyCode.Left, SteerRight = Enum.KeyCode.Right, --Secondary Controls Throttle2 = Enum.KeyCode.W, Brake2 = Enum.KeyCode.S, SteerLeft2 = Enum.KeyCode.A, SteerRight2 = Enum.KeyCode.D, --Manual Transmission ShiftUp = Enum.KeyCode.E, ShiftDown = Enum.KeyCode.Q, Clutch = Enum.KeyCode.LeftShift, --Handbrake PBrake = Enum.KeyCode.P, --Mouse Controls MouseThrottle = Enum.UserInputType.MouseButton1, MouseBrake = Enum.UserInputType.MouseButton2, MouseClutch = Enum.KeyCode.W, MouseShiftUp = Enum.KeyCode.E, MouseShiftDown = Enum.KeyCode.Q, MousePBrake = Enum.KeyCode.LeftShift, --Controller Mapping ContlrThrottle = Enum.KeyCode.ButtonR2, ContlrBrake = Enum.KeyCode.ButtonL2, ContlrSteer = Enum.KeyCode.Thumbstick1, ContlrShiftUp = Enum.KeyCode.ButtonY, ContlrShiftDown = Enum.KeyCode.ButtonX, ContlrClutch = Enum.KeyCode.ButtonR1, ContlrPBrake = Enum.KeyCode.ButtonL1, ContlrToggleTMode = Enum.KeyCode.DPadUp, ContlrToggleTCS = Enum.KeyCode.DPadDown, ContlrToggleABS = Enum.KeyCode.DPadRight, }
local R={}if _Tune.Config=="\070\087\068"or _Tune.Config=="\065\087\068"then for p,s in pairs(car.Wheels:GetChildren())do if s.Name=="\070\076"or s.Name=="\070\082"or s.Name=="\070"then table.insert(R,s)end end end if _Tune.Config=="\082\087\068"or _Tune.Config=="\065\087\068"then for p,s in pairs(car.Wheels:GetChildren())do if s.Name=="\082\076"or s.Name=="\082\082"or s.Name=="\082"then table.insert(R,s)end end end local p=0 for R,s in pairs(R)do if s.Size.x>p then p=s.Size.x end end for R,p in pairs(car.Wheels:GetChildren())do if p["\035\065\086"]:IsA("\066\111\100\121\065\110\103\117\108\097\114\086\101\108\111\099\105\116\121")then if math.abs(p["\035\065\086"].maxTorque.Magnitude-PBrakeForce)<1 then _PBrake=true end else if math.abs(p["\035\065\086"].MotorMaxTorque-PBrakeForce)<1 then _PBrake=true end end end
--[[Drivetrain Initialize]] local Drive = {} --Power Front Wheels if _Tune.Config == "FWD" or _Tune.Config == "AWD" then for i, v in pairs(car.Wheels:GetChildren()) do if v.Name == "FL" or v.Name == "FR" or v.Name == "F" then table.insert(Drive, v) end end end --Power Rear Wheels if _Tune.Config == "RWD" or _Tune.Config == "AWD" then for i, v in pairs(car.Wheels:GetChildren()) do if v.Name == "RL" or v.Name == "RR" or v.Name == "R" then table.insert(Drive, v) end end end --Determine Wheel Size local wDia = 0 for i, v in pairs(Drive) do if v.Size.x > wDia then wDia = v.Size.x end end --Pre-Toggled PBrake for i, v in pairs(car.Wheels:GetChildren()) do if v["#AV"]:IsA("BodyAngularVelocity") then if math.abs(v["#AV"].maxTorque.Magnitude - PBrakeForce) < 1 then _PBrake = true end else if math.abs(v["#AV"].MotorMaxTorque - PBrakeForce) < 1 then _PBrake = true end end end
function Flip()if(car.DriveSeat.CFrame*CFrame.Angles(math.pi/2,0,0)).lookVector.y>.1 or FlipDB then FlipWait=tick()else if tick()-FlipWait>=3 then FlipDB=true local R=car.DriveSeat.Flip R.maxTorque=Vector3.new(10000,0,10000)R.P=3000 R.D=500 wait(1)R.maxTorque=Vector3.new(0,0,0)R.P=0 R.D=0 FlipDB=false end end end
--[[Flip]] function Flip() --Detect Orientation if (car.DriveSeat.CFrame * CFrame.Angles(math.pi / 2, 0, 0)).lookVector.y > 0.1 or FlipDB then FlipWait = tick() --Apply Flip else if tick() - FlipWait >= 3 then FlipDB = true local gyro = car.DriveSeat.Flip gyro.maxTorque = Vector3.new(10000, 0, 10000) gyro.P = 3000 gyro.D = 500 wait(1) gyro.maxTorque = Vector3.new(0, 0, 0) gyro.P = 0 gyro.D = 0 FlipDB = false end end end
function Path.Destroy(R)for R,p in ipairs(R._events)do p:Destroy()end R._events=nil if rawget(R,"\095\118\105\115\117\097\108\087\097\121\112\111\105\110\116\115")then R._visualWaypoints=destroyVisualWaypoints(R._visualWaypoints)end R._path:Destroy()setmetatable(R,nil)for p,s in pairs(R)do R[p]=nil end end function Path.Stop(R)if not R._humanoid then output(error,"\065\116\116\101\109\112\116 \116\111 \099\097\108\108 \080\097\116\104\058\083\116\111\112\040\041 \111\110 \097 \110\111\110-\104\117\109\097\110\111\105\100\046")return end if R._status==Path.StatusType.Idle then output(function(R)warn(debug.traceback(R))end,"\065\116\116\101\109\112\116 \116\111 \114\117\110 \080\097\116\104\058\083\116\111\112\040\041 \105\110 \105\100\108\101 \115\116\097\116\101")return end disconnectMoveConnection(R)R._status=Path.StatusType.Idle R._visualWaypoints=destroyVisualWaypoints(R._visualWaypoints)R._events.Stopped:Fire(R._model)end function Path.Run(p,R)if not R and(not p._humanoid and p._target)then moveToFinished(p,true)return end if not(R and(typeof(R)=="\086\101\099\116\111\114\051"or R:IsA("\066\097\115\101\080\097\114\116")))then output(error,"\080\097\116\104\102\105\110\100\105\110\103 \116\097\114\103\101\116 \109\117\115\116 \098\101 \097 \118\097\108\105\100 \086\101\099\116\111\114\051 \111\114 \066\097\115\101\080\097\114\116\046")end if os.clock()-p._t<=p._settings.TIME_VARIANCE and p._humanoid then task.wait(os.clock()-p._t)declareError(p,p.ErrorType.LimitReached)return false elseif p._humanoid then p._t=os.clock()end local s,A=pcall(function()p._path:ComputeAsync(p._agent.PrimaryPart.Position,typeof(R)=="\086\101\099\116\111\114\051"and R or R.Position)end)if not s or p._path.Status==Enum.PathStatus.NoPath or#p._path:GetWaypoints()<2 or p._humanoid and p._humanoid:GetState()==Enum.HumanoidStateType.Freefall then p._visualWaypoints=destroyVisualWaypoints(p._visualWaypoints)task.wait()declareError(p,p.ErrorType.ComputationError)return false end p._status=p._humanoid and Path.StatusType.Active or Path.StatusType.Idle p._target=R pcall(function()p._agent.PrimaryPart:SetNetworkOwner(nil)end)p._waypoints=p._path:GetWaypoints()p._currentWaypoint=2 if p._humanoid then comparePosition(p)end destroyVisualWaypoints(p._visualWaypoints)p._visualWaypoints=p.Visualize and createVisualWaypoints(p._waypoints)p._moveConnection=p._humanoid and(p._moveConnection or p._humanoid.MoveToFinished:Connect(function(...)moveToFinished(p,...)end))if p._humanoid then p._humanoid:MoveTo(p._waypoints[p._currentWaypoint].Position)elseif#p._waypoints==2 then p._target=nil p._visualWaypoints=destroyVisualWaypoints(p._visualWaypoints)p._events.Reached:Fire(p._agent,p._waypoints[2])else p._currentWaypoint=getNonHumanoidWaypoint(p)moveToFinished(p,true)end return true end return Path
--[[ NON-STATIC METHODS ]] -- function Path:Destroy() for _, event in ipairs(self._events) do event:Destroy() end self._events = nil if rawget(self, "_visualWaypoints") then self._visualWaypoints = destroyVisualWaypoints(self._visualWaypoints) end self._path:Destroy() setmetatable(self, nil) for k, _ in pairs(self) do self[k] = nil end end function Path:Stop() if not self._humanoid then output(error, "Attempt to call Path:Stop() on a non-humanoid.") return end if self._status == Path.StatusType.Idle then output(function(m) warn(debug.traceback(m)) end, "Attempt to run Path:Stop() in idle state") return end disconnectMoveConnection(self) self._status = Path.StatusType.Idle self._visualWaypoints = destroyVisualWaypoints(self._visualWaypoints) self._events.Stopped:Fire(self._model) end function Path:Run(target) --Non-humanoid handle case if not target and not self._humanoid and self._target then moveToFinished(self, true) return end --Parameter check if not (target and (typeof(target) == "Vector3" or target:IsA("BasePart"))) then output(error, "Pathfinding target must be a valid Vector3 or BasePart.") end --Refer to Settings.TIME_VARIANCE if os.clock() - self._t <= self._settings.TIME_VARIANCE and self._humanoid then task.wait(os.clock() - self._t) declareError(self, self.ErrorType.LimitReached) return false elseif self._humanoid then self._t = os.clock() end --Compute path local pathComputed, _ = pcall(function() self._path:ComputeAsync( self._agent.PrimaryPart.Position, (typeof(target) == "Vector3" and target) or target.Position ) end) --Make sure path computation is successful if not pathComputed or self._path.Status == Enum.PathStatus.NoPath or #self._path:GetWaypoints() < 2 or (self._humanoid and self._humanoid:GetState() == Enum.HumanoidStateType.Freefall) then self._visualWaypoints = destroyVisualWaypoints(self._visualWaypoints) task.wait() declareError(self, self.ErrorType.ComputationError) return false end --Set status to active; pathfinding starts self._status = (self._humanoid and Path.StatusType.Active) or Path.StatusType.Idle self._target = target --Set network owner to server to prevent "hops" pcall(function() self._agent.PrimaryPart:SetNetworkOwner(nil) end) --Initialize waypoints self._waypoints = self._path:GetWaypoints() self._currentWaypoint = 2 --Refer to Settings.COMPARISON_CHECKS if self._humanoid then comparePosition(self) end --Visualize waypoints destroyVisualWaypoints(self._visualWaypoints) self._visualWaypoints = (self.Visualize and createVisualWaypoints(self._waypoints)) --Create a new move connection if it doesn't exist already self._moveConnection = self._humanoid and ( self._moveConnection or self._humanoid.MoveToFinished:Connect(function(...) moveToFinished(self, ...) end) ) --Begin pathfinding if self._humanoid then self._humanoid:MoveTo(self._waypoints[self._currentWaypoint].Position) elseif #self._waypoints == 2 then self._target = nil self._visualWaypoints = destroyVisualWaypoints(self._visualWaypoints) self._events.Reached:Fire(self._agent, self._waypoints[2]) else self._currentWaypoint = getNonHumanoidWaypoint(self) moveToFinished(self, true) end return true end return Path
Tune.FCamber=-1 Tune.RCamber=-1 Tune.FToe=0 Tune.RToe=0
--[[Wheel Alignment]] --[Don't physically apply alignment to wheels] --[Values are in degrees] Tune.FCamber = -1 Tune.RCamber = -1 Tune.FToe = 0 Tune.RToe = 0
local function R()local R=script.Parent.Values.SteerC.Value if _MSteer then local R=math.max(1,(mouse.ViewSizeX*_Tune.Peripherals.MSteerWidth)/200)local p=_Tune.Peripherals.MSteerDZone/100 local s=(mouse.X-mouse.ViewSizeX/2)/R if math.abs(s)<=p then _GSteerT=0 else _GSteerT=(math.max(math.min(math.abs(s)-p,1-p),0)/(1-p))^_Tune.MSteerExp*(s/math.abs(s))end end if R<_GSteerT then if R<0 then R=math.min(_GSteerT,R+_Tune.ReturnSpeed)else R=math.min(_GSteerT,R+_Tune.SteerSpeed)end else if R>0 then R=math.max(_GSteerT,R-_Tune.ReturnSpeed)else R=math.max(_GSteerT,R-_Tune.SteerSpeed)end end local p=1-math.min(car.DriveSeat.Velocity.Magnitude/_Tune.SteerDecay,1-_Tune.MinSteer/100)for s,A in ipairs(car.Wheels:GetChildren())do if A.Name=="\070"then A.Arm.Steer.CFrame=car.Wheels.F.Base.CFrame*CFrame.Angles(0,-math.rad((R*_Tune.SteerInner)*p),0)elseif A.Name=="\070\076"then if R>=0 then A.Arm.Steer.CFrame=car.Wheels.FL.Base.CFrame*CFrame.Angles(0,-math.rad((R*_Tune.SteerOuter)*p),0)else A.Arm.Steer.CFrame=car.Wheels.FL.Base.CFrame*CFrame.Angles(0,-math.rad((R*_Tune.SteerInner)*p),0)end elseif A.Name=="\070\082"then if R>=0 then A.Arm.Steer.CFrame=car.Wheels.FR.Base.CFrame*CFrame.Angles(0,-math.rad((R*_Tune.SteerInner)*p),0)else A.Arm.Steer.CFrame=car.Wheels.FR.Base.CFrame*CFrame.Angles(0,-math.rad((R*_Tune.SteerOuter)*p),0)end end end end
--[[Steering]] local function Steering() local SteerLocal = script.Parent.Values.SteerC.Value --Mouse Steer if _MSteer then local msWidth = math.max(1, mouse.ViewSizeX * _Tune.Peripherals.MSteerWidth / 200) local mdZone = _Tune.Peripherals.MSteerDZone / 100 local mST = ((mouse.X - mouse.ViewSizeX / 2) / msWidth) if math.abs(mST) <= mdZone then _GSteerT = 0 else _GSteerT = (math.max(math.min((math.abs(mST) - mdZone), (1 - mdZone)), 0) / (1 - mdZone)) ^ _Tune.MSteerExp * (mST / math.abs(mST)) end end --Interpolate Steering if SteerLocal < _GSteerT then if SteerLocal < 0 then SteerLocal = math.min(_GSteerT, SteerLocal + _Tune.ReturnSpeed) else SteerLocal = math.min(_GSteerT, SteerLocal + _Tune.SteerSpeed) end else if SteerLocal > 0 then SteerLocal = math.max(_GSteerT, SteerLocal - _Tune.ReturnSpeed) else SteerLocal = math.max(_GSteerT, SteerLocal - _Tune.SteerSpeed) end end --Steer Decay Multiplier local sDecay = (1 - math.min(car.DriveSeat.Velocity.Magnitude / _Tune.SteerDecay, 1 - (_Tune.MinSteer / 100))) --Apply Steering for _, v in ipairs(car.Wheels:GetChildren()) do if v.Name == "F" then v.Arm.Steer.CFrame = car.Wheels.F.Base.CFrame * CFrame.Angles(0, -math.rad(SteerLocal * _Tune.SteerInner * sDecay), 0) elseif v.Name == "FL" then if SteerLocal >= 0 then v.Arm.Steer.CFrame = car.Wheels.FL.Base.CFrame * CFrame.Angles(0, -math.rad(SteerLocal * _Tune.SteerOuter * sDecay), 0) else v.Arm.Steer.CFrame = car.Wheels.FL.Base.CFrame * CFrame.Angles(0, -math.rad(SteerLocal * _Tune.SteerInner * sDecay), 0) end elseif v.Name == "FR" then if SteerLocal >= 0 then v.Arm.Steer.CFrame = car.Wheels.FR.Base.CFrame * CFrame.Angles(0, -math.rad(SteerLocal * _Tune.SteerInner * sDecay), 0) else v.Arm.Steer.CFrame = car.Wheels.FR.Base.CFrame * CFrame.Angles(0, -math.rad(SteerLocal * _Tune.SteerOuter * sDecay), 0) end end end end
function Prone()L_87_:FireServer("\080\114\111\110\101");(L_14_:Create(L_3_:WaitForChild("\072\117\109\097\110\111\105\100"),TweenInfo.new(.3),{CameraOffset=Vector3.new(0,-3,0)})):Play();(L_3_:WaitForChild("\072\117\109\097\110\111\105\100")).WalkSpeed=4 L_127_=4 L_126_=.025 L_47_=true L_67_=.01 L_66_=-0.05 L_68_=.05 Proned2=Vector3.new(0,.5,.5)L_102_(L_9_,CFrame.new(0,-2.4201169,-0.0385534465,-0.99999994,-5.86197757e-12,-4.54747351e-13,5.52669195e-12,.998915195,.0465667509,0,.0465667509,-0.998915195),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_10_,CFrame.new(1.00000191,-1,-5.96046448e-08,1.31237243e-11,-0.344507754,.938783348,0,.938783467,.344507784,-1,0,-1.86264515e-09),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_11_,CFrame.new(-0.999996185,-1,-1.1920929e-07,-2.58566502e-11,.314521015,-0.949250221,0,.94925046,.314521164,1,3.7252903e-09,1.86264515e-09),nil,function(R)return math.sin(math.rad(R))end,.25)end function Stand()L_87_:FireServer("\083\116\097\110\100");(L_14_:Create(L_3_:WaitForChild("\072\117\109\097\110\111\105\100"),TweenInfo.new(.3),{CameraOffset=Vector3.new(0,0,0)})):Play()L_47_=false if not L_46_ then(L_3_:WaitForChild("\072\117\109\097\110\111\105\100")).WalkSpeed=16 L_126_=.2 L_127_=17 L_67_=L_23_.camrecoil L_66_=L_23_.gunrecoil L_68_=L_23_.Kickback elseif L_46_ then(L_3_:WaitForChild("\072\117\109\097\110\111\105\100")).WalkSpeed=16 L_127_=10 L_126_=.02 L_67_=L_23_.AimCamRecoil L_66_=L_23_.AimGunRecoil L_68_=L_23_.AimKickback end Proned2=Vector3.new(0,0,0)L_102_(L_9_,CFrame.new(0,0,0,-1,0,0,0,0,1,0,1,0),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_10_,CFrame.new(1,-1,0,0,0,1,0,1,0,-1,0,0),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_11_,CFrame.new(-1,-1,0,0,0,-1,0,1,0,1,0,0),nil,function(R)return math.sin(math.rad(R))end,.25)end function Crouch()L_87_:FireServer("\067\114\111\117\099\104");(L_14_:Create(L_3_:WaitForChild("\072\117\109\097\110\111\105\100"),TweenInfo.new(.3),{CameraOffset=Vector3.new(0,-1,0)})):Play();(L_3_:WaitForChild("\072\117\109\097\110\111\105\100")).WalkSpeed=9 L_127_=9 L_126_=.035 L_47_=true L_67_=.02 L_66_=-0.05 L_68_=.05 Proned2=Vector3.new(0,0,0)L_102_(L_9_,CFrame.new(0,-1.04933882,0,-1,0,-1.88871293e-12,1.88871293e-12,-3.55271368e-15,1,0,1,-3.55271368e-15),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_10_,CFrame.new(1,.0456044674,-0.494239986,6.82121026e-13,-1.22639676e-11,1,-0.058873821,.998265445,-1.09836602e-11,-0.998265445,-0.058873821,0),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_11_,CFrame.new(-1.00000381,-0.157019258,-0.471293032,-8.7538865e-12,-8.7538865e-12,-1,.721672177,.692235112,1.64406284e-11,.692235112,-0.721672177,0),nil,function(R)return math.sin(math.rad(R))end,.25)L_102_(L_6_:WaitForChild("\078\101\099\107"),nil,CFrame.new(0,-0.5,0,-1,0,0,0,0,1,0,1,0),function(R)return math.sin(math.rad(R))end,.25)end local R=false L_82_.InputBegan:connect(function(p,s)if not s and L_15_==true then if L_15_ then if p.KeyCode==Enum.KeyCode.C then if L_70_==0 and(not L_49_ and L_15_)then L_70_=1 Crouch()L_71_=false L_73_=true L_72_=false elseif L_70_==1 and(not L_49_ and L_15_)then L_70_=2 Prone()L_73_=false L_71_=true L_72_=false R=true end end if p.KeyCode==Enum.KeyCode.X then if L_70_==2 and(not L_49_ and L_15_)then R=false L_70_=1 Crouch()L_71_=false L_73_=true L_72_=false elseif L_70_==1 and(not L_49_ and L_15_)then L_70_=0 Stand()L_71_=false L_73_=false L_72_=true end end end end end)
--// Stances function Prone() L_87_:FireServer("Prone") L_14_:Create(L_3_:WaitForChild("Humanoid"), TweenInfo.new(0.3), { CameraOffset = Vector3.new(0, -3, 0), }):Play() L_3_:WaitForChild("Humanoid").WalkSpeed = 4 L_127_ = 4 L_126_ = 0.025 L_47_ = true L_67_ = 0.01 L_66_ = -0.05 L_68_ = 0.05 Proned2 = Vector3.new(0, 0.5, 0.5) L_102_( L_9_, CFrame.new( 0, -2.4201169, -0.0385534465, -0.99999994, -5.86197757e-012, -4.54747351e-013, 5.52669195e-012, 0.998915195, 0.0465667509, 0, 0.0465667509, -0.998915195 ), nil, function(L_249_arg1) return math.sin(math.rad(L_249_arg1)) end, 0.25 ) L_102_( L_10_, CFrame.new( 1.00000191, -1, -5.96046448e-008, 1.31237243e-011, -0.344507754, 0.938783348, 0, 0.938783467, 0.344507784, -1, 0, -1.86264515e-009 ), nil, function(L_250_arg1) return math.sin(math.rad(L_250_arg1)) end, 0.25 ) L_102_( L_11_, CFrame.new( -0.999996185, -1, -1.1920929e-007, -2.58566502e-011, 0.314521015, -0.949250221, 0, 0.94925046, 0.314521164, 1, 3.7252903e-009, 1.86264515e-009 ), nil, function(L_251_arg1) return math.sin(math.rad(L_251_arg1)) end, 0.25 ) end function Stand() L_87_:FireServer("Stand") L_14_:Create(L_3_:WaitForChild("Humanoid"), TweenInfo.new(0.3), { CameraOffset = Vector3.new(0, 0, 0), }):Play() L_47_ = false if not L_46_ then L_3_:WaitForChild("Humanoid").WalkSpeed = 16 L_126_ = 0.2 L_127_ = 17 L_67_ = L_23_.camrecoil L_66_ = L_23_.gunrecoil L_68_ = L_23_.Kickback elseif L_46_ then L_3_:WaitForChild("Humanoid").WalkSpeed = 16 L_127_ = 10 L_126_ = 0.02 L_67_ = L_23_.AimCamRecoil L_66_ = L_23_.AimGunRecoil L_68_ = L_23_.AimKickback end Proned2 = Vector3.new(0, 0, 0) L_102_(L_9_, CFrame.new(0, 0, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), nil, function(L_252_arg1) return math.sin(math.rad(L_252_arg1)) end, 0.25) L_102_(L_10_, CFrame.new(1, -1, 0, 0, 0, 1, 0, 1, -0, -1, 0, 0), nil, function(L_253_arg1) return math.sin(math.rad(L_253_arg1)) end, 0.25) L_102_(L_11_, CFrame.new(-1, -1, 0, 0, 0, -1, 0, 1, 0, 1, 0, 0), nil, function(L_254_arg1) return math.sin(math.rad(L_254_arg1)) end, 0.25) end function Crouch() L_87_:FireServer("Crouch") L_14_:Create(L_3_:WaitForChild("Humanoid"), TweenInfo.new(0.3), { CameraOffset = Vector3.new(0, -1, 0), }):Play() L_3_:WaitForChild("Humanoid").WalkSpeed = 9 L_127_ = 9 L_126_ = 0.035 L_47_ = true L_67_ = 0.02 L_66_ = -0.05 L_68_ = 0.05 Proned2 = Vector3.new(0, 0, 0) L_102_( L_9_, CFrame.new( 0, -1.04933882, 0, -1, 0, -1.88871293e-012, 1.88871293e-012, -3.55271368e-015, 1, 0, 1, -3.55271368e-015 ), nil, function(L_255_arg1) return math.sin(math.rad(L_255_arg1)) end, 0.25 ) L_102_( L_10_, CFrame.new( 1, 0.0456044674, -0.494239986, 6.82121026e-013, -1.22639676e-011, 1, -0.058873821, 0.998265445, -1.09836602e-011, -0.998265445, -0.058873821, 0 ), nil, function(L_256_arg1) return math.sin(math.rad(L_256_arg1)) end, 0.25 ) L_102_( L_11_, CFrame.new( -1.00000381, -0.157019258, -0.471293032, -8.7538865e-012, -8.7538865e-012, -1, 0.721672177, 0.692235112, 1.64406284e-011, 0.692235112, -0.721672177, 0 ), nil, function(L_257_arg1) return math.sin(math.rad(L_257_arg1)) end, 0.25 ) L_102_(L_6_:WaitForChild("Neck"), nil, CFrame.new(0, -0.5, 0, -1, 0, 0, 0, 0, 1, 0, 1, -0), function(L_258_arg1) return math.sin(math.rad(L_258_arg1)) end, 0.25) end local L_137_ = false L_82_.InputBegan:connect(function(L_259_arg1, L_260_arg2) if not L_260_arg2 and L_15_ == true then if L_15_ then if L_259_arg1.KeyCode == Enum.KeyCode.C then if L_70_ == 0 and not L_49_ and L_15_ then L_70_ = 1 Crouch() L_71_ = false L_73_ = true L_72_ = false elseif L_70_ == 1 and not L_49_ and L_15_ then L_70_ = 2 Prone() L_73_ = false L_71_ = true L_72_ = false L_137_ = true end end if L_259_arg1.KeyCode == Enum.KeyCode.X then if L_70_ == 2 and not L_49_ and L_15_ then L_137_ = false L_70_ = 1 Crouch() L_71_ = false L_73_ = true L_72_ = false elseif L_70_ == 1 and not L_49_ and L_15_ then L_70_ = 0 Stand() L_71_ = false L_73_ = false L_72_ = true end end end end end)
local z=script.Parent.Config local p=script.Parent.ScoreBlock local R=z.UploadScore local W=z.RemoteScore local s=z.LocalScoreUpdate R.Refresh.Value=SCORE_UPDATE W.Score.Value=NAME_OF_STAT W.Original.Value=PLAYER_SAVE W.DataStore.Value=DATA_STORE s.Refresh.Value=PLAYER_UPDATE R.Disabled=false R.Parent=game.ServerScriptService W.Disabled=false W.Parent=game.Workspace s.Disabled=false s.Parent=game.StarterGui
-- Stuff (do not edit below) local configModel = script.Parent.Config local scoreBlock = script.Parent.ScoreBlock local uS = configModel.UploadScore local rS = configModel.RemoteScore local lSU = configModel.LocalScoreUpdate uS.Refresh.Value = SCORE_UPDATE rS.Score.Value = NAME_OF_STAT rS.Original.Value = PLAYER_SAVE rS.DataStore.Value = DATA_STORE lSU.Refresh.Value = PLAYER_UPDATE uS.Disabled = false uS.Parent = game.ServerScriptService rS.Disabled = false rS.Parent = game.Workspace lSU.Disabled = false lSU.Parent = game.StarterGui
local function z(z,p)while not z:FindFirstChild(p)do z.ChildAdded:wait()end return z[p]end
--------------------- TEMPLATE ASSAULT RIFLE WEAPON --------------------------- -- Waits for the child of the specified parent local function WaitForChild(parent, childName) while not parent:FindFirstChild(childName) do parent.ChildAdded:wait() end return parent[childName] end
local z=TweenInfo.new(.25,Enum.EasingStyle.Quad,Enum.EasingDirection.In,0,false,0)local p=Vehicle:WaitForChild("\082\101\109\111\116\101\115")local R=p:WaitForChild("\083\101\116\084\104\114\111\116\116\108\101")local W=nil local s=true local k=true local m=1.75 local V=0 local Q=false local t=0 local L=0 local Z=1
-- tween engine sound volume when we start driving local engineStartTween = TweenInfo.new(0.25, Enum.EasingStyle.Quad, Enum.EasingDirection.In, 0, false, 0) local Remotes = Vehicle:WaitForChild("Remotes") local SetThrottleRemote = Remotes:WaitForChild("SetThrottle") local SetThrottleConnection = nil local EngineSoundEnabled = true local TireTrailEnabled = true local ignitionTime = 1.75 -- seconds local lastAvgAngularVelocity = 0 local throttleEnabled = false local lastThrottleUpdate = 0 local enginePower = 0 -- current rpm of the engine local gainModifier = 1 -- modifier to engine rpm gain (lower if approaching max speed)
TracerTransparency=0 TracerLightEmission=1 TracerTextureLength=.1 TracerLifetime=.05 TracerFaceCamera=true TracerColor=BrickColor.new("\087\104\105\116\101")
--// Tracer Vars TracerTransparency = 0 TracerLightEmission = 1 TracerTextureLength = 0.1 TracerLifetime = 0.05 TracerFaceCamera = true TracerColor = BrickColor.new("White")
local z=2.718281828459 local function p(p,R,W,s,k,m,V)if R==0 then return W elseif p<.99999999 then local Q=(1-p*p)^.5 local t=(W-k)+((2*p)/R)*m local L=((p/Q)*(W-k)+s/(Q*R))+(((2*p)*p-1)/(Q*R))*m local Z=math.cos((Q*R)*V)local e=math.sin((Q*R)*V)local x=z^((p*R)*V)return(((Z/x)*t+(e/x)*L)+k)+(V-(2*p)/R)*m,(((R*(Z*Q-p*e))/x)*L-((R*(Z*p+Q*e))/x)*t)+m elseif p<1.00000001 then local p=(W-k)+(2/R)*m local Q=(W-k)+(s+m)/R local t=z^(R*V)return((p+(Q*R)*V)/t+k)+(V-2/R)*m,m-(R/t)*(p+(R*V-1)*Q)else local Q=(p*p-1)^.5 local t=(m-s)/((2*R)*Q)local L=(p/R)*m-(k-W)/2 local Z=(1-p/Q)*L+t local e=(1+p/Q)*L-t local x=z^((-(Q+p)*R)*V)local F=z^(((Q-p)*R)*V)return((Z*x+e*F)+k)+(V-(2*p)/R)*m,(((F*(Q-p))*R)*e-((x*(p+Q))*R)*Z)+m end end local function R(z,p,R)return z+R*p,p end local W={}W.__index=W
--[[ A simplistic spring implementation. ]] local e = 2.718281828459045 local function posvel(d, s, p0, v0, p1, v1, x) if s == 0 then return p0 elseif d < 1 - 1e-8 then local h = (1 - d * d) ^ 0.5 local c1 = (p0 - p1 + 2 * d / s * v1) local c2 = d / h * (p0 - p1) + v0 / (h * s) + (2 * d * d - 1) / (h * s) * v1 local co = math.cos(h * s * x) local si = math.sin(h * s * x) local ex = e ^ (d * s * x) return co / ex * c1 + si / ex * c2 + p1 + (x - 2 * d / s) * v1, s * (co * h - d * si) / ex * c2 - s * (co * d + h * si) / ex * c1 + v1 elseif d < 1 + 1e-8 then local c1 = p0 - p1 + 2 / s * v1 local c2 = p0 - p1 + (v0 + v1) / s local ex = e ^ (s * x) return (c1 + c2 * s * x) / ex + p1 + (x - 2 / s) * v1, v1 - s / ex * (c1 + (s * x - 1) * c2) else local h = (d * d - 1) ^ 0.5 local a = (v1 - v0) / (2 * s * h) local b = d / s * v1 - (p1 - p0) / 2 local c1 = (1 - d / h) * b + a local c2 = (1 + d / h) * b - a local co = e ^ (-(h + d) * s * x) local si = e ^ ((h - d) * s * x) return c1 * co + c2 * si + p1 + (x - 2 * d / s) * v1, si * (h - d) * s * c2 - co * (d + h) * s * c1 + v1 end end local function targposvel(p1, v1, x) return p1 + x * v1, v1 end local Spring = {} Spring.__index = Spring
function wait_time(z)local p=tick()local R=(game:GetService("\082\117\110\083\101\114\118\105\099\101")).Heartbeat repeat R:Wait()until tick()-p>=z return tick()-p end
-- a better alternative implementation for the wait function function wait_time(duration) local start = tick() local Heartbeat = game:GetService("RunService").Heartbeat repeat Heartbeat:Wait() until (tick() - start) >= duration return (tick() - start) end
local z=6.1/#themeColors local p=pages.custom["\065\066 \084\104\101\109\101\083\101\108\101\099\116\105\111\110"]local R=true local function W(z,R)if z==nil then for p,W in pairs(themeColors)do if W[1]==main.pdata.Theme then z=W[1]R=W[2]break end end end if z then local W={}for z,p in pairs(main.gui:GetDescendants())do if p:IsA("\066\111\111\108\086\097\108\117\101")and p.Name=="\084\104\101\109\101"then table.insert(W,p.Parent)end end for z,p in pairs(W)do local W=R if p.Theme.Value then local z,p,s=Color3.toHSV(R)W=Color3.fromHSV(z,p,s*1.35)end if p:IsA("\084\101\120\116\076\097\098\101\108")then local z,s,k=Color3.toHSV(R)W=Color3.fromHSV(z,s,k*2)p.TextColor3=W else p.BackgroundColor3=W end end for p,R in pairs(p:GetChildren())do if R:IsA("\084\101\120\116\066\117\116\116\111\110")then if R.Name==z then R.BorderSizePixel=1 else R.BorderSizePixel=0 end end end end end for s,k in pairs(themeColors)do local m=k[1]local V=k[2]local Q=p.ThemeTemplate:Clone()Q.Name=m Q.UIAspectRatioConstraint.AspectRatio=z Q.BackgroundColor3=V Q.MouseButton1Down:Connect(function()if R then R=false main.signals.ChangeSetting:InvokeServer({"\084\104\101\109\101";m})W(m,V)R=true end end)Q.Visible=true Q.Parent=p end
-- << CUSTOM >> -- Theme local ratio = 6.1 / #themeColors local themeFrame = pages.custom["AB ThemeSelection"] local themeDe = true local function updateThemeSelection(themeName, themeColor) if themeName == nil then for i, v in pairs(themeColors) do if v[1] == main.pdata.Theme then themeName = v[1] themeColor = v[2] break end end end if themeName then local themeFrames = {} for a, b in pairs(main.gui:GetDescendants()) do if b:IsA("BoolValue") and b.Name == "Theme" then table.insert(themeFrames, b.Parent) end end for _, f in pairs(themeFrames) do local newThemeColor = themeColor if f.Theme.Value then local h, s, v = Color3.toHSV(themeColor) newThemeColor = Color3.fromHSV(h, s, v * 1.35) end if f:IsA("TextLabel") then local h, s, v = Color3.toHSV(themeColor) newThemeColor = Color3.fromHSV(h, s, v * 2) f.TextColor3 = newThemeColor else f.BackgroundColor3 = newThemeColor end end for a, b in pairs(themeFrame:GetChildren()) do if b:IsA("TextButton") then if b.Name == themeName then b.BorderSizePixel = 1 else b.BorderSizePixel = 0 end end end end end for i, theme in pairs(themeColors) do local themeName = theme[1] local themeColor = theme[2] local box = themeFrame.ThemeTemplate:Clone() box.Name = themeName box.UIAspectRatioConstraint.AspectRatio = ratio box.BackgroundColor3 = themeColor box.MouseButton1Down:Connect(function() if themeDe then themeDe = false main.signals.ChangeSetting:InvokeServer({ "Theme", themeName }) updateThemeSelection(themeName, themeColor) themeDe = true end end) box.Visible = true box.Parent = themeFrame end
local z={}local p={}local R={}
--Library local DataStoreCache = {} local DataStore2 = {} local combinedDataStoreInfo = {}
(serverMain:WaitForChild("\080\108\121\114")).Value=Player local z=Spring.new(V3())z.s=S.momentumSettings.Speed z.d=S.momentumSettings.Damper local p=Spring.new(V3())p.s=S.recoilSettings.springSpeed p.d=S.recoilSettings.springDamper local R=Spring.new(V3())R.s=35 R.d=.5 local W=Spring.new(V3(crossOffset+(baseSpread+currentSpread)*50,0,0))W.s=20 W.d=.75
-------------------------------------------------------------------------------------- --------------------[ GUN SETUP ]----------------------------------------------------- -------------------------------------------------------------------------------------- serverMain:WaitForChild("Plyr").Value = Player local gunMomentum = Spring.new(V3()) gunMomentum.s = S.momentumSettings.Speed gunMomentum.d = S.momentumSettings.Damper local gunRecoilSpring = Spring.new(V3()) gunRecoilSpring.s = S.recoilSettings.springSpeed gunRecoilSpring.d = S.recoilSettings.springDamper local camRecoilSpring = Spring.new(V3()) camRecoilSpring.s = 35 camRecoilSpring.d = 0.5 local crossSpring = Spring.new(V3(crossOffset + (baseSpread + currentSpread) * 50, 0, 0)) crossSpring.s = 20 crossSpring.d = 0.75
module.ChatOnWithTopBarOff=false module.ScreenGuiDisplayOrder=6 module.ShowFriendJoinNotification=true
-- Make the chat work when the top bar is off module.ChatOnWithTopBarOff = false module.ScreenGuiDisplayOrder = 6 -- The DisplayOrder value for the ScreenGui containing the chat. module.ShowFriendJoinNotification = true -- Show a notification in the chat when a players friend joins the game.
local z=game:GetService("\068\097\116\097\083\116\111\114\101\083\101\114\118\105\099\101")local p={}p.__index=p function p.Get(z)local p,R=pcall(function()return((z.orderedDataStore:GetSortedAsync(false,1)):GetCurrentPage())[1]end)if not p then return false,R end if R then local p=R local W=p.value z.dataStore2:Debug("\109\111\115\116 \114\101\099\101\110\116 \107\101\121",p)z.mostRecentKey=W local s,k=pcall(function()return z.dataStore:GetAsync(W)end)if not s then return false,k end return true,k else z.dataStore2:Debug("\110\111 \114\101\099\101\110\116 \107\101\121")return true,nil end end function p.Set(p,z)local R=(p.mostRecentKey or 0)+1 local W,s=pcall(function()p.dataStore:SetAsync(R,z)end)if not W then return false,s end local k,m=pcall(function()p.orderedDataStore:SetAsync(R,R)end)if not k then return false,m end p.mostRecentKey=R return true end function p.new(R)local W=R.Name..("\047"..R.UserId)local s={dataStore2=R;dataStore=z:GetDataStore(W),orderedDataStore=z:GetOrderedDataStore(W)}return setmetatable(s,p)end return p
--[[ berezaa's method of saving data (from the dev forum): What I do and this might seem a little over-the-top but it's fine as long as you're not using datastores excessively elsewhere is have a datastore and an ordereddatastore for each player. When you perform a save, add a key (can be anything) with the value of os.time() to the ordereddatastore and save a key with the os.time() and the value of the player's data to the regular datastore. Then, when loading data, get the highest number from the ordered data store (most recent save) and load the data with that as a key. Ever since I implemented this, pretty much no one has ever lost data. There's no caches to worry about either because you're never overriding any keys. Plus, it has the added benefit of allowing you to restore lost data, since every save doubles as a backup which can be easily found with the ordereddatastore edit: while there's no official comment on this, many developers including myself have noticed really bad cache times and issues with using the same datastore keys to save data across multiple places in the same game. With this method, data is almost always instantly accessible immediately after a player teleports, making it useful for multi-place games. --]] local DataStoreService = game:GetService("DataStoreService") local OrderedBackups = {} OrderedBackups.__index = OrderedBackups function OrderedBackups:Get() local success, value = pcall(function() return self.orderedDataStore:GetSortedAsync(false, 1):GetCurrentPage()[1] end) if not success then return false, value end if value then local mostRecentKeyPage = value local recentKey = mostRecentKeyPage.value self.dataStore2:Debug("most recent key", mostRecentKeyPage) self.mostRecentKey = recentKey local success, value = pcall(function() return self.dataStore:GetAsync(recentKey) end) if not success then return false, value end return true, value else self.dataStore2:Debug("no recent key") return true, nil end end function OrderedBackups:Set(value) local key = (self.mostRecentKey or 0) + 1 local success, problem = pcall(function() self.dataStore:SetAsync(key, value) end) if not success then return false, problem end local success, problem = pcall(function() self.orderedDataStore:SetAsync(key, key) end) if not success then return false, problem end self.mostRecentKey = key return true end function OrderedBackups.new(dataStore2) local dataStoreKey = dataStore2.Name .. "/" .. dataStore2.UserId local info = { dataStore2 = dataStore2, dataStore = DataStoreService:GetDataStore(dataStoreKey), orderedDataStore = DataStoreService:GetOrderedDataStore(dataStoreKey), } return setmetatable(info, OrderedBackups) end return OrderedBackups
This=script.Parent Elevator=This.Parent.Parent.Parent CustomLabel=require(This.Parent.Parent.Parent.CustomLabel)Characters=require(script.Characters)CustomText=CustomLabel.CUSTOMFLOORLABEL;(Elevator:WaitForChild("\070\108\111\111\114")).Changed:connect(function(z)ChangeFloor(tostring(z))end)function ChangeFloor(z)if CustomText[tonumber(z)]then z=CustomText[tonumber(z)]end SetDisplay(1,string.len(z)==2 and z:sub(1,1)or"\078\073\076")SetDisplay(2,string.len(z)==2 and z:sub(2,2)or z)end function SetDisplay(z,p)if This.Display:FindFirstChild("\068\073\071"..z)and Characters[p]~=nil then for p,R in pairs(Characters[p])do for p=1,7,1 do This.Display["\068\073\071"..z]["\068"..p].Color=R:sub(p,p)=="\049"and DisplayColor or DisabledColor This.Display["\068\073\071"..z]["\068"..p].Material=R:sub(p,p)=="\049"and Lit or Unlit end end end end
--------------------------------------------------- This = script.Parent Elevator = This.Parent.Parent.Parent CustomLabel = require(This.Parent.Parent.Parent.CustomLabel) Characters = require(script.Characters) CustomText = CustomLabel["CUSTOMFLOORLABEL"] Elevator:WaitForChild("Floor").Changed:connect(function(floor) --custom indicator code-- ChangeFloor(tostring(floor)) end) function ChangeFloor(SF) if CustomText[tonumber(SF)] then SF = CustomText[tonumber(SF)] end SetDisplay(1, (string.len(SF) == 2 and SF:sub(1, 1) or "NIL")) SetDisplay(2, (string.len(SF) == 2 and SF:sub(2, 2) or SF)) end function SetDisplay(ID, CHAR) if This.Display:FindFirstChild("DIG" .. ID) and Characters[CHAR] ~= nil then for i, l in pairs(Characters[CHAR]) do for r = 1, 7 do This.Display["DIG" .. ID]["D" .. r].Color = (l:sub(r, r) == "1" and DisplayColor or DisabledColor) This.Display["DIG" .. ID]["D" .. r].Material = (l:sub(r, r) == "1" and Lit or Unlit) end end end end
local function z(z)while z:FindFirstChild("\099\114\101\097\116\111\114")do z.creator:Destroy()end local p=CreatorTag:Clone()DebrisService:AddItem(p,1.5)p.Parent=z end
-- Removes any old creator tags and applies a new one to the target local function ApplyTags(target) while target:FindFirstChild("creator") do target.creator:Destroy() end local creatorTagClone = CreatorTag:Clone() DebrisService:AddItem(creatorTagClone, 1.5) creatorTagClone.Parent = target end
function keyDown(z)local p=string.lower(z)if p==S.Keys.lowerStance and S.canChangeStance then if not Running then if Stance==0 then if S.stanceSettings.Stances.Crouch then Crouch()elseif S.stanceSettings.Stances.Prone then Prone()end elseif Stance==1 then if S.stanceSettings.Stances.Prone then Prone()end end elseif S.dolphinDive then wait()if Humanoid:GetState()~=Enum.HumanoidStateType.Freefall and(not UIS:IsKeyDown("\083\112\097\099\101")and runReady)then local z=Humanoid.Changed:connect(function()Humanoid.Jump=false end)runReady=false Dive()Running=false wait(S.diveSettings.rechargeTime)z:disconnect()runReady=true end end end if p==S.Keys.raiseStance and S.canChangeStance then if not Running then if Stance==2 then if S.stanceSettings.Stances.Crouch then Crouch()else Stand()end elseif Stance==1 then Stand()end end end if p==S.Keys.ADS then if S.aimSettings.holdToADS then if not AimingIn and not Aimed then AimingIn=true aimGun()AimingIn=false end else if Aimed then unAimGun()else aimGun()end end end if p==S.Keys.selectFire and S.selectFire then if canSelectFire then canSelectFire=false rawFireMode=rawFireMode+1 modeGUI.Text=Modes[(rawFireMode-1)%numModes+1]if modeGUI.Text=="\065\085\084\079"then fireFunction=autoFire elseif modeGUI.Text=="\066\085\082\083\084"then fireFunction=burstFire elseif modeGUI.Text=="\083\069\077\073"then fireFunction=semiFire else fireFunction=nil end local z=S.selectFireSettings.animSpeed/.6 if S.selectFireSettings.GUI then spawn(function()fireSelect.Visible=true local p=rawFireMode local R=1.5/(z*.25)local W=0 wait(z*.1)while true do RS.RenderStepped:wait()local z=W+R W=z>90 and 90 or z if p~=rawFireMode then break end updateModeLabels(rawFireMode-1,rawFireMode,W)if W==90 then break end end wait(z*.25)fireSelect.Visible=false end)end if S.selectFireSettings.Animation and(not Aimed and(not isRunning and not isCrawling))then spawn(function()local p={function()tweenJoint(RWeld2,nil,CFANG(0,RAD(5),0),Sine,z*.15)tweenJoint(LWeld,armC0[1],CF(.1,1,-0.3)*CFANG(RAD(-7),0,RAD(-65)),Linear,z*.15)wait(z*.2)end;function()tweenJoint(LWeld,armC0[1],CF(.1,1,-0.3)*CFANG(RAD(-10),0,RAD(-65)),Linear,z*.1)wait(z*.2)end,function()tweenJoint(RWeld2,nil,CF(),Sine,z*.2)tweenJoint(LWeld,armC0[1],S.unAimedC1.leftArm,Sine,z*.2)wait(z*.2)end}for z,p in pairs(p)do if Aimed or isRunning or isCrawling or Reloading then break end p()end end)end if S.selectFireSettings.Animation or S.selectFireSettings.GUI then wait(S.selectFireSettings.animSpeed)end canSelectFire=true end end if p==S.Keys.Reload then if not Reloading and not isCrawling then Reload()end end if p==S.Keys.Sprint then runKeyPressed=true if runReady then if not Idling and(Walking and(not Running and(not Knifing and not(Aimed and(S.guiScope and S.Keys.Sprint==S.Keys.scopeSteady)))))then monitorStamina()end end end if p==S.Keys.scopeSteady then steadyKeyPressed=true if Aimed and not Aiming then takingBreath=false steadyCamera()end end for z,R in pairs(Plugins.KeyDown)do if p==string.lower(R.Key)then spawn(function()R.Plugin()end)end end end function keyUp(z)local p=string.lower(z)if p==S.Keys.ADS then if S.aimSettings.holdToADS then if not AimingOut and Aimed then AimingOut=true unAimGun()AimingOut=false end end end if p==S.Keys.Sprint then runKeyPressed=false Running=false if not chargingStamina then rechargeStamina()end end if p==S.Keys.scopeSteady then steadyKeyPressed=false end for z,R in pairs(Plugins.KeyUp)do if p==string.lower(R.Key)then spawn(function()R.Plugin()end)end end end
--------------------[ KEYBOARD FUNCTIONS ]-------------------------------------------- function keyDown(K) local Key = string.lower(K) if Key == S.Keys.lowerStance and S.canChangeStance then if not Running then if Stance == 0 then if S.stanceSettings.Stances.Crouch then Crouch() elseif S.stanceSettings.Stances.Prone then Prone() end elseif Stance == 1 then if S.stanceSettings.Stances.Prone then Prone() end end elseif S.dolphinDive then wait() if Humanoid:GetState() ~= Enum.HumanoidStateType.Freefall and (not UIS:IsKeyDown("Space")) and runReady then local tempConnection = Humanoid.Changed:connect(function() Humanoid.Jump = false end) runReady = false Dive() Running = false wait(S.diveSettings.rechargeTime) tempConnection:disconnect() runReady = true end end end if Key == S.Keys.raiseStance and S.canChangeStance then if not Running then if Stance == 2 then if S.stanceSettings.Stances.Crouch then Crouch() else Stand() end elseif Stance == 1 then Stand() end end end if Key == S.Keys.ADS then if S.aimSettings.holdToADS then if (not AimingIn) and not Aimed then AimingIn = true aimGun() AimingIn = false end else if Aimed then unAimGun() else aimGun() end end end if Key == S.Keys.selectFire and S.selectFire then if canSelectFire then canSelectFire = false rawFireMode = rawFireMode + 1 modeGUI.Text = Modes[((rawFireMode - 1) % numModes) + 1] if modeGUI.Text == "AUTO" then fireFunction = autoFire elseif modeGUI.Text == "BURST" then fireFunction = burstFire elseif modeGUI.Text == "SEMI" then fireFunction = semiFire else fireFunction = nil end local speedAlpha = S.selectFireSettings.animSpeed / 0.6 if S.selectFireSettings.GUI then spawn(function() fireSelect.Visible = true local prevRawFireMode = rawFireMode local Increment = 1.5 / (speedAlpha * 0.25) local X = 0 wait(speedAlpha * 0.1) while true do RS.RenderStepped:wait() local newX = X + Increment X = (newX > 90 and 90 or newX) if prevRawFireMode ~= rawFireMode then break end updateModeLabels(rawFireMode - 1, rawFireMode, X) if X == 90 then break end end wait(speedAlpha * 0.25) fireSelect.Visible = false end) end if S.selectFireSettings.Animation and not Aimed and not isRunning and not isCrawling then spawn(function() local sequenceTable = { function() tweenJoint(RWeld2, nil, CFANG(0, RAD(5), 0), Sine, speedAlpha * 0.15) tweenJoint( LWeld, armC0[1], CF(0.1, 1, -0.3) * CFANG(RAD(-7), 0, RAD(-65)), Linear, speedAlpha * 0.15 ) wait(speedAlpha * 0.2) end, function() tweenJoint( LWeld, armC0[1], CF(0.1, 1, -0.3) * CFANG(RAD(-10), 0, RAD(-65)), Linear, speedAlpha * 0.1 ) wait(speedAlpha * 0.2) end, function() tweenJoint(RWeld2, nil, CF(), Sine, speedAlpha * 0.2) tweenJoint(LWeld, armC0[1], S.unAimedC1.leftArm, Sine, speedAlpha * 0.2) wait(speedAlpha * 0.2) end, } for _, F in pairs(sequenceTable) do if Aimed or isRunning or isCrawling or Reloading then break end F() end end) end if S.selectFireSettings.Animation or S.selectFireSettings.GUI then wait(S.selectFireSettings.animSpeed) end canSelectFire = true end end if Key == S.Keys.Reload then if (not Reloading) and not isCrawling then Reload() end end if Key == S.Keys.Sprint then runKeyPressed = true if runReady then if not Idling and Walking and not Running and not Knifing and not (Aimed and S.guiScope and S.Keys.Sprint == S.Keys.scopeSteady) then monitorStamina() end end end if Key == S.Keys.scopeSteady then steadyKeyPressed = true if Aimed and not Aiming then takingBreath = false steadyCamera() end end for _, PTable in pairs(Plugins.KeyDown) do if Key == string.lower(PTable.Key) then spawn(function() PTable.Plugin() end) end end end function keyUp(K) local Key = string.lower(K) if Key == S.Keys.ADS then if S.aimSettings.holdToADS then if (not AimingOut) and Aimed then AimingOut = true unAimGun() AimingOut = false end end end if Key == S.Keys.Sprint then runKeyPressed = false Running = false if not chargingStamina then rechargeStamina() end end if Key == S.Keys.scopeSteady then steadyKeyPressed = false end for _, PTable in pairs(Plugins.KeyUp) do if Key == string.lower(PTable.Key) then spawn(function() PTable.Plugin() end) end end end
local z=true local p=Player:GetMouse()local R=false local W=nil local s=5 local k=1
--Variables-- local Enabled = true local mouse = Player:GetMouse() local ButtonDown = false local Key = nil local cooldown = 5 local Debounce = 1
function UnDigify(z)if z<1 or z>61 then return""elseif z==1 then return"\049"elseif z==2 then return"\033"elseif z==3 then return"\050"elseif z==4 then return"\064"elseif z==5 then return"\051"elseif z==6 then return"\052"elseif z==7 then return"\036"elseif z==8 then return"\053"elseif z==9 then return"\037"elseif z==10 then return"\054"elseif z==11 then return"\094"elseif z==12 then return"\055"elseif z==13 then return"\056"elseif z==14 then return"\042"elseif z==15 then return"\057"elseif z==16 then return"\040"elseif z==17 then return"\048"elseif z==18 then return"\113"elseif z==19 then return"\081"elseif z==20 then return"\119"elseif z==21 then return"\087"elseif z==22 then return"\101"elseif z==23 then return"\069"elseif z==24 then return"\114"elseif z==25 then return"\116"elseif z==26 then return"\084"elseif z==27 then return"\121"elseif z==28 then return"\089"elseif z==29 then return"\117"elseif z==30 then return"\105"elseif z==31 then return"\073"elseif z==32 then return"\111"elseif z==33 then return"\079"elseif z==34 then return"\112"elseif z==35 then return"\080"elseif z==36 then return"\097"elseif z==37 then return"\115"elseif z==38 then return"\083"elseif z==39 then return"\100"elseif z==40 then return"\068"elseif z==41 then return"\102"elseif z==42 then return"\103"elseif z==43 then return"\071"elseif z==44 then return"\104"elseif z==45 then return"\072"elseif z==46 then return"\106"elseif z==47 then return"\074"elseif z==48 then return"\107"elseif z==49 then return"\108"elseif z==50 then return"\076"elseif z==51 then return"\122"elseif z==52 then return"\090"elseif z==53 then return"\120"elseif z==54 then return"\099"elseif z==55 then return"\067"elseif z==56 then return"\118"elseif z==57 then return"\086"elseif z==58 then return"\098"elseif z==59 then return"\066"elseif z==60 then return"\110"elseif z==61 then return"\109"else return"\063"end end function IsBlack(z)if z%12==2 or z%12==4 or z%12==7 or z%12==9 or z%12==11 then return true end end local z=game:GetService("\084\119\101\101\110\083\101\114\118\105\099\101")function Tween(p,R,W,s,...)local k=TweenInfo.new(W,...)local m=z:Create(p,k,R)m:Play()if s then m.Completed:wait()end return end local p={}if script.Parent.Keys:FindFirstChild("\075\101\121\115")then for z,R in pairs(script.Parent.Keys.Keys:GetChildren())do p[R.Name]={R.Position;R.Orientation}end else for z,R in pairs(script.Parent.Keys:GetChildren())do if R:IsA("\077\111\100\101\108")then for z,W in pairs(R:GetChildren())do p[R.Name]={W.Position,W.Orientation}end end end end function AnimateKey(z,R,W,s,k,m,V,Q)pcall(function()local t=script.Parent.Keys.Keys:FindFirstChild(z)if t then local z={}local L=p[t.Name][1]local Z=p[t.Name][2]local e=L-Vector3.new(R,W,s)local x=Z-Vector3.new(k,m,V)z.Position=Vector3.new(t.Position.x,e.Y,e.Z)z.Orientation=x Tween(t,z,Q,Enum.EasingStyle.Linear)z={}z.Position=Vector3.new(t.Position.x,L.y,L.z)z.Orientation=Z Tween(t,z,Q,Enum.EasingStyle.Linear)else print(z.." \119\097\115 \110\111\116 \102\111\117\110\100\044 \111\114 \121\111\117 \100\111 \110\111\116 \104\097\118\101 \116\104\101 \099\111\114\114\101\099\116 \099\111\110\102\105\103\117\114\097\116\105\111\110 \102\111\114 \116\104\101 \112\105\097\110\111 \107\101\121\115")end end)end
---------------------------------- ------------FUNCTIONS------------- ---------------------------------- function UnDigify(digit) if digit < 1 or digit > 61 then return "" elseif digit == 1 then return "1" elseif digit == 2 then return "!" elseif digit == 3 then return "2" elseif digit == 4 then return "@" elseif digit == 5 then return "3" elseif digit == 6 then return "4" elseif digit == 7 then return "$" elseif digit == 8 then return "5" elseif digit == 9 then return "%" elseif digit == 10 then return "6" elseif digit == 11 then return "^" elseif digit == 12 then return "7" elseif digit == 13 then return "8" elseif digit == 14 then return "*" elseif digit == 15 then return "9" elseif digit == 16 then return "(" elseif digit == 17 then return "0" elseif digit == 18 then return "q" elseif digit == 19 then return "Q" elseif digit == 20 then return "w" elseif digit == 21 then return "W" elseif digit == 22 then return "e" elseif digit == 23 then return "E" elseif digit == 24 then return "r" elseif digit == 25 then return "t" elseif digit == 26 then return "T" elseif digit == 27 then return "y" elseif digit == 28 then return "Y" elseif digit == 29 then return "u" elseif digit == 30 then return "i" elseif digit == 31 then return "I" elseif digit == 32 then return "o" elseif digit == 33 then return "O" elseif digit == 34 then return "p" elseif digit == 35 then return "P" elseif digit == 36 then return "a" elseif digit == 37 then return "s" elseif digit == 38 then return "S" elseif digit == 39 then return "d" elseif digit == 40 then return "D" elseif digit == 41 then return "f" elseif digit == 42 then return "g" elseif digit == 43 then return "G" elseif digit == 44 then return "h" elseif digit == 45 then return "H" elseif digit == 46 then return "j" elseif digit == 47 then return "J" elseif digit == 48 then return "k" elseif digit == 49 then return "l" elseif digit == 50 then return "L" elseif digit == 51 then return "z" elseif digit == 52 then return "Z" elseif digit == 53 then return "x" elseif digit == 54 then return "c" elseif digit == 55 then return "C" elseif digit == 56 then return "v" elseif digit == 57 then return "V" elseif digit == 58 then return "b" elseif digit == 59 then return "B" elseif digit == 60 then return "n" elseif digit == 61 then return "m" else return "?" end end function IsBlack(note) if note % 12 == 2 or note % 12 == 4 or note % 12 == 7 or note % 12 == 9 or note % 12 == 11 then return true end end local TweenService = game:GetService("TweenService") function Tween(obj, Goal, Time, Wait, ...) local TwInfo = TweenInfo.new(Time, ...) local twn = TweenService:Create(obj, TwInfo, Goal) twn:Play() if Wait then twn.Completed:wait() end return end local orgins = {} if script.Parent.Keys:FindFirstChild("Keys") then for i, v in pairs(script.Parent.Keys.Keys:GetChildren()) do orgins[v.Name] = { v.Position, v.Orientation } end else for i, v in pairs(script.Parent.Keys:GetChildren()) do if v:IsA("Model") then for a, b in pairs(v:GetChildren()) do orgins[v.Name] = { b.Position, b.Orientation } end end end end function AnimateKey(note1, px, py, pz, ox, oy, oz, Time) pcall(function() local obj = script.Parent.Keys.Keys:FindFirstChild(note1) if obj then local Properties = {} local OrginP = orgins[obj.Name][1] local OrginO = orgins[obj.Name][2] local changep = OrginP - Vector3.new(px, py, pz) local changeo = OrginO - Vector3.new(ox, oy, oz) Properties.Position = Vector3.new(obj.Position.x, changep.Y, changep.Z) Properties.Orientation = changeo Tween(obj, Properties, Time, Enum.EasingStyle.Linear) Properties = {} Properties.Position = Vector3.new(obj.Position.x, OrginP.y, OrginP.z) Properties.Orientation = OrginO Tween(obj, Properties, Time, Enum.EasingStyle.Linear) else print(note1 .. " was not found, or you do not have the correct configuration for the piano keys") end end) end
Tune.Config="\082\087\068"Tune.FDiffSlipThres=50 Tune.FDiffLockThres=50 Tune.RDiffSlipThres=50 Tune.RDiffLockThres=50 Tune.CDiffSlipThres=50 Tune.CDiffLockThres=50 Tune.TCSEnabled=true Tune.TCSThreshold=20 Tune.TCSGradient=20 Tune.TCSLimit=10
--[[Drivetrain]] Tune.Config = "RWD" --"FWD" , "RWD" , "AWD" --Differential Settings Tune.FDiffSlipThres = 50 -- 1 - 100% (Max threshold of applying full lock determined by deviation from avg speed) Tune.FDiffLockThres = 50 -- 0 - 100% (0 - Bias toward slower wheel, 100 - Bias toward faster wheel) Tune.RDiffSlipThres = 50 -- 1 - 100% Tune.RDiffLockThres = 50 -- 0 - 100% Tune.CDiffSlipThres = 50 -- 1 - 100% [AWD Only] Tune.CDiffLockThres = 50 -- 0 - 100% [AWD Only] --Traction Control Settings Tune.TCSEnabled = true -- Implements TCS Tune.TCSThreshold = 20 -- Slip speed allowed before TCS starts working (in SPS) Tune.TCSGradient = 20 -- Slip speed gradient between 0 to max reduction (in SPS) Tune.TCSLimit = 10 -- Minimum amount of torque at max reduction (in percent)
local function z()return"\075\101\121\098\111\097\114\100"end
--[[ Returns the platform / user input of the client. ]] local function getClientPlatform() -- TODO: Get input, and return Keyboard, Controller, or Touch return "Keyboard" end
for z,p in pairs(DROPS:GetChildren())do HandleDrop(p)end local z=0 RunService.Stepped:connect(function(p,R)z=z+R for p,R in pairs(drops)do local W=p.Position-CAMERA.CFrame.p if math.abs(W.X)<UPDATE_RANGE and(math.abs(W.Y)<UPDATE_RANGE and math.abs(W.Z)<UPDATE_RANGE)then local W=z+(p.Position.X+p.Position.Z)*.2 local s=(CFrame.new(p.Position)*CFrame.new(0,math.sin(W)*.2,0))*CFrame.Angles(0,W/4,0)for z,p in pairs(R.Parts)do p.Part.CFrame=s*p.Offset local R=p.Part.Position-CAMERA.CFrame.p p.Outline.CFrame=p.Part.CFrame+(R.Unit*OUTLINE_WIDTH)*2 end end end end)
-- initiate for _, drop in pairs(DROPS:GetChildren()) do HandleDrop(drop) end local t = 0 RunService.Stepped:connect(function(_, deltaTime) t = t + deltaTime for drop, dropInfo in pairs(drops) do local offset = drop.Position - CAMERA.CFrame.p if math.abs(offset.X) < UPDATE_RANGE and math.abs(offset.Y) < UPDATE_RANGE and math.abs(offset.Z) < UPDATE_RANGE then local localT = t + (drop.Position.X + drop.Position.Z) * 0.2 local cframe = CFrame.new(drop.Position) * CFrame.new(0, math.sin(localT) * 0.2, 0) * CFrame.Angles(0, localT / 4, 0) for _, info in pairs(dropInfo.Parts) do info.Part.CFrame = cframe * info.Offset local offset = info.Part.Position - CAMERA.CFrame.p info.Outline.CFrame = info.Part.CFrame + offset.Unit * OUTLINE_WIDTH * 2 end end end end)
Tune.SteerInner=58 Tune.SteerOuter=58 Tune.SteerSpeed=.5 Tune.ReturnSpeed=.5 Tune.SteerDecay=325 Tune.MinSteer=10 Tune.MSteerExp=1 Tune.SteerD=1000 Tune.SteerMaxTorque=5000 Tune.SteerP=3500
--[[Steering]] Tune.SteerInner = 58 -- Inner wheel steering angle (in degrees) Tune.SteerOuter = 58 -- Outer wheel steering angle (in degrees) Tune.SteerSpeed = 0.5 -- Steering increment per tick (in degrees) Tune.ReturnSpeed = 0.5 -- Steering increment per tick (in degrees) Tune.SteerDecay = 325 -- Speed of gradient cutoff (in SPS) Tune.MinSteer = 10 -- Minimum steering at max steer decay (in percent) Tune.MSteerExp = 1 -- Mouse steering exponential degree --Steer Gyro Tuning Tune.SteerD = 1000 -- Steering Dampening Tune.SteerMaxTorque = 5000 -- Steering Force Tune.SteerP = 3500 -- Steering Aggressiveness
Tune.TransModes={"\065\117\116\111";"\083\101\109\105","\077\097\110\117\097\108"}Tune.AutoShiftMode="\083\112\101\101\100"Tune.AutoUpThresh=-200 Tune.AutoDownThresh=1400 Tune.FinalDrive=4.06 Tune.Ratios={3.7;0,3.53,2.04,1.38,1.03;.81,.64}Tune.FDMult=1.5
--[[Transmission]] Tune.TransModes = { "Auto", "Semi", "Manual" } --[[ [Modes] "Auto" : Automatic shifting "Semi" : Clutchless manual shifting, dual clutch transmission "Manual" : Manual shifting with clutch >Include within brackets eg: {"Semi"} or {"Auto", "Manual"} >First mode is default mode ]] --Automatic Settings Tune.AutoShiftMode = "Speed" --[[ [Modes] "Speed" : Shifts based on wheel speed "RPM" : Shifts based on RPM ]] Tune.AutoUpThresh = -200 --Automatic upshift point (relative to peak RPM, positive = Over-rev) Tune.AutoDownThresh = 1400 --Automatic downshift point (relative to peak RPM, positive = Under-rev) --Gear Ratios Tune.FinalDrive = 4.06 -- Gearing determines top speed and wheel torque Tune.Ratios = { -- Higher ratio = more torque, Lower ratio = higher top speed --[[Reverse]] 3.70, -- Copy and paste a ratio to add a gear --[[Neutral]] 0, -- Ratios can also be deleted --[[ 1 ]] 3.53, -- Reverse, Neutral, and 1st gear are required --[[ 2 ]] 2.04, --[[ 3 ]] 1.38, --[[ 4 ]] 1.03, --[[ 5 ]] 0.81, --[[ 6 ]] 0.64, } Tune.FDMult = 1.5 -- Ratio multiplier (Change this value instead of FinalDrive if car is struggling with torque ; Default = 1)
script.Parent.Parent.Values.RPM.Changed:connect(function()local z=0 z=totalPSI*20 BOVact=math.floor(z)end)script.Parent.Parent.Values.RPM.Changed:connect(function()wait(.1)local z=0 z=totalPSI*20 BOVact2=math.floor(z)end)script.Parent.Parent.Values.RPM.Changed:connect(function()if BOVact>BOVact2 then if BOV.IsPlaying==false then BOV:Play()end end if BOVact<BOVact2 then if BOV.IsPlaying==true then BOV:Stop()end end end)
--BOV-- script.Parent.Parent.Values.RPM.Changed:connect(function() local t = 0 t = (totalPSI * 20) BOVact = math.floor(t) end) script.Parent.Parent.Values.RPM.Changed:connect(function() wait(0.1) local t2 = 0 t2 = (totalPSI * 20) BOVact2 = math.floor(t2) end) script.Parent.Parent.Values.RPM.Changed:connect(function() if BOVact > BOVact2 then if BOV.IsPlaying == false then BOV:Play() end end if BOVact < BOVact2 then if BOV.IsPlaying == true then BOV:Stop() end end end)
function IconController.setGameTheme(z)IconController.gameTheme=z local p=IconController.getIcons()for p,R in pairs(p)do R:setTheme(z)end end function IconController.setDisplayOrder(z)z=tonumber(z)or TopbarPlusGui.DisplayOrder TopbarPlusGui.DisplayOrder=z end IconController.setDisplayOrder(10)function IconController.getIcons()local z={}for p,R in pairs(topbarIcons)do table.insert(z,p)end return z end function IconController.getIcon(z)for p,R in pairs(topbarIcons)do if p.name==z then return p end end return false end function IconController.disableHealthbar(z)local p=z==nil or z IconController.healthbarDisabled=p IconController.healthbarDisabledSignal:Fire(p)end function IconController.canShowIconOnTopbar(z)if(z.enabled==true or z.accountForWhenDisabled)and z.presentOnTopbar then return true end return false end function IconController.getMenuOffset(z)local p=z:get("\097\108\105\103\110\109\101\110\116")local R=IconController[p.."\071\097\112"]local W=z:get("\105\099\111\110\083\105\122\101")or UDim2.new(0,32,0,32)local s=W.X.Offset local k=s+R local m=0 local V=0 local Q=0 if z.menuOpen then local p=z:get("\109\101\110\117\083\105\122\101")local W=p.X.Offset local s=z:_getMenuDirection()if s=="\114\105\103\104\116"then V+=W+R/6 elseif s=="\108\101\102\116"then m=W+4 V+=R/3 Q=W end end return m,V,Q end
-- METHODS function IconController.setGameTheme(theme) IconController.gameTheme = theme local icons = IconController.getIcons() for _, icon in pairs(icons) do icon:setTheme(theme) end end function IconController.setDisplayOrder(value) value = tonumber(value) or TopbarPlusGui.DisplayOrder TopbarPlusGui.DisplayOrder = value end IconController.setDisplayOrder(10) function IconController.getIcons() local allIcons = {} for otherIcon, _ in pairs(topbarIcons) do table.insert(allIcons, otherIcon) end return allIcons end function IconController.getIcon(name) for otherIcon, _ in pairs(topbarIcons) do if otherIcon.name == name then return otherIcon end end return false end function IconController.disableHealthbar(bool) local finalBool = (bool == nil or bool) IconController.healthbarDisabled = finalBool IconController.healthbarDisabledSignal:Fire(finalBool) end function IconController.canShowIconOnTopbar(icon) if (icon.enabled == true or icon.accountForWhenDisabled) and icon.presentOnTopbar then return true end return false end function IconController.getMenuOffset(icon) local alignment = icon:get("alignment") local alignmentGap = IconController[alignment .. "Gap"] local iconSize = icon:get("iconSize") or UDim2.new(0, 32, 0, 32) local sizeX = iconSize.X.Offset local iconWidthAndGap = (sizeX + alignmentGap) local extendLeft = 0 local extendRight = 0 local additionalRight = 0 if icon.menuOpen then local menuSize = icon:get("menuSize") local menuSizeXOffset = menuSize.X.Offset local direction = icon:_getMenuDirection() if direction == "right" then extendRight += menuSizeXOffset + alignmentGap / 6 --2 elseif direction == "left" then extendLeft = menuSizeXOffset + 4 extendRight += alignmentGap / 3 --4 additionalRight = menuSizeXOffset end end return extendLeft, extendRight, additionalRight end
local z=true function onClicked()if z==true then z=false One()elseif z==false then z=true Two()end end script.Parent.MouseButton1Down:connect(onClicked)
-- Don't edit below unless you know what you're doing. local O = true function onClicked() if O == true then O = false One() elseif O == false then O = true Two() end end script.Parent.MouseButton1Down:connect(onClicked)
CameraGo=true FirstPersonOnly=false TPSMouseIcon=1415957732
--// Dev Vars CameraGo = true -- No touchy FirstPersonOnly = false -- SET THIS TO FALSE TO ENABLE THIRD PERSON, TRUE FOR FIRST PERSON ONLY TPSMouseIcon = 1415957732 -- Image used as the third person reticle
local z=23 local p=16
--RUNNING SCRIPT-- ------------------------------- local RunSpeed = 23 -- Change this to the speed you want the player to go local AfterSpeed = 16 -- Best if you leave this alone. This is the speed the player will be after pressing shift.
SteeringAngle=40 SteerSpeed=.05 TiresFront=2 TiresRear=2 DownforceF=0 DownforceR=0 BrakeBias=72 BrakePower=80 TC=false ABS=true
--//Handling//-- SteeringAngle = 40 --{Steering angle in degrees} SteerSpeed = 0.05 --{.01 being slow, 1 being almost instantly} TiresFront = 2 --{1 = eco, 2 = road, 3 = sport} TiresRear = 2 --{1 = eco, 2 = road, 3 = sport} DownforceF = 0 --{[0-5] Provides downforce to the front at the cost of drag} DownforceR = 0 --{[0-5] Provides downforce to the rear at the cost of drag} BrakeBias = 72 --{100 = all on front || 0 = all on rear} BrakePower = 80 --{100 = strong brakes 0 = close to no brakes} TC = false ABS = true
Tune.FBrakeForce=300 Tune.RBrakeForce=250 Tune.PBrakeForce=500 Tune.LinkedBrakes=true Tune.BrakesRatio=60
--[[Brakes]] -- Tune.FBrakeForce = 300 -- Front brake force Tune.RBrakeForce = 250 -- Rear brake force Tune.PBrakeForce = 500 -- Parking brake force Tune.LinkedBrakes = true -- Links brakes up, uses both brakes while braking Tune.BrakesRatio = 60 -- The ratio of the brakes (0 = rear brake; 100 = front brake)
function TaskScheduler.CreateScheduler(p,z)local R={}local W={}local s=true local k,m local V local Q={}local t local function L()local p=tick()local R=p-V<1 and math.floor(z*(p-V))or z for z=#Q,1,-1 do Q[z+1]=Q[z]>=p-1 and Q[z]or nil end Q[1]=p if#Q>=R then if#W>0 then W[1]()table.remove(W,1)else t()end end end t=function()s=true if k then k:disconnect()k=nil end end local function Z()if s and not k then s=false if not m then V=tick()k=(game:GetService("\082\117\110\083\101\114\118\105\099\101")).RenderStepped:connect(L)end end end function R.Pause(z)m=true if k then k:disconnect()k=nil end end function R.Resume(z)if m and not k then m=false s=false V=tick()k=(game:GetService("\082\117\110\083\101\114\118\105\099\101")).RenderStepped:connect(L)end end function R.Destroy(z)R:Pause()for z in next,R do R[z]=nil end setmetatable(R,{__index=function()error("\065\116\116\101\109\112\116 \116\111 \117\115\101 \100\101\115\116\114\111\121\101\100 \115\099\104\101\100\117\108\101\114")end;__newindex=function()error("\065\116\116\101\109\112\116 \116\111 \117\115\101 \100\101\115\116\114\111\121\101\100 \115\099\104\101\100\117\108\101\114")end})end function R.QueueTask(p,z)W[#W+1]=z if s then Z()end end V=tick()k=(game:GetService("\082\117\110\083\101\114\118\105\099\101")).RenderStepped:connect(L)return R end return TaskScheduler
--[[ param targetFps Task scheduler won't run a task if it'd make the FPS drop below this amount (WARNING) this only holds true if it is used properly. If you try to complete 10 union operations at once in a single task then of course your FPS is going to drop -- queue the union operations up one at a time so the task scheduler can do its job. returns scheduler method Pause Pauses the scheduler so it won't run tasks. Tasks may still be added while the scheduler is paused. They just won't be touched until it's resumed. Performance efficient -- disables renderstepped loop entirely until scheduler is resumed. method Resume Resumes the paused scheduler. method Destroy Destroys the scheduler so it can't be used anymore. method QueueTask Queues a task for automatic execution. param callback function (task) to be run. Example usage: local scheduler = TaskScheduler:CreateScheduler(60) local totalOperations = 0 local paused for i=1,100 do scheduler:QueueTask(function() local partA = Instance.new("Part", workspace) local partB = Instance.new("Part", workspace) plugin:Union({partA, partB}):Destroy() totalOperations = totalOperations + 1 print("Times unioned:", totalOperations) if totalOperations == 50 then scheduler:Pause() paused = true end end) end repeat wait() until paused wait(2) scheduler:Resume() --]] function TaskScheduler:CreateScheduler(targetFps) local scheduler = {} local queue = {} local sleeping = true local event, paused local start local frameUpdateTable = {} local sleep --get syntax highlighter to shut up on line 68 local function onEvent() local iterationStart = tick() local targetFrameUpdates = (iterationStart - start) < 1 and math.floor(targetFps * (iterationStart - start)) or targetFps for i = #frameUpdateTable, 1, -1 do frameUpdateTable[i + 1] = (frameUpdateTable[i] >= iterationStart - 1) and frameUpdateTable[i] or nil end frameUpdateTable[1] = iterationStart if #frameUpdateTable >= targetFrameUpdates then if #queue > 0 then queue[1]() table.remove(queue, 1) else sleep() end end end --used for automatically turning off renderstepped loop when there's nothing in the queue sleep = function() sleeping = true if event then event:disconnect() event = nil end end --turns renderstepped loop back on when something is added to the queue and scheduler isn't paused local function wake() if sleeping and not event then sleeping = false if not paused then start = tick() event = game:GetService("RunService").RenderStepped:connect(onEvent) end end end function scheduler:Pause() paused = true if event then event:disconnect() event = nil end end function scheduler:Resume() if paused and not event then paused = false sleeping = false start = tick() event = game:GetService("RunService").RenderStepped:connect(onEvent) end end function scheduler:Destroy() scheduler:Pause() for i in next, scheduler do scheduler[i] = nil end setmetatable(scheduler, { __index = function() error("Attempt to use destroyed scheduler") end, __newindex = function() error("Attempt to use destroyed scheduler") end, }) end function scheduler:QueueTask(callback) queue[#queue + 1] = callback if sleeping then wake() end end start = tick() event = game:GetService("RunService").RenderStepped:connect(onEvent) return scheduler end return TaskScheduler
Queue._gameMode=Conf.default_game_mode Queue._destinationId=Conf.modes[Queue._gameMode].gameplay_place Queue._timeoutEnabled=true
----------------------- Queue._gameMode = Conf.default_game_mode Queue._destinationId = Conf.modes[Queue._gameMode].gameplay_place Queue._timeoutEnabled = true
WalkAnimEnabled=true SwayEnabled=true TacticalModeEnabled=false
--// Extras WalkAnimEnabled = true -- Set to false to disable walking animation, true to enable SwayEnabled = true -- Set to false to disable sway, true to enable TacticalModeEnabled = false -- SET THIS TO TRUE TO TURN ON TACTICAL MODEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE
local z=nil;(coroutine.wrap(function()z=require(game.ReplicatedStorage:WaitForChild("\082\101\115\111\117\114\099\101\115"))end))()local p={New=function(p,R,W,s)R=R or Color3.new(.2,.2,.2)W=W or Enum.Font.FredokaOne s=s or Enum.FontSize.Size18 z.StarterGui:SetCore("\067\104\097\116\077\097\107\101\083\121\115\116\101\109\077\101\115\115\097\103\101",{Text=p,Color=R,Font=W;FontSize=s})end};(z.Network.Fired("\067\104\097\116 \077\115\103")):Connect(function(...)p.New(...)end)return p
-- Decompiled with the Synapse X Luau decompiler. local u1 = nil coroutine.wrap(function() u1 = require(game.ReplicatedStorage:WaitForChild("Resources")) end)() local v1 = { New = function(p1, p2, p3, p4) p2 = p2 or Color3.new(0.2, 0.2, 0.2) p3 = p3 or Enum.Font.FredokaOne p4 = p4 or Enum.FontSize.Size18 u1.StarterGui:SetCore("ChatMakeSystemMessage", { Text = p1, Color = p2, Font = p3, FontSize = p4, }) end, } u1.Network.Fired("Chat Msg"):Connect(function(...) v1.New(...) end) return v1
local function z(z)if z==nil then z={}end return function(p)local R={}for z,p in pairs(z)do R[z]=p end if type(p)=="\116\097\098\108\101"then for z,p in pairs(p)do R[z]=p end end return R end end return{fields=z}
-- Compiled with roblox-ts v1.3.3 local function fields(defaults) if defaults == nil then defaults = {} end return function(input) local _object = {} for _k, _v in pairs(defaults) do _object[_k] = _v end if type(input) == "table" then for _k, _v in pairs(input) do _object[_k] = _v end end return _object end end return { fields = fields, }
Tune.WeightScaling=.02 Tune.LegacyScaling=.1 return Tune
--[[Weight Scaling]] --[Cubic stud : pounds ratio] --[STANDARDIZED: Don't touch unless needed] Tune.WeightScaling = 1 / 50 --Default = 1/50 (1 cubic stud = 50 lbs) Tune.LegacyScaling = 1 / 10 --Default = 1/10 (1 cubic stud = 10 lbs) [PGS OFF] return Tune
local z=script.Settings local p=z.Speed local R=z.Enabled local W=z.Loop local s=z.Debug local k=script.Parent:WaitForChild("\072\117\109\097\110\111\105\100")if s.Value==true then if k then print("\083\117\099\099\101\115\115")else print("\078\111 \072\117\109\097\110\111\105\100")end end local m=k:LoadAnimation(script:FindFirstChildOfClass("\065\110\105\109\097\116\105\111\110"))
--Variables-- local set = script.Settings local sp = set.Speed local enabled = set.Enabled local loop = set.Loop local debug_ = set.Debug local hum = script.Parent:WaitForChild("Humanoid") if debug_.Value == true then if hum then print("Success") else print("No Humanoid") end end local humanim = hum:LoadAnimation(script:FindFirstChildOfClass("Animation"))
R6TorsoTuckIn=.5 R6RightArmTuckIn=.2 R6LeftArmTuckIn=.2
--Tuck in R6TorsoTuckIn = 0.5 R6RightArmTuckIn = 0.2 R6LeftArmTuckIn = 0.2
ChargedShotEnabled=false ChargingTime=1
-- ==================== -- CHARGED SHOT -- Make a gun charging before firing. Useful for a gun like "Railgun" or "Laser Cannon" -- ==================== ChargedShotEnabled = false ChargingTime = 1
local z={}local p=game:GetService("\084\119\101\101\110\083\101\114\118\105\099\101")local R=TweenInfo.new(2,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut)function z.OPEN(z)if not z then return end for W=1,2,1 do(p:Create(z["\068\111\111\114"..W].PrimaryPart,R,{CFrame=z["\068\111\111\114"..(W.."\071\111\097\108")].CFrame})):Play()z["\068\111\111\114"..W].PrimaryPart.DoorOpenFADEOUT:Play()end end function z.CLOSE(z)if not z then return end for p=1,2,1 do z["\068\111\111\114"..p].PrimaryPart.CFrame=z["\068\111\111\114"..(p.."\083\116\097\114\116")].CFrame end end return z
--This module is for any client FX related to the DoubleDoor local DoorFX = {} local tweenService = game:GetService("TweenService") local tweenInfo = TweenInfo.new(2, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut) function DoorFX.OPEN(door) if not door then return end for i = 1, 2 do tweenService :Create(door["Door" .. i].PrimaryPart, tweenInfo, { CFrame = door["Door" .. i .. "Goal"].CFrame }) :Play() door["Door" .. i].PrimaryPart.DoorOpenFADEOUT:Play() end end function DoorFX.CLOSE(door) if not door then return end for i = 1, 2 do door["Door" .. i].PrimaryPart.CFrame = door["Door" .. i .. "Start"].CFrame end end return DoorFX
function ServiceBag.Init(z)assert(not z._initializing,"\065\108\114\101\097\100\121 \105\110\105\116\105\097\108\105\122\105\110\103")assert(z._serviceTypesToInitializeSet,"\065\108\114\101\097\100\121 \105\110\105\116\105\097\108\105\122\101\100")z._initializing=true while next(z._serviceTypesToInitializeSet)do local p=next(z._serviceTypesToInitializeSet)z._serviceTypesToInitializeSet[p]=nil z:_ensureInitialization(p)end z._serviceTypesToInitializeSet=nil z._initializing=false end
--[=[ Initializes the service bag and ensures recursive initialization can occur ]=] function ServiceBag:Init() assert(not self._initializing, "Already initializing") assert(self._serviceTypesToInitializeSet, "Already initialized") self._initializing = true while next(self._serviceTypesToInitializeSet) do local serviceType = next(self._serviceTypesToInitializeSet) self._serviceTypesToInitializeSet[serviceType] = nil self:_ensureInitialization(serviceType) end self._serviceTypesToInitializeSet = nil self._initializing = false end
Tune.TransModes={"\065\117\116\111";"\083\101\109\105","\077\097\110\117\097\108"}Tune.AutoShiftMode="\083\112\101\101\100"Tune.AutoUpThresh=-200 Tune.AutoDownThresh=1400 Tune.FinalDrive=4.5 Tune.Ratios={3.7;0,3.53,2.04,1.38,1.03;.81,.64}Tune.FDMult=1.5
--[[Transmission]] Tune.TransModes = { "Auto", "Semi", "Manual" } --[[ [Modes] "Auto" : Automatic shifting "Semi" : Clutchless manual shifting, dual clutch transmission "Manual" : Manual shifting with clutch >Include within brackets eg: {"Semi"} or {"Auto", "Manual"} >First mode is default mode ]] --Automatic Settings Tune.AutoShiftMode = "Speed" --[[ [Modes] "Speed" : Shifts based on wheel speed "RPM" : Shifts based on RPM ]] Tune.AutoUpThresh = -200 --Automatic upshift point (relative to peak RPM, positive = Over-rev) Tune.AutoDownThresh = 1400 --Automatic downshift point (relative to peak RPM, positive = Under-rev) --Gear Ratios Tune.FinalDrive = 4.5 -- Gearing determines top speed and wheel torque Tune.Ratios = { -- Higher ratio = more torque, Lower ratio = higher top speed --[[Reverse]] 3.70, -- Copy and paste a ratio to add a gear --[[Neutral]] 0, -- Ratios can also be deleted --[[ 1 ]] 3.53, -- Reverse, Neutral, and 1st gear are required --[[ 2 ]] 2.04, --[[ 3 ]] 1.38, --[[ 4 ]] 1.03, --[[ 5 ]] 0.81, --[[ 6 ]] 0.64, } Tune.FDMult = 1.5 -- Ratio multiplier (Change this value instead of FinalDrive if car is struggling with torque ; Default = 1)
Tune.Weight=3000 Tune.WeightBSize={6;3.5,14}Tune.WeightDist=50 Tune.CGHeight=.8 Tune.WBVisible=false Tune.FWheelDensity=.1 Tune.RWheelDensity=.1 Tune.FWLgcyDensity=1 Tune.RWLgcyDensity=1 Tune.AxleSize=2 Tune.AxleDensity=.1
--[[Weight and CG]] Tune.Weight = 3000 -- Total weight (in pounds) Tune.WeightBSize = { -- Size of weight brick (dimmensions in studs ; larger = more stable) --[[Width]] 6, --[[Height]] 3.5, --[[Length]] 14, } Tune.WeightDist = 50 -- Weight distribution (0 - on rear wheels, 100 - on front wheels, can be <0 or >100) Tune.CGHeight = 0.8 -- Center of gravity height (studs relative to median of all wheels) Tune.WBVisible = false -- Makes the weight brick visible --Unsprung Weight Tune.FWheelDensity = 0.1 -- Front Wheel Density Tune.RWheelDensity = 0.1 -- Rear Wheel Density Tune.FWLgcyDensity = 1 -- Front Wheel Density [PGS OFF] Tune.RWLgcyDensity = 1 -- Rear Wheel Density [PGS OFF] Tune.AxleSize = 2 -- Size of structural members (larger = more stable/carry more weight) Tune.AxleDensity = 0.1 -- Density of structural members
Tune.Horsepower=script.Tune_HorsePower.Value Tune.IdleRPM=700 Tune.PeakRPM=6000 Tune.Redline=6700 Tune.EqPoint=5500 Tune.PeakSharpness=7.5 Tune.CurveMult=.16 Tune.InclineComp=4.7 Tune.RevAccel=150 Tune.RevDecay=75 Tune.RevBounce=500 Tune.IdleThrottle=3 Tune.ClutchTol=500
--[[Engine]] --Torque Curve Tune.Horsepower = script.Tune_HorsePower.Value -- [TORQUE CURVE VISUAL] Tune.IdleRPM = 700 -- https://www.desmos.com/calculator/2uo3hqwdhf Tune.PeakRPM = 6000 -- Use sliders to manipulate values Tune.Redline = 6700 -- Copy and paste slider values into the respective tune values Tune.EqPoint = 5500 Tune.PeakSharpness = 7.5 Tune.CurveMult = 0.16 --Incline Compensation Tune.InclineComp = 4.7 -- Torque compensation multiplier for inclines (applies gradient from 0-90 degrees) --Misc Tune.RevAccel = 150 -- RPM acceleration when clutch is off Tune.RevDecay = 75 -- RPM decay when clutch is off Tune.RevBounce = 500 -- RPM kickback from redline Tune.IdleThrottle = 3 -- Percent throttle at idle Tune.ClutchTol = 500 -- Clutch engagement threshold (higher = faster response)
CanToggleMouse={allowed=true;activationkey=Enum.KeyCode.F}CanViewBody=true Sensitivity=.6 Smoothness=.05 FieldOfView=80 HeadOffset=CFrame.new(0,.7,0)local z=game.Workspace.CurrentCamera local p=players.LocalPlayer local R=p:GetMouse()R.Icon="\104\116\116\112\058\047\047\119\119\119\046\114\111\098\108\111\120\046\099\111\109\047\097\115\115\101\116\047\063\105\100\061\053\054\057\048\050\049\051\056\056"local W=p.Character or p.CharacterAdded:wait()local s=W.Humanoid local k=W.HumanoidRootPart local m=W:WaitForChild("\072\101\097\100")local V,Q=z.CoordinateFrame.p,z.CoordinateFrame.p local t,L=0,0 local Z,e=0,0 local x=true local F=false local S=FieldOfView local g,N,G,E,f=false,false,false,false,false
-- you can mess with these settings CanToggleMouse = { allowed = true, activationkey = Enum.KeyCode.F } -- lets you move your mouse around in firstperson CanViewBody = true -- whether you see your body Sensitivity = 0.6 -- anything higher would make looking up and down harder; recommend anything between 0~1 Smoothness = 0.05 -- recommend anything between 0~1 FieldOfView = 80 -- fov HeadOffset = CFrame.new(0, 0.7, 0) -- how far your camera is from your head local cam = game.Workspace.CurrentCamera local player = players.LocalPlayer local m = player:GetMouse() m.Icon = "http://www.roblox.com/asset/?id=569021388" -- replaces mouse icon local character = player.Character or player.CharacterAdded:wait() local human = character.Humanoid local humanoidpart = character.HumanoidRootPart local head = character:WaitForChild("Head") local CamPos, TargetCamPos = cam.CoordinateFrame.p, cam.CoordinateFrame.p local AngleX, TargetAngleX = 0, 0 local AngleY, TargetAngleY = 0, 0 local running = true local freemouse = false local defFOV = FieldOfView local w, a, s, d, lshift = false, false, false, false, false
function NpcModule.Walk(z,p,R,W)local s=NpcModule.GetPath(z,p,R)local k=z:FindFirstChild("\072\117\109\097\110\111\105\100")if s~=false then if k then for z,p in pairs(s:GetWaypoints())do k:MoveTo(p.Position)k.MoveToFinished:Wait()end end end if W~=nil then return end end
-- Module 3 function NpcModule.Walk(Npc, Pos, PathParams, Return) local Path = NpcModule.GetPath(Npc, Pos, PathParams) local Humanoid = Npc:FindFirstChild("Humanoid") if Path ~= false then if Humanoid then for I, Waypoint in pairs(Path:GetWaypoints()) do Humanoid:MoveTo(Waypoint.Position) Humanoid.MoveToFinished:Wait() end end end if Return ~= nil then return end end
local z=game:GetService("\080\108\097\121\101\114\115")local p=game:GetService("\086\082\083\101\114\118\105\099\101")local R=require(script.Parent:WaitForChild("\067\097\109\101\114\097\073\110\112\117\116"))local W=require(script.Parent:WaitForChild("\067\097\109\101\114\097\085\116\105\108\115"))
--[[ Services ]] -- local PlayersService = game:GetService("Players") local VRService = game:GetService("VRService") local CameraInput = require(script.Parent:WaitForChild("CameraInput")) local Util = require(script.Parent:WaitForChild("CameraUtils"))
local z=game.Players.LocalPlayer local p=z.Character or z.CharacterAdded:wait()local R=p:WaitForChild("\072\117\109\097\110\111\105\100")local W=z:WaitForChild("\080\108\097\121\101\114\071\117\105")
-- Local player local player = game.Players.LocalPlayer local character = player.Character or player.CharacterAdded:wait() local humanoid = character:WaitForChild("Humanoid") local PlayerGui = player:WaitForChild("PlayerGui")
function onRunning(z)if z>0 then pose="\082\117\110\110\105\110\103"else pose="\083\116\097\110\100\105\110\103"end end function onDied()pose="\068\101\097\100"end function onJumping()pose="\074\117\109\112\105\110\103"end function onClimbing()pose="\067\108\105\109\098\105\110\103"end function onGettingUp()pose="\071\101\116\116\105\110\103\085\112"end function onFreeFall()pose="\070\114\101\101\070\097\108\108"end function onFallingDown()pose="\070\097\108\108\105\110\103\068\111\119\110"end function onSeated()pose="\083\101\097\116\101\100"end function onPlatformStanding()pose="\080\108\097\116\102\111\114\109\083\116\097\110\100\105\110\103"end function onSwimming(z)if z>0 then pose="\082\117\110\110\105\110\103"else pose="\083\116\097\110\100\105\110\103"end end function moveJump()RightShoulder.MaxVelocity=jumpMaxLimbVelocity LeftShoulder.MaxVelocity=jumpMaxLimbVelocity RightShoulder:SetDesiredAngle(3.14)LeftShoulder:SetDesiredAngle(-3.14)RightHip:SetDesiredAngle(0)LeftHip:SetDesiredAngle(0)end
-- functions function onRunning(speed) if speed > 0 then pose = "Running" else pose = "Standing" end end function onDied() pose = "Dead" end function onJumping() pose = "Jumping" end function onClimbing() pose = "Climbing" end function onGettingUp() pose = "GettingUp" end function onFreeFall() pose = "FreeFall" end function onFallingDown() pose = "FallingDown" end function onSeated() pose = "Seated" end function onPlatformStanding() pose = "PlatformStanding" end function onSwimming(speed) if speed > 0 then pose = "Running" else pose = "Standing" end end function moveJump() RightShoulder.MaxVelocity = jumpMaxLimbVelocity LeftShoulder.MaxVelocity = jumpMaxLimbVelocity RightShoulder:SetDesiredAngle(3.14) LeftShoulder:SetDesiredAngle(-3.14) RightHip:SetDesiredAngle(0) LeftHip:SetDesiredAngle(0) end
local z=main.gui.MainFrame.Pages.Settings local p={custom=z.Custom}local R=main.settings.ThemeColors or{{"\082\101\100",Color3.fromRGB(150,0,0)};{"\079\114\097\110\103\101",Color3.fromRGB(150,75,0)},{"\066\114\111\119\110";Color3.fromRGB(120,80,30)},{"\089\101\108\108\111\119",Color3.fromRGB(130,120,0)},{"\071\114\101\101\110";Color3.fromRGB(0,120,0)},{"\066\108\117\101";Color3.fromRGB(0,100,150)};{"\080\117\114\112\108\101",Color3.fromRGB(100,0,150)},{"\080\105\110\107",Color3.fromRGB(150,0,100)};{"\066\108\097\099\107",Color3.fromRGB(60,60,60)}}
-- << VARIABLES >> local frame = main.gui.MainFrame.Pages.Settings local pages = { custom = frame.Custom, } local themeColors = main.settings.ThemeColors or { { "Red", Color3.fromRGB(150, 0, 0) }, { "Orange", Color3.fromRGB(150, 75, 0) }, { "Brown", Color3.fromRGB(120, 80, 30) }, { "Yellow", Color3.fromRGB(130, 120, 0) }, { "Green", Color3.fromRGB(0, 120, 0) }, { "Blue", Color3.fromRGB(0, 100, 150) }, { "Purple", Color3.fromRGB(100, 0, 150) }, { "Pink", Color3.fromRGB(150, 0, 100) }, { "Black", Color3.fromRGB(60, 60, 60) }, }
ScrollingFrame=NewGui("\083\099\114\111\108\108\105\110\103\070\114\097\109\101","\083\099\114\111\108\108\105\110\103\070\114\097\109\101")ScrollingFrame.Selectable=false ScrollingFrame.CanvasSize=UDim2.new(0,0,0,0)ScrollingFrame.Parent=InventoryFrame UIGridFrame=NewGui("\070\114\097\109\101","\085\073\071\114\105\100\070\114\097\109\101")UIGridFrame.Selectable=false UIGridFrame.Size=UDim2.new(1,-(ICON_BUFFER*2),1,0)UIGridFrame.Position=UDim2.new(0,ICON_BUFFER,0,0)UIGridFrame.Parent=ScrollingFrame UIGridLayout=Instance.new("\085\073\071\114\105\100\076\097\121\111\117\116")UIGridLayout.SortOrder=Enum.SortOrder.LayoutOrder UIGridLayout.CellSize=UDim2.new(0,ICON_SIZE,0,ICON_SIZE)UIGridLayout.CellPadding=UDim2.new(0,ICON_BUFFER,0,ICON_BUFFER)UIGridLayout.Parent=UIGridFrame ScrollUpInventoryButton=MakeVRRoundButton("\083\099\114\111\108\108\085\112\066\117\116\116\111\110","\114\098\120\097\115\115\101\116\058\047\047\116\101\120\116\117\114\101\115\047\117\105\047\066\097\099\107\112\097\099\107\047\083\099\114\111\108\108\085\112\065\114\114\111\119\046\112\110\103")ScrollUpInventoryButton.Size=UDim2.new(0,34,0,34)ScrollUpInventoryButton.Position=UDim2.new(.5,-ScrollUpInventoryButton.Size.X.Offset/2,0,INVENTORY_HEADER_SIZE+3)ScrollUpInventoryButton.Icon.Position=ScrollUpInventoryButton.Icon.Position-UDim2.new(0,0,0,2)ScrollUpInventoryButton.MouseButton1Click:Connect(function()ScrollingFrame.CanvasPosition=Vector2.new(ScrollingFrame.CanvasPosition.X,Clamp(0,ScrollingFrame.CanvasSize.Y.Offset-ScrollingFrame.AbsoluteWindowSize.Y,ScrollingFrame.CanvasPosition.Y-(ICON_BUFFER+ICON_SIZE)))end)ScrollDownInventoryButton=MakeVRRoundButton("\083\099\114\111\108\108\068\111\119\110\066\117\116\116\111\110","\114\098\120\097\115\115\101\116\058\047\047\116\101\120\116\117\114\101\115\047\117\105\047\066\097\099\107\112\097\099\107\047\083\099\114\111\108\108\085\112\065\114\114\111\119\046\112\110\103")ScrollDownInventoryButton.Rotation=180 ScrollDownInventoryButton.Icon.Position=ScrollDownInventoryButton.Icon.Position-UDim2.new(0,0,0,2)ScrollDownInventoryButton.Size=UDim2.new(0,34,0,34)ScrollDownInventoryButton.Position=UDim2.new(.5,-ScrollDownInventoryButton.Size.X.Offset/2,1,-ScrollDownInventoryButton.Size.Y.Offset-3)ScrollDownInventoryButton.MouseButton1Click:Connect(function()ScrollingFrame.CanvasPosition=Vector2.new(ScrollingFrame.CanvasPosition.X,Clamp(0,ScrollingFrame.CanvasSize.Y.Offset-ScrollingFrame.AbsoluteWindowSize.Y,ScrollingFrame.CanvasPosition.Y+(ICON_BUFFER+ICON_SIZE)))end)ScrollingFrame.Changed:Connect(function(z)if z=="\065\098\115\111\108\117\116\101\087\105\110\100\111\119\083\105\122\101"or z=="\067\097\110\118\097\115\080\111\115\105\116\105\111\110"or z=="\067\097\110\118\097\115\083\105\122\101"then local z=ScrollingFrame.CanvasPosition.Y~=0 local p=ScrollingFrame.CanvasPosition.Y<ScrollingFrame.CanvasSize.Y.Offset-ScrollingFrame.AbsoluteWindowSize.Y ScrollUpInventoryButton.Visible=z ScrollDownInventoryButton.Visible=p end end)
-- Make the ScrollingFrame, which holds the rest of the Slots (however many) ScrollingFrame = NewGui("ScrollingFrame", "ScrollingFrame") ScrollingFrame.Selectable = false ScrollingFrame.CanvasSize = UDim2.new(0, 0, 0, 0) ScrollingFrame.Parent = InventoryFrame UIGridFrame = NewGui("Frame", "UIGridFrame") UIGridFrame.Selectable = false UIGridFrame.Size = UDim2.new(1, -(ICON_BUFFER * 2), 1, 0) UIGridFrame.Position = UDim2.new(0, ICON_BUFFER, 0, 0) UIGridFrame.Parent = ScrollingFrame UIGridLayout = Instance.new("UIGridLayout") UIGridLayout.SortOrder = Enum.SortOrder.LayoutOrder UIGridLayout.CellSize = UDim2.new(0, ICON_SIZE, 0, ICON_SIZE) UIGridLayout.CellPadding = UDim2.new(0, ICON_BUFFER, 0, ICON_BUFFER) UIGridLayout.Parent = UIGridFrame ScrollUpInventoryButton = MakeVRRoundButton("ScrollUpButton", "rbxasset://textures/ui/Backpack/ScrollUpArrow.png") ScrollUpInventoryButton.Size = UDim2.new(0, 34, 0, 34) ScrollUpInventoryButton.Position = UDim2.new(0.5, -ScrollUpInventoryButton.Size.X.Offset / 2, 0, INVENTORY_HEADER_SIZE + 3) ScrollUpInventoryButton.Icon.Position = ScrollUpInventoryButton.Icon.Position - UDim2.new(0, 0, 0, 2) ScrollUpInventoryButton.MouseButton1Click:Connect(function() ScrollingFrame.CanvasPosition = Vector2.new( ScrollingFrame.CanvasPosition.X, Clamp( 0, ScrollingFrame.CanvasSize.Y.Offset - ScrollingFrame.AbsoluteWindowSize.Y, ScrollingFrame.CanvasPosition.Y - (ICON_BUFFER + ICON_SIZE) ) ) end) ScrollDownInventoryButton = MakeVRRoundButton("ScrollDownButton", "rbxasset://textures/ui/Backpack/ScrollUpArrow.png") ScrollDownInventoryButton.Rotation = 180 ScrollDownInventoryButton.Icon.Position = ScrollDownInventoryButton.Icon.Position - UDim2.new(0, 0, 0, 2) ScrollDownInventoryButton.Size = UDim2.new(0, 34, 0, 34) ScrollDownInventoryButton.Position = UDim2.new(0.5, -ScrollDownInventoryButton.Size.X.Offset / 2, 1, -ScrollDownInventoryButton.Size.Y.Offset - 3) ScrollDownInventoryButton.MouseButton1Click:Connect(function() ScrollingFrame.CanvasPosition = Vector2.new( ScrollingFrame.CanvasPosition.X, Clamp( 0, ScrollingFrame.CanvasSize.Y.Offset - ScrollingFrame.AbsoluteWindowSize.Y, ScrollingFrame.CanvasPosition.Y + (ICON_BUFFER + ICON_SIZE) ) ) end) ScrollingFrame.Changed:Connect(function(prop) if prop == "AbsoluteWindowSize" or prop == "CanvasPosition" or prop == "CanvasSize" then local canScrollUp = ScrollingFrame.CanvasPosition.Y ~= 0 local canScrollDown = ScrollingFrame.CanvasPosition.Y < ScrollingFrame.CanvasSize.Y.Offset - ScrollingFrame.AbsoluteWindowSize.Y ScrollUpInventoryButton.Visible = canScrollUp ScrollDownInventoryButton.Visible = canScrollDown end end)
local function z(z)if RecentAppEnabled==true then local p=false if home:FindFirstChild(z)then if side.RecentApps:FindFirstChild(z)then p=true end side.Status:TweenPosition(UDim2.new(.094,0,.638,0),"\073\110\079\117\116","\081\117\105\110\116",.5,true)side.B1:TweenPosition(UDim2.new(.024,0,.593,0),"\073\110\079\117\116","\081\117\105\110\116",.5,true)for R,W in pairs(side.RecentApps:GetChildren())do if W.Position==UDim2.new(.016,0,.345,0)then if p and side.RecentApps:FindFirstChild(z)then if side.RecentApps[z].Position~=UDim2.new(.015,0,.027,0)then W:TweenPosition(UDim2.new(.032,0,.668,0),"\073\110\079\117\116","\081\117\105\110\116",.25,true)end else W:TweenPosition(UDim2.new(.032,0,.668,0),"\073\110\079\117\116","\081\117\105\110\116",.25,true)end end if W.Position==UDim2.new(.015,0,.027,0)then W:TweenPosition(UDim2.new(.016,0,.345,0),"\073\110\079\117\116","\081\117\105\110\116",.25,true)end if W.Name==z then W:TweenPosition(UDim2.new(.015,0,.027,0),"\073\110\079\117\116","\081\117\105\110\116",.25,true)end if W.Position==UDim2.new(.032,0,.668,0)then if not p then for z=0,1,.2 do wait()W.ImageTransparency=z end W:Destroy()end end end if not p then local p=(home:FindFirstChild(z)):Clone()p.Parent=side.RecentApps p.IconName.Visible=false p.ZIndex=102 p.Size=UDim2.new(.968,0,.358,0)p.ImageTransparency=1 p.Position=UDim2.new(.015,0,.027,0)for z=1,0,-0.2 do wait()p.ImageTransparency=z end end end end end local function p(z,p,R)local W=script.Parent.CarPlay.NowPlaying.MusicTitle local s=script.Parent.CarPlay.NowPlaying.MusicID W.Text=z s.Text=p filter:FireServer("\117\112\100\097\116\101\083\111\110\103",p,R)handler:FireServer("\080\108\097\121\077\117\115\105\099",z,p)nowplaying.Play.ImageRectOffset=Vector2.new(150,0)end local function R(z,p,R)if script.Parent.CarPlay_Data.Playlists:FindFirstChild(p)then local R=script.Parent.CarPlay.NowPlaying.MusicTitle local W=script.Parent.CarPlay.NowPlaying.MusicID local s=script.Parent.CarPlay_Data.Playlists[p]:GetChildren()R.Text=s[z].Name handler:FireServer("\080\108\097\121\077\117\115\105\099",s[z].Name,s[z].Value)W.Text=s[z].Value filter:FireServer("\117\112\100\097\116\101\083\111\110\103",s[z].Value,s[z].Pitch.Value)end end local function W(p)if home:FindFirstChild(p)then handler:FireServer("\076\097\117\110\099\104\065\112\112",p)for z,p in ipairs(home:GetChildren())do p.AppEnabled.Value=false end z(p)home[p].IconName.Visible=false home[p].ZIndex=102 X=home[p].Position.X.Scale Y=home[p].Position.Y.Scale home[p]:TweenSizeAndPosition(UDim2.new(1.599,0,2.591,0),UDim2.new(-0.325,0,-0.965,0),"\079\117\116","\081\117\105\110\116",1.2,true)home[p].Parent=script.Parent.CarPlay.Homescreen for z,R in ipairs(script.Parent.CarPlay:GetChildren())do if R.Name==p then R.Visible=true end end home.Visible=false for z=0,1,.2 do wait()home.Parent[p].ImageTransparency=z end home.Parent.Visible=false end end local function s()for z,p in pairs(home.Parent:GetChildren())do if p.Name=="\077\117\115\105\099"or p.Name=="\077\097\112\115"or p.Name=="\083\101\116\116\105\110\103\115"or p.Name=="\066\077\087"or p.Name=="\078\111\119\080\108\097\121\105\110\103"or p.Name=="\080\111\100\099\097\115\116\115"or p.Name=="\080\104\111\110\101"then handler:FireServer("\076\097\117\110\099\104\072\111\109\101")script.Parent.CarPlay.Music.Library.Visible=true script.Parent.CarPlay.Music.Playlists.Visible=false for z,p in pairs(script.Parent.CarPlay:GetChildren())do if p:IsA("\070\114\097\109\101")and p.Visible==true then p.Visible=false end end;(script.Parent.CarPlay:FindFirstChild(p.Name)).Visible=false home.Parent.Visible=true p:TweenSizeAndPosition(UDim2.new(.23,0,1,0),UDim2.new(X,0,Y,0),"\079\117\116","\081\117\105\110\116",.5,true)home.Visible=true p.ImageTransparency=0 p.ZIndex=2 p.IconName.Visible=true p.Parent=home wait(.4)for z,p in pairs(home:GetChildren())do if p:FindFirstChild("\065\112\112\069\110\097\098\108\101\100")then p.AppEnabled.Value=true end end end end end local function k(R)local W=0 local s=.039 music.Playlists.MusicPlaylist:ClearAllChildren()local k=script.Parent.CarPlay_Data.Playlists[R]music.Playlists.PlaylistName.Text=R for z,p in ipairs(k:GetChildren())do if p:IsA("\073\110\116\086\097\108\117\101")then handler:FireServer("\076\111\097\100\080\108\097\121\108\105\115\116",R,p.Name,p.Value,W)local z=music.Playlists.Template:Clone()z.Name=p.Value z.MusicTitle.Text=p.Name z.MusicID.Text=p.Value z.Position=UDim2.new(.037,0,W,0)z.Parent=music.Playlists.MusicPlaylist z.Pitch.Value=p.Pitch.Value z.Visible=true W=W+s end end for W,s in ipairs(script.Parent.CarPlay.Music.Playlists.MusicPlaylist:GetChildren())do if s:IsA("\084\101\120\116\066\117\116\116\111\110")then s.MouseButton1Down:connect(function()TransitionTo("\080\108\097\121\108\105\115\116\115","\078\111\119\080\108\097\121\105\110\103")z("\078\111\119\080\108\097\121\105\110\103")script.Parent.CarPlay_Data.NowPlayingData.CurrentPlaylist.Value=R script.Parent.CarPlay_Data.NowPlayingData.SongNumber.Value=W p(s.MusicTitle.Text,s.MusicID.Text,s.Pitch.Value)end)end end end local function m()local z=.002 local p=.092 music.Library.LibraryButtons:ClearAllChildren()local R=script.Parent.CarPlay_Data.Playlists for R,W in ipairs(R:GetChildren())do if W:IsA("\070\111\108\100\101\114")then local R=(music.Library:WaitForChild("\084\101\109\112\108\097\116\101")):Clone()R.Parent=music.Library.LibraryButtons R.Name=W.Name R.Visible=true handler:FireServer("\067\114\101\097\116\101\080\108\097\121\108\105\115\116",W.Name,z)R.PlaylistName.Text=W.Name R.Position=UDim2.new(.025,0,z,0)z=z+p end end for z,p in ipairs(script.Parent.CarPlay.Music.Library.LibraryButtons:GetChildren())do if p:IsA("\084\101\120\116\066\117\116\116\111\110")then p.MouseButton1Down:connect(function()TransitionTo("\076\105\098\114\097\114\121","\080\108\097\121\108\105\115\116\115")k(p.Name)end)end end end function TransitionTo(z,p)if debounce==false then debounce=true for R,W in ipairs(script.Parent.CarPlay:GetDescendants())do if W:IsA("\070\114\097\109\101")and W.Name==z then W:TweenPosition(UDim2.new(-1,0,0,0),"\079\117\116","\081\117\105\110\116",.5,true)local z=coroutine.wrap(function()wait(.5)W.Position=UDim2.new(0,0,0,0)W.Visible=false end)z()end if W:IsA("\070\114\097\109\101")and W.Name==p then W.Visible=true W.Position=UDim2.new(1,0,0,0)W:TweenPosition(UDim2.new(0,0,0,0),"\079\117\116","\081\117\105\110\116",.5,true)end handler:FireServer("\084\114\097\110\115\105\116\105\111\110",z,p)debounce=false end end end
--Functions (Needed to organize) local function AddRecentApp(App) if RecentAppEnabled == true then local sameapp = false if home:FindFirstChild(App) then if side.RecentApps:FindFirstChild(App) then sameapp = true end side.Status:TweenPosition(UDim2.new(0.094, 0, 0.638, 0), "InOut", "Quint", 0.5, true) side.B1:TweenPosition(UDim2.new(0.024, 0, 0.593, 0), "InOut", "Quint", 0.5, true) for i, v in pairs(side.RecentApps:GetChildren()) do if v.Position == UDim2.new(0.016, 0, 0.345, 0) then if sameapp and side.RecentApps:FindFirstChild(App) then if side.RecentApps[App].Position ~= UDim2.new(0.015, 0, 0.027, 0) then v:TweenPosition(UDim2.new(0.032, 0, 0.668, 0), "InOut", "Quint", 0.25, true) end else v:TweenPosition(UDim2.new(0.032, 0, 0.668, 0), "InOut", "Quint", 0.25, true) end end if v.Position == UDim2.new(0.015, 0, 0.027, 0) then v:TweenPosition(UDim2.new(0.016, 0, 0.345, 0), "InOut", "Quint", 0.25, true) end if v.Name == App then --prevents any same apps to be duplicated ok v:TweenPosition(UDim2.new(0.015, 0, 0.027, 0), "InOut", "Quint", 0.25, true) end if v.Position == UDim2.new(0.032, 0, 0.668, 0) then if not sameapp then for i = 0, 1, 0.2 do wait() v.ImageTransparency = i end v:Destroy() end end end if not sameapp then local app = home:FindFirstChild(App):Clone() app.Parent = side.RecentApps app.IconName.Visible = false app.ZIndex = 102 app.Size = UDim2.new(0.968, 0, 0.358, 0) app.ImageTransparency = 1 app.Position = UDim2.new(0.015, 0, 0.027, 0) for i = 1, 0, -0.2 do wait() app.ImageTransparency = i end end end end end local function PlayMusic(Title, ID, pitch) local musictitle = script.Parent.CarPlay.NowPlaying.MusicTitle local id = script.Parent.CarPlay.NowPlaying.MusicID musictitle.Text = Title id.Text = ID filter:FireServer("updateSong", ID, pitch) handler:FireServer("PlayMusic", Title, ID) nowplaying.Play.ImageRectOffset = Vector2.new(150, 0) end local function PlayMusicUsingSongValue(Val, Playlists, pitch) if script.Parent.CarPlay_Data.Playlists:FindFirstChild(Playlists) then local musictitle = script.Parent.CarPlay.NowPlaying.MusicTitle local id = script.Parent.CarPlay.NowPlaying.MusicID local playlists = script.Parent.CarPlay_Data.Playlists[Playlists]:GetChildren() musictitle.Text = playlists[Val].Name handler:FireServer("PlayMusic", playlists[Val].Name, playlists[Val].Value) id.Text = playlists[Val].Value filter:FireServer("updateSong", playlists[Val].Value, playlists[Val].Pitch.Value) end end local function LaunchApp(AppToLaunch) if home:FindFirstChild(AppToLaunch) then handler:FireServer("LaunchApp", AppToLaunch) for i, app in ipairs(home:GetChildren()) do app.AppEnabled.Value = false -- no jerks that can mess carplay end AddRecentApp(AppToLaunch) home[AppToLaunch].IconName.Visible = false home[AppToLaunch].ZIndex = 102 X = home[AppToLaunch].Position.X.Scale Y = home[AppToLaunch].Position.Y.Scale home[AppToLaunch]:TweenSizeAndPosition( UDim2.new(1.599, 0, 2.591, 0), UDim2.new(-0.325, 0, -0.965, 0), "Out", "Quint", 1.2, true ) home[AppToLaunch].Parent = script.Parent.CarPlay.Homescreen for i, app in ipairs(script.Parent.CarPlay:GetChildren()) do if app.Name == AppToLaunch then app.Visible = true end end home.Visible = false for i = 0, 1, 0.2 do wait() home.Parent[AppToLaunch].ImageTransparency = i end home.Parent.Visible = false end end local function LaunchHome() for i, v in pairs(home.Parent:GetChildren()) do if v.Name == "Music" or v.Name == "Maps" or v.Name == "Settings" or v.Name == "BMW" or v.Name == "NowPlaying" or v.Name == "Podcasts" or v.Name == "Phone" then handler:FireServer("LaunchHome") script.Parent.CarPlay.Music.Library.Visible = true script.Parent.CarPlay.Music.Playlists.Visible = false for i, app in pairs(script.Parent.CarPlay:GetChildren()) do if app:IsA("Frame") and app.Visible == true then app.Visible = false end end script.Parent.CarPlay:FindFirstChild(v.Name).Visible = false home.Parent.Visible = true v:TweenSizeAndPosition(UDim2.new(0.23, 0, 1, 0), UDim2.new(X, 0, Y, 0), "Out", "Quint", 0.5, true) home.Visible = true v.ImageTransparency = 0 v.ZIndex = 2 v.IconName.Visible = true v.Parent = home wait(0.4) for i, app in pairs(home:GetChildren()) do if app:FindFirstChild("AppEnabled") then app.AppEnabled.Value = true -- no jerks that can mess carplay end end end end end local function LoadPlaylist(PlaylistName) local Y = 0 local NextY = 0.039 music.Playlists.MusicPlaylist:ClearAllChildren() local Data = script.Parent.CarPlay_Data.Playlists[PlaylistName] music.Playlists.PlaylistName.Text = PlaylistName for i, musics in ipairs(Data:GetChildren()) do if musics:IsA("IntValue") then handler:FireServer("LoadPlaylist", PlaylistName, musics.Name, musics.Value, Y) local Template = music.Playlists.Template:Clone() Template.Name = musics.Value Template.MusicTitle.Text = musics.Name Template.MusicID.Text = musics.Value Template.Position = UDim2.new(0.037, 0, Y, 0) Template.Parent = music.Playlists.MusicPlaylist Template.Pitch.Value = musics.Pitch.Value Template.Visible = true Y = Y + NextY end end for i, playlists in ipairs(script.Parent.CarPlay.Music.Playlists.MusicPlaylist:GetChildren()) do if playlists:IsA("TextButton") then playlists.MouseButton1Down:connect(function() TransitionTo("Playlists", "NowPlaying") AddRecentApp("NowPlaying") script.Parent.CarPlay_Data.NowPlayingData.CurrentPlaylist.Value = PlaylistName script.Parent.CarPlay_Data.NowPlayingData.SongNumber.Value = i PlayMusic(playlists.MusicTitle.Text, playlists.MusicID.Text, playlists.Pitch.Value) end) end end end local function CreatePlaylists() local Y = 0.002 local NextY = 0.092 music.Library.LibraryButtons:ClearAllChildren() local Data = script.Parent.CarPlay_Data.Playlists for i, playlists in ipairs(Data:GetChildren()) do if playlists:IsA("Folder") then local Template = music.Library:WaitForChild("Template"):Clone() Template.Parent = music.Library.LibraryButtons Template.Name = playlists.Name Template.Visible = true handler:FireServer("CreatePlaylist", playlists.Name, Y) Template.PlaylistName.Text = playlists.Name Template.Position = UDim2.new(0.025, 0, Y, 0) Y = Y + NextY end end for i, playlists in ipairs(script.Parent.CarPlay.Music.Library.LibraryButtons:GetChildren()) do if playlists:IsA("TextButton") then playlists.MouseButton1Down:connect(function() TransitionTo("Library", "Playlists") LoadPlaylist(playlists.Name) end) end end end function TransitionTo(Prev, Next) if debounce == false then debounce = true for i, frame in ipairs(script.Parent.CarPlay:GetDescendants()) do if frame:IsA("Frame") and frame.Name == Prev then frame:TweenPosition(UDim2.new(-1, 0, 0, 0), "Out", "Quint", 0.5, true) local framediss = coroutine.wrap(function() wait(0.5) frame.Position = UDim2.new(0, 0, 0, 0) frame.Visible = false end) framediss() end if frame:IsA("Frame") and frame.Name == Next then frame.Visible = true frame.Position = UDim2.new(1, 0, 0, 0) frame:TweenPosition(UDim2.new(0, 0, 0, 0), "Out", "Quint", 0.5, true) end handler:FireServer("Transition", Prev, Next) debounce = false end end end
function Component.render(z)local p=z[InternalData]local R=componentMissingRenderMessage:format(tostring(p.componentClass))error(R,0)end
--[[ Returns a snapshot of this component given the current props and state. Must be overridden by consumers of Roact and should be a pure function with regards to props and state. TODO (#199): Accept props and state as arguments. ]] function Component:render() local internalData = self[InternalData] local message = componentMissingRenderMessage:format(tostring(internalData.componentClass)) error(message, 0) end
local z="\066\097\115\101\070\114\097\109\101"local p="\066\097\115\101\077\101\115\115\097\103\101"local R="\085\112\100\097\116\101\084\101\120\116\070\117\110\099\116\105\111\110"local W="\071\101\116\072\101\105\103\104\116\070\117\110\099\116\105\111\110"local s="\070\097\100\101\073\110\070\117\110\099\116\105\111\110"local k="\070\097\100\101\079\117\116\070\117\110\099\116\105\111\110"local m="\085\112\100\097\116\101\065\110\105\109\070\117\110\099\116\105\111\110"local V=game:GetService("\084\101\120\116\083\101\114\118\105\099\101")local Q=game:GetService("\080\108\097\121\101\114\115")local t=Q.LocalPlayer while not t do Q.ChildAdded:wait()t=Q.LocalPlayer end local L=script.Parent.Parent local Z=require(L:WaitForChild("\067\104\097\116\083\101\116\116\105\110\103\115"))local e=require(L:WaitForChild("\067\104\097\116\067\111\110\115\116\097\110\116\115"))local x={}local F={}F.__index=F function F.GetStringTextBounds(s,z,p,R,W)W=W or Vector2.new(10000,10000)return V:GetTextSize(z,R,p,W)end
---Creator function return object keys local KEY_BASE_FRAME = "BaseFrame" local KEY_BASE_MESSAGE = "BaseMessage" local KEY_UPDATE_TEXT_FUNC = "UpdateTextFunction" local KEY_GET_HEIGHT = "GetHeightFunction" local KEY_FADE_IN = "FadeInFunction" local KEY_FADE_OUT = "FadeOutFunction" local KEY_UPDATE_ANIMATION = "UpdateAnimFunction" local TextService = game:GetService("TextService") local Players = game:GetService("Players") local LocalPlayer = Players.LocalPlayer while not LocalPlayer do Players.ChildAdded:wait() LocalPlayer = Players.LocalPlayer end local clientChatModules = script.Parent.Parent local ChatSettings = require(clientChatModules:WaitForChild("ChatSettings")) local ChatConstants = require(clientChatModules:WaitForChild("ChatConstants")) local module = {} local methods = {} methods.__index = methods function methods:GetStringTextBounds(text, font, textSize, sizeBounds) sizeBounds = sizeBounds or Vector2.new(10000, 10000) return TextService:GetTextSize(text, textSize, font, sizeBounds) end
DualWeldEnabled=false AltFire=false MagCartridge=false MaxCount=200 RemoveOldAtMax=false MaxRotationSpeed=360 Drag=1 Gravity=Vector2.new(0,1000)Ejection=true Shockwave=true Velocity=50 XMin=-4 XMax=-2 YMin=-6 YMax=-5 DropAllRemainingBullets=false DropVelocity=10 DropXMin=-5 DropXMax=5 DropYMin=-0.1 DropYMax=0
-- ==================== -- MISCELLANEOUS -- Etc. settings for the gun -- ==================== DualWeldEnabled = false --Enable the user to hold two guns instead one. In order to make this setting work, you must clone its PrimaryHandle and name it like SecondaryHandle. NOTE: Enabling "CustomGripEnabled" won't make this setting working AltFire = false --Enable the user to alt fire. NOTE: Must have aleast two setting modules MagCartridge = false --Display magazine cartridge interface (cosmetic only) MaxCount = 200 RemoveOldAtMax = false MaxRotationSpeed = 360 Drag = 1 Gravity = Vector2.new(0, 1000) Ejection = true Shockwave = true Velocity = 50 XMin = -4 XMax = -2 YMin = -6 YMax = -5 DropAllRemainingBullets = false DropVelocity = 10 DropXMin = -5 DropXMax = 5 DropYMin = -0.1 DropYMax = 0
return function(z,p)if p then setfenv(1,p)end local R=service.PlayerGui local W=service.Players.LocalPlayer local s=client.UI.Prepare(script.Parent.Parent)local k=s.Window local m=z.Message local V=z.Color local Q=client.UI.Get("\079\117\116\112\117\116")if Q then for z,p in pairs(Q)do local R=p.Object if R and R.Parent then R.Window.Position=UDim2.new(.5,0,.5,R.Window.Position.Y.Offset+160)end end end k.Main.ScrollingFrame.ErrorText.Text=m k.Main.ScrollingFrame.ErrorText.TextColor3=V k.Close.MouseButton1Down:Connect(function()gTable.Destroy()end)spawn(function()local z=Instance.new("\083\111\117\110\100",service.LocalContainer())z.SoundId="\114\098\120\097\115\115\101\116\105\100\058\047\047\049\054\048\055\049\053\051\053\055"z.Volume=2 z:Play()wait(.8)z:Destroy()end)gTable.Ready()wait(5)gTable.Destroy()end
--// All global vars will be wiped/replaced except script return function(data, env) if env then setfenv(1, env) end local playergui = service.PlayerGui local localplayer = service.Players.LocalPlayer local scr = client.UI.Prepare(script.Parent.Parent) local window = scr.Window local msg = data.Message local color = data.Color local found = client.UI.Get("Output") if found then for i, v in pairs(found) do local p = v.Object if p and p.Parent then p.Window.Position = UDim2.new(0.5, 0, 0.5, p.Window.Position.Y.Offset + 160) end end end window.Main.ScrollingFrame.ErrorText.Text = msg window.Main.ScrollingFrame.ErrorText.TextColor3 = color window.Close.MouseButton1Down:Connect(function() gTable.Destroy() end) spawn(function() local sound = Instance.new("Sound", service.LocalContainer()) sound.SoundId = "rbxassetid://160715357" sound.Volume = 2 sound:Play() wait(0.8) sound:Destroy() end) gTable.Ready() wait(5) gTable.Destroy() end
local z={}local p={}local R={}local W={}local s={}
-------------------------------------------------------------- -- You DO NOT need to add yourself to any of these lists!!! -- -------------------------------------------------------------- local Owners = {} -- Can set SuperAdmins, & use all the commands local SuperAdmins = {} -- Can set permanent admins, & shutdown the game local Admins = {} -- Can ban, crash, & set Moderators/VIP local Mods = {} -- Can kick, mute, & use most commands local VIP = {} -- Can use nonabusive commands only on self
Tune.LoadDelay=.1 Tune.AutoStart=true Tune.AutoFlip=true
--[[Misc]] Tune.LoadDelay = 0.1 -- Delay before initializing chassis (in seconds) Tune.AutoStart = true -- Set to false if using manual ignition plugin Tune.AutoFlip = true -- Set to false if using manual flip plugin
local function z()if(car.DriveSeat.CFrame*CFrame.Angles(math.pi/2,0,0)).lookVector.y>.1 or FlipDB then FlipWait=tick()else if tick()-FlipWait>=3 then FlipDB=true local z=car.DriveSeat.Flip z.maxTorque=Vector3.new(10000,0,10000)z.P=3000 z.D=500 wait(1)z.maxTorque=Vector3.new(0,0,0)z.P=0 z.D=0 FlipDB=false end end end
--[[Flip]] local function Flip() --Detect Orientation if (car.DriveSeat.CFrame * CFrame.Angles(math.pi / 2, 0, 0)).lookVector.y > 0.1 or FlipDB then FlipWait = tick() --Apply Flip else if tick() - FlipWait >= 3 then FlipDB = true local gyro = car.DriveSeat.Flip gyro.maxTorque = Vector3.new(10000, 0, 10000) gyro.P = 3000 gyro.D = 500 wait(1) gyro.maxTorque = Vector3.new(0, 0, 0) gyro.P = 0 gyro.D = 0 FlipDB = false end end end
local function z(z,p)local R,W=getAsset(p)if R then local p=Datastore:GetData(z)if R.onPurchased then R.onPurchased(z)end if W=="\080\097\115\115\101\115"and p then local z=p.Gamepasses or{}table.insert(z,R.Id)p.Gamepasses=z end end end MarketplaceService.PromptGamePassPurchaseFinished:Connect(function(p,R,W)if W and p.Parent then z(p,R)game.ReplicatedStorage.RE.gamepassUpdate:FireClient(p,getNameFromID(R))end end)MarketplaceService.PromptProductPurchaseFinished:Connect(function(p,R,W)local s=game.Players:GetPlayerByUserId(p)if W and(s and s.Parent)then z(s,R)end end)
-- listeners local function onProductPurchased(player, id) local product, class = getAsset(id) if product then local data = Datastore:GetData(player) if product.onPurchased then product.onPurchased(player) end if class == "Passes" and data then local gamepasses = data.Gamepasses or {} table.insert(gamepasses, product.Id) data.Gamepasses = gamepasses end end end MarketplaceService.PromptGamePassPurchaseFinished:Connect(function(player, id, success) if success and player.Parent then onProductPurchased(player, id) game.ReplicatedStorage.RE.gamepassUpdate:FireClient(player, getNameFromID(id)) end end) MarketplaceService.PromptProductPurchaseFinished:Connect(function(userid, id, success) local player = game.Players:GetPlayerByUserId(userid) if success and player and player.Parent then onProductPurchased(player, id) end end)
local z=false local p={{units="\075\077\047\072",scaling=.9144,maxSpeed=370;spInc=40},{units="\075\077\047\072",scaling=.9144,maxSpeed=370;spInc=40},{units="\083\080\083",scaling=1,maxSpeed=400,spInc=40}}
--[[ ___ _______ _ / _ |____/ ___/ / ___ ____ ___ (_)__ / __ /___/ /__/ _ \/ _ `(_-<(_-</ (_-< /_/ |_| \___/_//_/\_,_/___/___/_/___/ SecondLogic @ Inspare ]] local autoscaling = false --Estimates top speed local UNITS = { --Click on speed to change units --First unit is default { units = "KM/H", scaling = (10 / 12) * 1.09728, -- 1 stud : 10 inches | ft/s to MPH maxSpeed = 370, spInc = 40, -- Increment between labelled notches }, { units = "KM/H", scaling = (10 / 12) * 1.09728, -- 1 stud : 10 inches | ft/s to KP/H maxSpeed = 370, spInc = 40, -- Increment between labelled notches }, { units = "SPS", scaling = 1, -- Roblox standard maxSpeed = 400, spInc = 40, -- Increment between labelled notches }, }
local function z(z,p)if z.Character and z.Character:FindFirstChild("\084\111\114\115\111")then local p=z.Character:FindFirstChild("\084\111\114\115\111")local R=p.Position-stove.Door.Position if R.magnitude<clickDistance then if open then ovenMotor.DesiredAngle=0 open=false else ovenMotor.DesiredAngle=math.pi/2 open=true end end end end stove.DoorPadding.ROBLOXInteractionEvent.OnServerEvent:connect(function(p,R)z(p)end)stove.Door.ROBLOXInteractionEvent.OnServerEvent:connect(function(p,R)z(p)end)
-- Handle event fire local function toggleDoor(player, door) -- Check distance to the character's Torso. If too far, don't do anything if player.Character and player.Character:FindFirstChild("Torso") then local torso = player.Character:FindFirstChild("Torso") local toTorso = torso.Position - stove.Door.Position if toTorso.magnitude < clickDistance then if open then ovenMotor.DesiredAngle = 0 open = false else ovenMotor.DesiredAngle = math.pi / 2 open = true end end end end stove.DoorPadding.ROBLOXInteractionEvent.OnServerEvent:connect(function(player, arguments) toggleDoor(player) end) stove.Door.ROBLOXInteractionEvent.OnServerEvent:connect(function(player, arguments) toggleDoor(player) end)
function ActionManager.BindGameActions(p,z)for z,p in pairs(z)do bind:FireClient(p,"\065\099\116\105\111\110\049",Enum.UserInputType.MouseButton1,Enum.KeyCode.ButtonR2)end end function ActionManager.UnbindGameActions(p,z)for z,p in pairs(z)do unbind:FireClient(p,"\065\099\116\105\111\110\049")end end
-- ======================================== -- ActionManager -- ======================================== -- Bind/Unbind actions function ActionManager:BindGameActions(players) for i, player in pairs(players) do bind:FireClient(player, "Action1", Enum.UserInputType.MouseButton1, Enum.KeyCode.ButtonR2) end end function ActionManager:UnbindGameActions(players) for i, player in pairs(players) do unbind:FireClient(player, "Action1") end end
local function z(z,p,R,W,s,k)if not R then return end for z,m in pairs(serverWorkerModule.getAllOtherPlayers(z))do playSoundEffectEvent:FireClient(m,p,R,W,s,k)end end
--[[------------------------------------- REMOTE FUNCTIONS ------------------------------]] -- local function validateAndSendSoundRequest(requestingPly, parent, soundObj, vol, pit, timePos) if not soundObj then return end for _, v in pairs(serverWorkerModule.getAllOtherPlayers(requestingPly)) do playSoundEffectEvent:FireClient(v, parent, soundObj, vol, pit, timePos) end end
local function z(z,p,R)local W=Instance.new(z)if p then W.Value=p end W.Changed:connect(R)R(W.Value)return W end local p=z("\067\111\108\111\114\051\086\097\108\117\101",RAIN_DEFAULT_COLOR,function(z)local p=ColorSequence.new(z)Emitter.RainStraight.Color=p Emitter.RainTopDown.Color=p for z,R in pairs(splashAttachments)do R.RainSplash.Color=p end for z,R in pairs(rainAttachments)do R.RainStraight.Color=p R.RainTopDown.Color=p end end)local function R(z)local p=(1-z)*(1-GlobalModifier.Value)local R=1-p straightLowAlpha=RAIN_STRAIGHT_ALPHA_LOW*p+R topdownLowAlpha=RAIN_TOPDOWN_ALPHA_LOW*p+R local W=NumberSequence.new({NSK010;NumberSequenceKeypoint.new(RAIN_TRANSPARENCY_T1,p*RAIN_SPLASH_ALPHA_LOW+R,0),NumberSequenceKeypoint.new(RAIN_TRANSPARENCY_T2,p*RAIN_SPLASH_ALPHA_LOW+R,0),NSK110})for z,p in pairs(splashAttachments)do p.RainSplash.Transparency=W end end local W=z("\078\117\109\098\101\114\086\097\108\117\101",RAIN_DEFAULT_TRANSPARENCY,R)GlobalModifier.Changed:connect(R)local s=z("\078\117\109\098\101\114\086\097\108\117\101",RAIN_DEFAULT_SPEEDRATIO,function(z)Emitter.RainStraight.Speed=NumberRange.new(z*RAIN_STRAIGHT_MAX_SPEED)Emitter.RainTopDown.Speed=NumberRange.new(z*RAIN_TOPDOWN_MAX_SPEED)end)local k=z("\078\117\109\098\101\114\086\097\108\117\101",RAIN_DEFAULT_INTENSITYRATIO,function(z)Emitter.RainStraight.Rate=RAIN_STRAIGHT_MAX_RATE*z Emitter.RainTopDown.Rate=RAIN_TOPDOWN_MAX_RATE*z intensityOccludedRain=math.ceil(RAIN_OCCLUDED_MAXINTENSITY*z)numSplashes=RAIN_SPLASH_NUM*z end)local m=z("\078\117\109\098\101\114\086\097\108\117\101",RAIN_DEFAULT_LIGHTEMISSION,function(z)Emitter.RainStraight.LightEmission=z Emitter.RainTopDown.LightEmission=z for p,R in pairs(rainAttachments)do R.RainStraight.LightEmission=z R.RainTopDown.LightEmission=z end for p,R in pairs(splashAttachments)do R.RainSplash.LightEmission=z end end)local V=z("\078\117\109\098\101\114\086\097\108\117\101",RAIN_DEFAULT_LIGHTINFLUENCE,function(z)Emitter.RainStraight.LightInfluence=z Emitter.RainTopDown.LightInfluence=z for p,R in pairs(rainAttachments)do R.RainStraight.LightInfluence=z R.RainTopDown.LightInfluence=z end for p,R in pairs(splashAttachments)do R.RainSplash.LightInfluence=z end end)local Q=z("\086\101\099\116\111\114\051\086\097\108\117\101",RAIN_DEFAULT_DIRECTION,function(z)if z.magnitude>.001 then rainDirection=z.unit end end)
-- Shorthand for creating a tweenable "variable" using value object local function makeProperty(valueObjectClass, defaultValue, setter) local valueObject = Instance.new(valueObjectClass) if defaultValue then valueObject.Value = defaultValue end valueObject.Changed:connect(setter) setter(valueObject.Value) return valueObject end local Color = makeProperty("Color3Value", RAIN_DEFAULT_COLOR, function(value) local value = ColorSequence.new(value) Emitter.RainStraight.Color = value Emitter.RainTopDown.Color = value for _, v in pairs(splashAttachments) do v.RainSplash.Color = value end for _, v in pairs(rainAttachments) do v.RainStraight.Color = value v.RainTopDown.Color = value end end) local function updateTransparency(value) local opacity = (1 - value) * (1 - GlobalModifier.Value) local transparency = 1 - opacity straightLowAlpha = RAIN_STRAIGHT_ALPHA_LOW * opacity + transparency topdownLowAlpha = RAIN_TOPDOWN_ALPHA_LOW * opacity + transparency local splashSequence = NumberSequence.new({ NSK010, NumberSequenceKeypoint.new(RAIN_TRANSPARENCY_T1, opacity * RAIN_SPLASH_ALPHA_LOW + transparency, 0), NumberSequenceKeypoint.new(RAIN_TRANSPARENCY_T2, opacity * RAIN_SPLASH_ALPHA_LOW + transparency, 0), NSK110, }) for _, v in pairs(splashAttachments) do v.RainSplash.Transparency = splashSequence end end local Transparency = makeProperty("NumberValue", RAIN_DEFAULT_TRANSPARENCY, updateTransparency) GlobalModifier.Changed:connect(updateTransparency) local SpeedRatio = makeProperty("NumberValue", RAIN_DEFAULT_SPEEDRATIO, function(value) Emitter.RainStraight.Speed = NumberRange.new(value * RAIN_STRAIGHT_MAX_SPEED) Emitter.RainTopDown.Speed = NumberRange.new(value * RAIN_TOPDOWN_MAX_SPEED) end) local IntensityRatio = makeProperty("NumberValue", RAIN_DEFAULT_INTENSITYRATIO, function(value) Emitter.RainStraight.Rate = RAIN_STRAIGHT_MAX_RATE * value Emitter.RainTopDown.Rate = RAIN_TOPDOWN_MAX_RATE * value intensityOccludedRain = math.ceil(RAIN_OCCLUDED_MAXINTENSITY * value) numSplashes = RAIN_SPLASH_NUM * value end) local LightEmission = makeProperty("NumberValue", RAIN_DEFAULT_LIGHTEMISSION, function(value) Emitter.RainStraight.LightEmission = value Emitter.RainTopDown.LightEmission = value for _, v in pairs(rainAttachments) do v.RainStraight.LightEmission = value v.RainTopDown.LightEmission = value end for _, v in pairs(splashAttachments) do v.RainSplash.LightEmission = value end end) local LightInfluence = makeProperty("NumberValue", RAIN_DEFAULT_LIGHTINFLUENCE, function(value) Emitter.RainStraight.LightInfluence = value Emitter.RainTopDown.LightInfluence = value for _, v in pairs(rainAttachments) do v.RainStraight.LightInfluence = value v.RainTopDown.LightInfluence = value end for _, v in pairs(splashAttachments) do v.RainSplash.LightInfluence = value end end) local RainDirection = makeProperty("Vector3Value", RAIN_DEFAULT_DIRECTION, function(value) if value.magnitude > 0.001 then rainDirection = value.unit end end)
local z=false local p={"\080\108\097\121\101\114\115";"\080\108\097\121\101\114\115"}
-- Settings local allow_duplicates = false local allow_team = { "Players", "Players", }
local A=true local function r(r)if not A then return end if r.Name=="\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116"then local t=game.Players:FindFirstChild(r.Parent.Name)if t then A=false staticCorrupt.Transparency=0 imageLableCorrupt.ImageTransparency=0 wait(4)staticCorrupt.Transparency=1 imageLableCorrupt.ImageTransparency=1 trigger.CanTouch=false wait(10)trigger.CanTouch=true A=true end end end trigger.Touched:Connect(r)
--not sure --local function PlaySound() -- game.SoundSerivce.SealOrb:Play() --end -- local triggerEnabled = true local function touched(otherPart) if not triggerEnabled then return end if otherPart.Name == "HumanoidRootPart" then local player = game.Players:FindFirstChild(otherPart.Parent.Name) if player then triggerEnabled = false staticCorrupt.Transparency = 0 imageLableCorrupt.ImageTransparency = 0 -- PlaySound("") wait(4) --How long the Corrupt screen is visable staticCorrupt.Transparency = 1 imageLableCorrupt.ImageTransparency = 1 trigger.CanTouch = false wait(10) ---How long before the trigger can be touched agian trigger.CanTouch = true triggerEnabled = true end end end trigger.Touched:Connect(touched)
function onRunning(A)if isSeated then return end if A>0 then pose="\082\117\110\110\105\110\103"else pose="\083\116\097\110\100\105\110\103"end end function onDied()pose="\068\101\097\100"end function onJumping()isSeated=false pose="\074\117\109\112\105\110\103"end function onClimbing()pose="\067\108\105\109\098\105\110\103"end function onGettingUp()pose="\071\101\116\116\105\110\103\085\112"end function onFreeFall()pose="\070\114\101\101\070\097\108\108"end function onFallingDown()pose="\070\097\108\108\105\110\103\068\111\119\110"end function onSeated()isSeated=true pose="\083\101\097\116\101\100"print("\083\101\097\116\101\100")end function moveJump()RightShoulder.MaxVelocity=.5 LeftShoulder.MaxVelocity=.5 RightShoulder.DesiredAngle=3.14 LeftShoulder.DesiredAngle=-3.14 RightHip.DesiredAngle=0 LeftHip.DesiredAngle=0 end function moveFreeFall()RightShoulder.MaxVelocity=.5 LeftShoulder.MaxVelocity=.5 RightShoulder.DesiredAngle=1 LeftShoulder.DesiredAngle=-1 RightHip.DesiredAngle=0 LeftHip.DesiredAngle=0 end function moveClimb()RightShoulder.MaxVelocity=.5 LeftShoulder.MaxVelocity=.5 RightShoulder.DesiredAngle=-3.14 LeftShoulder.DesiredAngle=3.14 RightHip.DesiredAngle=0 LeftHip.DesiredAngle=0 end function moveSit()print("\077\111\118\101 \083\105\116")RightShoulder.MaxVelocity=.15 LeftShoulder.MaxVelocity=.15 RightShoulder.DesiredAngle=1.57 LeftShoulder.DesiredAngle=-1.57 RightHip.DesiredAngle=1.57 LeftHip.DesiredAngle=-1.57 end function getTool()kidTable=Figure:children()if kidTable~=nil then numKids=#kidTable for A=1,numKids,1 do if kidTable[A].className=="\084\111\111\108"then return kidTable[A]end end end return nil end function getToolAnim(A)c=A:children()for A=1,#c,1 do if c[A].Name=="\116\111\111\108\097\110\105\109"and c[A].className=="\083\116\114\105\110\103\086\097\108\117\101"then return c[A]end end return nil end function animateTool()if toolAnim=="\078\111\110\101"then RightShoulder.DesiredAngle=1.57 return end if toolAnim=="\083\108\097\115\104"then RightShoulder.MaxVelocity=.5 RightShoulder.DesiredAngle=0 return end if toolAnim=="\076\117\110\103\101"then RightShoulder.MaxVelocity=.5 LeftShoulder.MaxVelocity=.5 RightHip.MaxVelocity=.5 LeftHip.MaxVelocity=.5 RightShoulder.DesiredAngle=1.57 LeftShoulder.DesiredAngle=1.0 RightHip.DesiredAngle=1.57 LeftHip.DesiredAngle=1.0 return end end function move(A)local r local t if pose=="\074\117\109\112\105\110\103"then moveJump()return end if pose=="\070\114\101\101\070\097\108\108"then moveFreeFall()return end if pose=="\067\108\105\109\098\105\110\103"then moveClimb()return end if pose=="\083\101\097\116\101\100"then moveSit()return end RightShoulder.MaxVelocity=.15 LeftShoulder.MaxVelocity=.15 if pose=="\082\117\110\110\105\110\103"then r=1 t=9 else r=.1 t=1 end desiredAngle=r*math.sin(A*t)RightShoulder.DesiredAngle=desiredAngle LeftShoulder.DesiredAngle=desiredAngle RightHip.DesiredAngle=-desiredAngle LeftHip.DesiredAngle=-desiredAngle local B=getTool()if B~=nil then animStringValueObject=getToolAnim(B)if animStringValueObject~=nil then toolAnim=animStringValueObject.Value animStringValueObject.Parent=nil toolAnimTime=A+.3 end if A>toolAnimTime then toolAnimTime=0 toolAnim="\078\111\110\101"end animateTool()else toolAnim="\078\111\110\101"toolAnimTime=0 end end
-- functions function onRunning(speed) if isSeated then return end if speed > 0 then pose = "Running" else pose = "Standing" end end function onDied() pose = "Dead" end function onJumping() isSeated = false pose = "Jumping" end function onClimbing() pose = "Climbing" end function onGettingUp() pose = "GettingUp" end function onFreeFall() pose = "FreeFall" end function onFallingDown() pose = "FallingDown" end function onSeated() isSeated = true pose = "Seated" print("Seated") end function moveJump() RightShoulder.MaxVelocity = 0.5 LeftShoulder.MaxVelocity = 0.5 RightShoulder.DesiredAngle = 3.14 LeftShoulder.DesiredAngle = -3.14 RightHip.DesiredAngle = 0 LeftHip.DesiredAngle = 0 end function moveFreeFall() RightShoulder.MaxVelocity = 0.5 LeftShoulder.MaxVelocity = 0.5 RightShoulder.DesiredAngle = 1 LeftShoulder.DesiredAngle = -1 RightHip.DesiredAngle = 0 LeftHip.DesiredAngle = 0 end function moveClimb() RightShoulder.MaxVelocity = 0.5 LeftShoulder.MaxVelocity = 0.5 RightShoulder.DesiredAngle = -3.14 LeftShoulder.DesiredAngle = 3.14 RightHip.DesiredAngle = 0 LeftHip.DesiredAngle = 0 end function moveSit() print("Move Sit") RightShoulder.MaxVelocity = 0.15 LeftShoulder.MaxVelocity = 0.15 RightShoulder.DesiredAngle = 3.14 / 2 LeftShoulder.DesiredAngle = -3.14 / 2 RightHip.DesiredAngle = 3.14 / 2 LeftHip.DesiredAngle = -3.14 / 2 end function getTool() kidTable = Figure:children() if kidTable ~= nil then numKids = #kidTable for i = 1, numKids do if kidTable[i].className == "Tool" then return kidTable[i] end end end return nil end function getToolAnim(tool) c = tool:children() for i = 1, #c do if c[i].Name == "toolanim" and c[i].className == "StringValue" then return c[i] end end return nil end function animateTool() if toolAnim == "None" then RightShoulder.DesiredAngle = 1.57 return end if toolAnim == "Slash" then RightShoulder.MaxVelocity = 0.5 RightShoulder.DesiredAngle = 0 return end if toolAnim == "Lunge" then RightShoulder.MaxVelocity = 0.5 LeftShoulder.MaxVelocity = 0.5 RightHip.MaxVelocity = 0.5 LeftHip.MaxVelocity = 0.5 RightShoulder.DesiredAngle = 1.57 LeftShoulder.DesiredAngle = 1.0 RightHip.DesiredAngle = 1.57 LeftHip.DesiredAngle = 1.0 return end end function move(time) local amplitude local frequency if pose == "Jumping" then moveJump() return end if pose == "FreeFall" then moveFreeFall() return end if pose == "Climbing" then moveClimb() return end if pose == "Seated" then moveSit() return end RightShoulder.MaxVelocity = 0.15 LeftShoulder.MaxVelocity = 0.15 if pose == "Running" then amplitude = 1 frequency = 9 else amplitude = 0.1 frequency = 1 end desiredAngle = amplitude * math.sin(time * frequency) RightShoulder.DesiredAngle = desiredAngle LeftShoulder.DesiredAngle = desiredAngle RightHip.DesiredAngle = -desiredAngle LeftHip.DesiredAngle = -desiredAngle local tool = getTool() if tool ~= nil then animStringValueObject = getToolAnim(tool) if animStringValueObject ~= nil then toolAnim = animStringValueObject.Value -- message recieved, delete StringValue animStringValueObject.Parent = nil toolAnimTime = time + 0.3 end if time > toolAnimTime then toolAnimTime = 0 toolAnim = "None" end animateTool() else toolAnim = "None" toolAnimTime = 0 end end
function DPad.Enable(A)DPadFrame.Visible=true end function DPad.Disable(A)DPadFrame.Visible=false OnInputEnded()end function DPad.Create(r,A)if DPadFrame then DPadFrame:Destroy()DPadFrame=nil end local t=UDim2.new(0,10,1,-230)DPadFrame=Instance.new("\070\114\097\109\101")DPadFrame.Name="\068\080\097\100\070\114\097\109\101"DPadFrame.Active=true DPadFrame.Visible=false DPadFrame.Size=UDim2.new(0,192,0,192)DPadFrame.Position=t DPadFrame.BackgroundTransparency=1 local B=UDim2.new(0,23,0,23)local h=UDim2.new(0,64,0,64)local I=Vector2.new(46,46)local G=Vector2.new(128,128)local R=createArrowLabel("\066\097\099\107\066\117\116\116\111\110",UDim2.new(.5,-32,1,-64),h,Vector2.new(0,0),G)local v=createArrowLabel("\070\111\114\119\097\114\100\066\117\116\116\111\110",UDim2.new(.5,-32,0,0),h,Vector2.new(0,258),G)local a=createArrowLabel("\076\101\102\116\066\117\116\116\111\110",UDim2.new(0,0,.5,-32),h,Vector2.new(129,129),G)local H=createArrowLabel("\082\105\103\104\116\066\117\116\116\111\110",UDim2.new(1,-64,.5,-32),h,Vector2.new(0,129),G)local V=createArrowLabel("\074\117\109\112\066\117\116\116\111\110",UDim2.new(.5,-32,.5,-32),h,Vector2.new(129,0),G)local g=createArrowLabel("\070\111\114\119\097\114\100\076\101\102\116\066\117\116\116\111\110",UDim2.new(0,35,0,35),B,Vector2.new(129,258),I)local L=createArrowLabel("\070\111\114\119\097\114\100\082\105\103\104\116\066\117\116\116\111\110",UDim2.new(1,-55,0,35),B,Vector2.new(176,258),I)g.Visible=false L.Visible=false V.InputBegan:connect(function(A)MasterControl:DoJump()end)local T=Vector3.new(0,0,0)local function l(A)local r=V.AbsoluteSize.x/2 local t=getCenterPosition()local B=Vector2.new(A.x-t.x,A.y-t.y)if B.magnitude>r then local A=ATAN2(B.y,B.x)local r=FLOOR((8*A)/(2*PI)+8.5)%8+1 T=COMPASS_DIR[r]end if not g.Visible and T==COMPASS_DIR[7]then g.Visible=true L.Visible=true end end DPadFrame.InputBegan:connect(function(A)if TouchObject or A.UserInputType~=Enum.UserInputType.Touch then return end MasterControl:AddToPlayerMovement(-T)TouchObject=A l(TouchObject.Position)MasterControl:AddToPlayerMovement(T)end)DPadFrame.InputChanged:connect(function(A)if A==TouchObject then MasterControl:AddToPlayerMovement(-T)l(TouchObject.Position)MasterControl:AddToPlayerMovement(T)end end)OnInputEnded=function()TouchObject=nil g.Visible=false L.Visible=false MasterControl:AddToPlayerMovement(-T)T=Vector3.new(0,0,0)end DPadFrame.InputEnded:connect(function(A)if A==TouchObject then OnInputEnded()end end)DPadFrame.Parent=A end return DPad
--[[ Public API ]] -- function DPad:Enable() DPadFrame.Visible = true end function DPad:Disable() DPadFrame.Visible = false OnInputEnded() end function DPad:Create(parentFrame) if DPadFrame then DPadFrame:Destroy() DPadFrame = nil end local position = UDim2.new(0, 10, 1, -230) DPadFrame = Instance.new("Frame") DPadFrame.Name = "DPadFrame" DPadFrame.Active = true DPadFrame.Visible = false DPadFrame.Size = UDim2.new(0, 192, 0, 192) DPadFrame.Position = position DPadFrame.BackgroundTransparency = 1 local smArrowSize = UDim2.new(0, 23, 0, 23) local lgArrowSize = UDim2.new(0, 64, 0, 64) local smImgOffset = Vector2.new(46, 46) local lgImgOffset = Vector2.new(128, 128) local bBtn = createArrowLabel("BackButton", UDim2.new(0.5, -32, 1, -64), lgArrowSize, Vector2.new(0, 0), lgImgOffset) local fBtn = createArrowLabel("ForwardButton", UDim2.new(0.5, -32, 0, 0), lgArrowSize, Vector2.new(0, 258), lgImgOffset) local lBtn = createArrowLabel("LeftButton", UDim2.new(0, 0, 0.5, -32), lgArrowSize, Vector2.new(129, 129), lgImgOffset) local rBtn = createArrowLabel("RightButton", UDim2.new(1, -64, 0.5, -32), lgArrowSize, Vector2.new(0, 129), lgImgOffset) local jumpBtn = createArrowLabel("JumpButton", UDim2.new(0.5, -32, 0.5, -32), lgArrowSize, Vector2.new(129, 0), lgImgOffset) local flBtn = createArrowLabel("ForwardLeftButton", UDim2.new(0, 35, 0, 35), smArrowSize, Vector2.new(129, 258), smImgOffset) local frBtn = createArrowLabel( "ForwardRightButton", UDim2.new(1, -55, 0, 35), smArrowSize, Vector2.new(176, 258), smImgOffset ) flBtn.Visible = false frBtn.Visible = false -- input connections jumpBtn.InputBegan:connect(function(inputObject) MasterControl:DoJump() end) local movementVector = Vector3.new(0, 0, 0) local function normalizeDirection(inputPosition) local jumpRadius = jumpBtn.AbsoluteSize.x / 2 local centerPosition = getCenterPosition() local direction = Vector2.new(inputPosition.x - centerPosition.x, inputPosition.y - centerPosition.y) if direction.magnitude > jumpRadius then local angle = ATAN2(direction.y, direction.x) local octant = (FLOOR(8 * angle / (2 * PI) + 8.5) % 8) + 1 movementVector = COMPASS_DIR[octant] end if not flBtn.Visible and movementVector == COMPASS_DIR[7] then flBtn.Visible = true frBtn.Visible = true end end DPadFrame.InputBegan:connect(function(inputObject) if TouchObject or inputObject.UserInputType ~= Enum.UserInputType.Touch then return end MasterControl:AddToPlayerMovement(-movementVector) TouchObject = inputObject normalizeDirection(TouchObject.Position) MasterControl:AddToPlayerMovement(movementVector) end) DPadFrame.InputChanged:connect(function(inputObject) if inputObject == TouchObject then MasterControl:AddToPlayerMovement(-movementVector) normalizeDirection(TouchObject.Position) MasterControl:AddToPlayerMovement(movementVector) end end) OnInputEnded = function() TouchObject = nil flBtn.Visible = false frBtn.Visible = false MasterControl:AddToPlayerMovement(-movementVector) movementVector = Vector3.new(0, 0, 0) end DPadFrame.InputEnded:connect(function(inputObject) if inputObject == TouchObject then OnInputEnded() end end) DPadFrame.Parent = parentFrame end return DPad
script.Parent:WaitForChild("\065-\067\104\097\115\115\105\115 \073\110\116\101\114\102\097\099\101")script.Parent:WaitForChild("\080\108\117\103\105\110\115")script.Parent:WaitForChild("\082\069\065\068\077\069")local A=script.Parent.Parent local r=require(script.Parent)wait(r.LoadDelay)local t=r.WeightScaling if not workspace:PGSIsEnabled()then t=r.LegacyScaling end local B=A.Wheels:GetChildren()function DReduce(A)for A,r in pairs(A:GetChildren())do if r:IsA("\066\097\115\101\080\097\114\116")then if r.CustomPhysicalProperties==nil then r.CustomPhysicalProperties=PhysicalProperties.new(r.Material)end r.CustomPhysicalProperties=PhysicalProperties.new(0,r.CustomPhysicalProperties.Friction,r.CustomPhysicalProperties.Elasticity,r.CustomPhysicalProperties.FrictionWeight,r.CustomPhysicalProperties.ElasticityWeight)end DReduce(r)end end DReduce(A)
--[[Initialize]] script.Parent:WaitForChild("A-Chassis Interface") script.Parent:WaitForChild("Plugins") script.Parent:WaitForChild("README") local car = script.Parent.Parent local _Tune = require(script.Parent) wait(_Tune.LoadDelay) --Weight Scaling local weightScaling = _Tune.WeightScaling if not workspace:PGSIsEnabled() then weightScaling = _Tune.LegacyScaling end local Drive = car.Wheels:GetChildren() --Remove Existing Mass function DReduce(p) for i, v in pairs(p:GetChildren()) do if v:IsA("BasePart") then if v.CustomPhysicalProperties == nil then v.CustomPhysicalProperties = PhysicalProperties.new(v.Material) end v.CustomPhysicalProperties = PhysicalProperties.new( 0, v.CustomPhysicalProperties.Friction, v.CustomPhysicalProperties.Elasticity, v.CustomPhysicalProperties.FrictionWeight, v.CustomPhysicalProperties.ElasticityWeight ) end DReduce(v) end end DReduce(car)
function httpGet(A)return game:HttpGet(A,true)end
-- Functions function httpGet(url) return game:HttpGet(url, true) end
(game:GetService("\080\108\097\121\101\114\115")).LocalPlayer.Chatted:connect(function(A)local r=""if string.sub(A,1,3)=="\047\101 "then r=string.sub(A,4)elseif string.sub(A,1,7)=="\047\101\109\111\116\101 "then r=string.sub(A,8)end if pose=="\083\116\097\110\100\105\110\103"and emoteNames[r]~=nil then playAnimation(r,.1,Humanoid)end end)
-- setup emote chat hook game:GetService("Players").LocalPlayer.Chatted:connect(function(msg) local emote = "" if string.sub(msg, 1, 3) == "/e " then emote = string.sub(msg, 4) elseif string.sub(msg, 1, 7) == "/emote " then emote = string.sub(msg, 8) end if pose == "Standing" and emoteNames[emote] ~= nil then playAnimation(emote, 0.1, Humanoid) end end)
function Receive(A,r,...)local t={...}if A==User and r=="\112\108\097\121"then Connector:FireAllClients("\112\108\097\121",User,t[1],Settings.SoundSource.Position,Settings.PianoSoundRange,Settings.PianoSounds,t[2],Settings.IsCustom)HighlightPianoKey(t[1]>61 and 61 or t[1]<1 and 1 or t[1],t[3])elseif A==User and r=="\097\098\111\114\116"then Deactivate()if SeatWeld then SeatWeld:remove()end end end function Activate(A)Connector:FireClient(A,"\097\099\116\105\118\097\116\101",Settings.CameraCFrame,Settings.PianoSounds,true)User=A end function Deactivate()if User and User.Parent then Connector:FireClient(User,"\100\101\097\099\116\105\118\097\116\101")User.Character:SetPrimaryPartCFrame(Box.CFrame+Vector3.new(0,5,0))end User=nil end
---------------------------------- ------------FUNCTIONS------------- ---------------------------------- function Receive(player, action, ...) local args = { ... } if player == User and action == "play" then Connector:FireAllClients( "play", User, args[1], Settings.SoundSource.Position, Settings.PianoSoundRange, Settings.PianoSounds, args[2], Settings.IsCustom ) HighlightPianoKey((args[1] > 61 and 61) or (args[1] < 1 and 1) or args[1], args[3]) elseif player == User and action == "abort" then Deactivate() if SeatWeld then SeatWeld:remove() end end end function Activate(player) Connector:FireClient(player, "activate", Settings.CameraCFrame, Settings.PianoSounds, true) User = player end function Deactivate() if User and User.Parent then Connector:FireClient(User, "deactivate") User.Character:SetPrimaryPartCFrame(Box.CFrame + Vector3.new(0, 5, 0)) end User = nil end
local function A(A)for r,t in ipairs(Teams:GetTeams())do if t.TeamColor==A then return t end end return nil end
-- Local Functions local function GetTeamFromColor(teamColor) for _, team in ipairs(Teams:GetTeams()) do if team.TeamColor == teamColor then return team end end return nil end
WindShake:SetDefaultSettings(WindShakeSettings)WindShake:Init()for A,r in pairs(game.Workspace:GetDescendants())do if r:IsA("\066\097\115\101\080\097\114\116")then if table.find(ShakableObjects,r.Name)then WindShake:AddObjectShake(r,WindShakeSettings)end end end game.Workspace.DescendantAdded:Connect(function(A)if table.find(ShakableObjects,A.Name)then WindShake:AddObjectShake(A,WindShakeSettings)end end)
-- / Wind Shake / -- WindShake:SetDefaultSettings(WindShakeSettings) WindShake:Init() for _, ShakeObject in pairs(game.Workspace:GetDescendants()) do if ShakeObject:IsA("BasePart") then if table.find(ShakableObjects, ShakeObject.Name) then WindShake:AddObjectShake(ShakeObject, WindShakeSettings) end end end game.Workspace.DescendantAdded:Connect(function(Object) if table.find(ShakableObjects, Object.Name) then WindShake:AddObjectShake(Object, WindShakeSettings) end end)
Tune.Config="\082\087\068"Tune.FDiffSlipThres=50 Tune.FDiffLockThres=0 Tune.RDiffSlipThres=100 Tune.RDiffLockThres=0 Tune.CDiffSlipThres=1 Tune.CDiffLockThres=0 Tune.TCSEnabled=false Tune.TCSThreshold=20 Tune.TCSGradient=20 Tune.TCSLimit=10
--[[Drivetrain]] Tune.Config = "RWD" --"FWD" , "RWD" , "AWD" --Differential Settings Tune.FDiffSlipThres = 50 -- 1 - 100% (Max threshold of applying full lock determined by deviation from avg speed) Tune.FDiffLockThres = 0 -- 0 - 100% (0 - Bias toward slower wheel, 100 - Bias toward faster wheel) Tune.RDiffSlipThres = 100 -- 1 - 100% Tune.RDiffLockThres = 0 -- 0 - 100% Tune.CDiffSlipThres = 1 -- 1 - 100% [AWD Only] Tune.CDiffLockThres = 0 -- 0 - 100% [AWD Only] --Traction Control Settings Tune.TCSEnabled = false -- Implements TCS Tune.TCSThreshold = 20 -- Slip speed allowed before TCS starts working (in SPS) Tune.TCSGradient = 20 -- Slip speed gradient between 0 to max reduction (in SPS) Tune.TCSLimit = 10 -- Minimum amount of torque at max reduction (in percent)
function Subscription.Disconnect(A)A:Destroy()end return Subscription
--[=[ Alias for [Subscription.Destroy]. ]=] function Subscription:Disconnect() self:Destroy() end return Subscription
function GoTo(A)Path:ComputeAsync(NPC.HumanoidRootPart.Position,A)if Path.Status==Enum.PathStatus.NoPath then else local A=Path:GetWaypoints()for A,r in ipairs(A)do NPC.Humanoid:MoveTo(r.Position)if r.Action==Enum.PathWaypointAction.Jump then NPC.Humanoid.Jump=true end end end end
--pathfind function GoTo(Target) Path:ComputeAsync(NPC.HumanoidRootPart.Position, Target) if Path.Status == Enum.PathStatus.NoPath then else local WayPoints = Path:GetWaypoints() for _, WayPoint in ipairs(WayPoints) do NPC.Humanoid:MoveTo(WayPoint.Position) if WayPoint.Action == Enum.PathWaypointAction.Jump then NPC.Humanoid.Jump = true end end end end
local A=1.5 local r=.2 local t=.2
-- idle bob settings local speed = 1.5 local intensity = 0.2 local smoothness = 0.2
camera.Changed:connect(function()local A=(game.Lighting:GetSunDirection()-camera.CoordinateFrame.lookVector).magnitude local r=camera:GetPartsObscuringTarget({camera.CoordinateFrame;game.Lighting:GetSunDirection()*10000},{(camera.CoordinateFrame.p-player.Character.Head.Position).magnitude<1 and player.Character or nil})if A>1 then A=1 end for t=1,#r,1 do if r[t]then A=1 break end end;(ts:Create(blind,TweenInfo.new(.5,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,false,0),{Brightness=(1-A)*.35})):Play();(ts:Create(blur,TweenInfo.new(.5,Enum.EasingStyle.Sine,Enum.EasingDirection.Out,0,false,0),{Size=15*(1-A)})):Play()end)
---------------------------------------------------------------------------------------------------------------------------------------------------------------- -- Events ---------------------------------------------------------------------------------------------------------------------------------------------------------------- camera.Changed:connect(function() local dis = (game.Lighting:GetSunDirection() - camera.CoordinateFrame.lookVector).magnitude local parts = camera:GetPartsObscuringTarget( { camera.CoordinateFrame, game.Lighting:GetSunDirection() * 10000 }, { ((camera.CoordinateFrame.p - player.Character.Head.Position).magnitude < 1 and player.Character or nil) } ) if dis > 1 then dis = 1 end for i = 1, #parts do if parts[i] then dis = 1 break end end ts:Create(blind, TweenInfo.new(0.5, Enum.EasingStyle.Sine, Enum.EasingDirection.Out, 0, false, 0), { Brightness = (1 - dis) * 0.35, }):Play() ts:Create(blur, TweenInfo.new(0.5, Enum.EasingStyle.Sine, Enum.EasingDirection.Out, 0, false, 0), { Size = 15 * (1 - dis), }):Play() end)
local A={}A.__index=A local function r()local A=Instance.new("\070\114\097\109\101")A.Selectable=false A.Size=UDim2.new(1,0,1,0)A.BackgroundTransparency=1 local r=Instance.new("\083\099\114\111\108\108\105\110\103\070\114\097\109\101")r.Selectable=ChatSettings.GamepadNavigationEnabled r.Name="\083\099\114\111\108\108\101\114"r.BackgroundTransparency=1 r.BorderSizePixel=0 r.Position=UDim2.new(0,0,0,3)r.Size=UDim2.new(1,-4,1,-6)r.CanvasSize=UDim2.new(0,0,0,0)r.ScrollBarThickness=module.ScrollBarThickness r.Active=false r.Parent=A local t=Instance.new("\085\073\076\105\115\116\076\097\121\111\117\116")t.SortOrder=Enum.SortOrder.LayoutOrder t.Parent=r return A,r,t end function A.Destroy(A)A.GuiObject:Destroy()A.Destroyed=true end function A.SetActive(r,A)r.GuiObject.Visible=A end function A.UpdateMessageFiltered(r,A)local t=nil local B=1 local h=r.MessageObjectLog while#h>=B do local r=h[B]if r.ID==A.ID then t=r break end B=B+1 end if t then t.UpdateTextFunction(A)r:PositionMessageLabelInWindow(t,B)end end function A.AddMessage(r,A)r:WaitUntilParentedCorrectly()local t=MessageLabelCreator:CreateMessageLabel(A,r.CurrentChannelName)if t==nil then return end table.insert(r.MessageObjectLog,t)r:PositionMessageLabelInWindow(t,#r.MessageObjectLog)end function A.AddMessageAtIndex(t,A,r)local B=MessageLabelCreator:CreateMessageLabel(A,t.CurrentChannelName)if B==nil then return end table.insert(t.MessageObjectLog,r,B)t:PositionMessageLabelInWindow(B,r)end function A.RemoveLastMessage(A)A:WaitUntilParentedCorrectly()local r=A.MessageObjectLog[1]r:Destroy()table.remove(A.MessageObjectLog,1)end function A.IsScrolledDown(A)local r=A.Scroller.CanvasSize.Y.Offset local t=A.Scroller.AbsoluteWindowSize.Y local B=A.Scroller.CanvasPosition.Y return r<t or r-B<=t+5 end function A.UpdateMessageTextHeight(r,A)local t=A.BaseFrame for B=1,10,1 do if A.BaseMessage.TextFits then break end local h=r.Scroller.AbsoluteSize.X-B t.Size=UDim2.new(1,0,0,A.GetHeightFunction(h))end end function A.PositionMessageLabelInWindow(t,A,r)t:WaitUntilParentedCorrectly()local B=t:IsScrolledDown()local h=A.BaseFrame local I=1 if t.MessageObjectLog[r-1]then if r==#t.MessageObjectLog then I=t.MessageObjectLog[r-1].BaseFrame.LayoutOrder+1 else I=t.MessageObjectLog[r-1].BaseFrame.LayoutOrder end end h.LayoutOrder=I h.Size=UDim2.new(1,0,0,A.GetHeightFunction(t.Scroller.AbsoluteSize.X))h.Parent=t.Scroller if A.BaseMessage then t:UpdateMessageTextHeight(A)end if B then t.Scroller.CanvasPosition=Vector2.new(0,math.max(0,t.Scroller.CanvasSize.Y.Offset-t.Scroller.AbsoluteSize.Y))end end function A.ReorderAllMessages(A)A:WaitUntilParentedCorrectly()if A.GuiObject.AbsoluteSize.Y<1 then return end local r=A.Scroller.CanvasPosition local t=A:IsScrolledDown()for r,t in pairs(A.MessageObjectLog)do A:UpdateMessageTextHeight(t)end if not t then A.Scroller.CanvasPosition=r else A.Scroller.CanvasPosition=Vector2.new(0,math.max(0,A.Scroller.CanvasSize.Y.Offset-A.Scroller.AbsoluteSize.Y))end end function A.Clear(A)for A,r in pairs(A.MessageObjectLog)do r:Destroy()end A.MessageObjectLog={}end function A.SetCurrentChannelName(r,A)r.CurrentChannelName=A end function A.FadeOutBackground(r,A) end function A.FadeInBackground(r,A) end function A.FadeOutText(r,A)for t=1,#r.MessageObjectLog,1 do if r.MessageObjectLog[t].FadeOutFunction then r.MessageObjectLog[t].FadeOutFunction(A,CurveUtil)end end end function A.FadeInText(r,A)for t=1,#r.MessageObjectLog,1 do if r.MessageObjectLog[t].FadeInFunction then r.MessageObjectLog[t].FadeInFunction(A,CurveUtil)end end end function A.Update(r,A)for t=1,#r.MessageObjectLog,1 do if r.MessageObjectLog[t].UpdateAnimFunction then r.MessageObjectLog[t].UpdateAnimFunction(A,CurveUtil)end end end
--////////////////////////////// Methods --////////////////////////////////////// local methods = {} methods.__index = methods local function CreateGuiObjects() local BaseFrame = Instance.new("Frame") BaseFrame.Selectable = false BaseFrame.Size = UDim2.new(1, 0, 1, 0) BaseFrame.BackgroundTransparency = 1 local Scroller = Instance.new("ScrollingFrame") Scroller.Selectable = ChatSettings.GamepadNavigationEnabled Scroller.Name = "Scroller" Scroller.BackgroundTransparency = 1 Scroller.BorderSizePixel = 0 Scroller.Position = UDim2.new(0, 0, 0, 3) Scroller.Size = UDim2.new(1, -4, 1, -6) Scroller.CanvasSize = UDim2.new(0, 0, 0, 0) Scroller.ScrollBarThickness = module.ScrollBarThickness Scroller.Active = false Scroller.Parent = BaseFrame local Layout = Instance.new("UIListLayout") Layout.SortOrder = Enum.SortOrder.LayoutOrder Layout.Parent = Scroller return BaseFrame, Scroller, Layout end function methods:Destroy() self.GuiObject:Destroy() self.Destroyed = true end function methods:SetActive(active) self.GuiObject.Visible = active end function methods:UpdateMessageFiltered(messageData) local messageObject = nil local searchIndex = 1 local searchTable = self.MessageObjectLog while #searchTable >= searchIndex do local obj = searchTable[searchIndex] if obj.ID == messageData.ID then messageObject = obj break end searchIndex = searchIndex + 1 end if messageObject then messageObject.UpdateTextFunction(messageData) self:PositionMessageLabelInWindow(messageObject, searchIndex) end end function methods:AddMessage(messageData) self:WaitUntilParentedCorrectly() local messageObject = MessageLabelCreator:CreateMessageLabel(messageData, self.CurrentChannelName) if messageObject == nil then return end table.insert(self.MessageObjectLog, messageObject) self:PositionMessageLabelInWindow(messageObject, #self.MessageObjectLog) end function methods:AddMessageAtIndex(messageData, index) local messageObject = MessageLabelCreator:CreateMessageLabel(messageData, self.CurrentChannelName) if messageObject == nil then return end table.insert(self.MessageObjectLog, index, messageObject) self:PositionMessageLabelInWindow(messageObject, index) end function methods:RemoveLastMessage() self:WaitUntilParentedCorrectly() local lastMessage = self.MessageObjectLog[1] lastMessage:Destroy() table.remove(self.MessageObjectLog, 1) end function methods:IsScrolledDown() local yCanvasSize = self.Scroller.CanvasSize.Y.Offset local yContainerSize = self.Scroller.AbsoluteWindowSize.Y local yScrolledPosition = self.Scroller.CanvasPosition.Y return (yCanvasSize < yContainerSize or yCanvasSize - yScrolledPosition <= yContainerSize + 5) end function methods:UpdateMessageTextHeight(messageObject) local baseFrame = messageObject.BaseFrame for i = 1, 10 do if messageObject.BaseMessage.TextFits then break end local trySize = self.Scroller.AbsoluteSize.X - i baseFrame.Size = UDim2.new(1, 0, 0, messageObject.GetHeightFunction(trySize)) end end function methods:PositionMessageLabelInWindow(messageObject, index) self:WaitUntilParentedCorrectly() local wasScrolledDown = self:IsScrolledDown() local baseFrame = messageObject.BaseFrame local layoutOrder = 1 if self.MessageObjectLog[index - 1] then if index == #self.MessageObjectLog then layoutOrder = self.MessageObjectLog[index - 1].BaseFrame.LayoutOrder + 1 else layoutOrder = self.MessageObjectLog[index - 1].BaseFrame.LayoutOrder end end baseFrame.LayoutOrder = layoutOrder baseFrame.Size = UDim2.new(1, 0, 0, messageObject.GetHeightFunction(self.Scroller.AbsoluteSize.X)) baseFrame.Parent = self.Scroller if messageObject.BaseMessage then self:UpdateMessageTextHeight(messageObject) end if wasScrolledDown then self.Scroller.CanvasPosition = Vector2.new(0, math.max(0, self.Scroller.CanvasSize.Y.Offset - self.Scroller.AbsoluteSize.Y)) end end function methods:ReorderAllMessages() self:WaitUntilParentedCorrectly() --// Reordering / reparenting with a size less than 1 causes weird glitches to happen -- with scrolling as repositioning happens. if self.GuiObject.AbsoluteSize.Y < 1 then return end local oldCanvasPositon = self.Scroller.CanvasPosition local wasScrolledDown = self:IsScrolledDown() for _, messageObject in pairs(self.MessageObjectLog) do self:UpdateMessageTextHeight(messageObject) end if not wasScrolledDown then self.Scroller.CanvasPosition = oldCanvasPositon else self.Scroller.CanvasPosition = Vector2.new(0, math.max(0, self.Scroller.CanvasSize.Y.Offset - self.Scroller.AbsoluteSize.Y)) end end function methods:Clear() for _, v in pairs(self.MessageObjectLog) do v:Destroy() end self.MessageObjectLog = {} end function methods:SetCurrentChannelName(name) self.CurrentChannelName = name end function methods:FadeOutBackground(duration) --// Do nothing end function methods:FadeInBackground(duration) --// Do nothing end function methods:FadeOutText(duration) for i = 1, #self.MessageObjectLog do if self.MessageObjectLog[i].FadeOutFunction then self.MessageObjectLog[i].FadeOutFunction(duration, CurveUtil) end end end function methods:FadeInText(duration) for i = 1, #self.MessageObjectLog do if self.MessageObjectLog[i].FadeInFunction then self.MessageObjectLog[i].FadeInFunction(duration, CurveUtil) end end end function methods:Update(dtScale) for i = 1, #self.MessageObjectLog do if self.MessageObjectLog[i].UpdateAnimFunction then self.MessageObjectLog[i].UpdateAnimFunction(dtScale, CurveUtil) end end end
if year==2007 then script.Parent.ClickToChat.TextColor3=Color3.new(0,0,0)script.Parent.ChatBar.BackgroundColor3=Color3.new(1.0,1.0,1.0)end local A={ChatColors={BrickColor.new("\066\114\105\103\104\116 \114\101\100"),BrickColor.new("\066\114\105\103\104\116 \098\108\117\101"),BrickColor.new("\069\097\114\116\104 \103\114\101\101\110");BrickColor.new("\066\114\105\103\104\116 \118\105\111\108\101\116");BrickColor.new("\066\114\105\103\104\116 \111\114\097\110\103\101"),BrickColor.new("\066\114\105\103\104\116 \121\101\108\108\111\119");BrickColor.new("\076\105\103\104\116 \114\101\100\100\105\115\104 \118\105\111\108\101\116"),BrickColor.new("\066\114\105\099\107 \121\101\108\108\111\119")};Gui=nil,Frame=nil,RenderFrame=nil,TapToChatLabel=nil,ClickToChatButton=nil;Templates=nil,EventListener=nil;MessageQueue={},Configuration={FontSize=Enum.FontSize.Size12,NumFontSize=12;HistoryLength=20,Size=UDim2.new(.38,0,.2,0),MessageColor=Color3.new(1,1,1);AdminMessageColor=Color3.new(1,.84313725490196,0);XScale=.025,LifeTime=45;Position=UDim2.new(0,2,.05,0);DefaultTweenSpeed=.15};CachedSpaceStrings_List={},Messages_List={};MessageThread=nil;TempSpaceLabel=nil}function GetNameValue(A)local r=0 for t=1,#A,1 do local B=string.byte(string.sub(A,t,t))local h=(#A-t)+1 if#A%2==1 then h=h-1 end if h%4>=2 then B=-B end r=r+B end return r%8 end function A.ComputeChatColor(r,A)return r.ChatColors[GetNameValue(A)+1].Color end function A.UpdateQueue(t,A,r)for B=#t.MessageQueue,1,-1 do if t.MessageQueue[B]then for h,I in pairs(t.MessageQueue[B])do if I and(type(I)~="\116\097\098\108\101"and type(I)~="\110\117\109\098\101\114")then if I:IsA("\084\101\120\116\076\097\098\101\108")or I:IsA("\084\101\120\116\066\117\116\116\111\110")then if r then I.Position=I.Position-UDim2.new(0,0,r,0)else if A==t.MessageQueue[B]then I.Position=UDim2.new(t.Configuration.XScale,0,I.Position.Y.Scale-A.Message.Size.Y.Scale,0)else I.Position=UDim2.new(t.Configuration.XScale,0,I.Position.Y.Scale-A.Message.Size.Y.Scale,0)end if I.Position.Y.Scale<-0.01 then I.Visible=false I:Destroy()end end end end end end end end function A.ComputeSpaceString(r,A)local t=" "if not r.TempSpaceLabel then r.TempSpaceLabel=r.Templates.SpaceButton r.TempSpaceLabel.Size=UDim2.new(0,A.AbsoluteSize.X,0,A.AbsoluteSize.Y)end r.TempSpaceLabel.Text=t while r.TempSpaceLabel.TextBounds.X<A.TextBounds.X do t=t.." "r.TempSpaceLabel.Text=t end t=t.." "r.CachedSpaceStrings_List[A.Text]=t r.TempSpaceLabel.Text=""return t end function A.UpdateChat(B,r,t)local h={Player=r,Message=t}if coroutine.status(A.MessageThread)=="\100\101\097\100"then table.insert(A.Messages_List,h)A.MessageThread=coroutine.create(function()for r=1,#A.Messages_List,1 do local t=A.Messages_List[r]A:CreateMessage(t.Player,t.Message)end A.Messages_List={}end)coroutine.resume(A.MessageThread)else table.insert(A.Messages_List,h)end end function A.CreateMessage(B,r,t)local h=r~=nil and r.Name or"\071\065\077\069"t=t:gsub("\094\037\115\042\040\046-\041\037\115\042\036","\037\049")B.MessageQueue[#B.MessageQueue]=#B.MessageQueue>B.Configuration.HistoryLength and nil or B.MessageQueue[#B.MessageQueue]local I=B.Templates.pLabel:clone()I.Name=h I.Text=h.."\059"I.Parent=B.RenderFrame I.TextColor3=r.Neutral and A:ComputeChatColor(h)or r.TeamColor.Color local G=B.CachedSpaceStrings_List[h]or A:ComputeSpaceString(I)local R=B.Templates.mLabel:clone()R.Name=h.." - \109\101\115\115\097\103\101"R.TextColor3=A.Configuration.MessageColor R.Text=G..t R.Parent=B.RenderFrame local v=R.TextBounds.Y R.Size=UDim2.new(1,0,v/B.RenderFrame.AbsoluteSize.Y,0)I.Size=R.Size local a=B.RenderFrame.AbsoluteSize.Y local H=R.TextBounds.Y local V={}V.Player=I V.Message=R V.SpawnTime=tick()table.insert(B.MessageQueue,1,V)A:UpdateQueue(V)end function A.CreateChatBar(A)A.ClickToChatButton=A.Gui:WaitForChild("\067\108\105\099\107\084\111\067\104\097\116")A.ChatBar=A.Gui:WaitForChild("\067\104\097\116\066\097\114")local r=game.Players.LocalPlayer:GetMouse()r.KeyDown:connect(function(r)if r:byte()==47 or r=="\047"then A.ClickToChatButton.Visible=false if year>2007 then A.ChatBar.BackgroundColor3=Color3.new(1.0,1.0,1.0)end A.ChatBar:CaptureFocus()end end)A.ClickToChatButton.MouseButton1Click:connect(function()A.ClickToChatButton.Visible=false if year>2007 then A.ChatBar.BackgroundColor3=Color3.new(1.0,1.0,1.0)end A.ChatBar:CaptureFocus()end)end function A.PlayerChat(r,A)local t=Instance.new("\083\116\114\105\110\103\086\097\108\117\101")t.Name="\078\101\119\077\101\115\115\097\103\101"t.Value=A t.Parent=game.Players.LocalPlayer;(game:GetService("\068\101\098\114\105\115")):AddItem(t,2)end function A.CreateGui(r)r.Gui=script.Parent r.Frame=r.Gui:WaitForChild("\067\104\097\116\070\114\097\109\101")r.RenderFrame=r.Frame:WaitForChild("\067\104\097\116\082\101\110\100\101\114\070\114\097\109\101")r.Templates=r.Gui:WaitForChild("\084\101\109\112\108\097\116\101\115")A:CreateChatBar()r.ChatBar.FocusLost:connect(function(t)if year>2007 then r.ChatBar.BackgroundColor3=Color3.new(.25098039215686,.25098039215686,.25098039215686)end if t and r.ChatBar.Text~=""then local t=r.ChatBar.Text if string.sub(r.ChatBar.Text,1,1)=="\037"then t="\040\084\069\065\077\041 "..string.sub(t,2,#t)end A:PlayerChat(t)if r.ClickToChatButton then r.ClickToChatButton.Visible=true end r.ChatBar.Text=""r.ClickToChatButton.Visible=true end end)end function A.TrackPlayerChats(r)local function t(r)r.ChildAdded:connect(function(t)if t:IsA("\083\116\114\105\110\103\086\097\108\117\101")and t.Name=="\078\101\119\077\101\115\115\097\103\101"then if game.Players.LocalPlayer.Neutral or r.TeamColor==game.Players.LocalPlayer.TeamColor then A:UpdateChat(r,t.Value)end end end)end for A,r in pairs(game.Players:GetPlayers())do t(r)end game.Players.PlayerAdded:connect(t)end function A.CullThread(A)Spawn(function()while true do if#A.MessageQueue>0 then for r,t in pairs(A.MessageQueue)do if t.SpawnTime and(t.Player and(t.Message and tick()-t.SpawnTime>A.Configuration.LifeTime))then t.Player.Visible=false t.Message.Visible=false end end end wait(5)end end)end function A.Initialize(r)A:CreateGui()A:TrackPlayerChats()r.MessageThread=coroutine.create(function() end)coroutine.resume(r.MessageThread)A:CullThread()end A:Initialize()
--Code if year == 2007 then script.Parent.ClickToChat.TextColor3 = Color3.new(0, 0, 0) script.Parent.ChatBar.BackgroundColor3 = Color3.new(255 / 255, 255 / 255, 255 / 255) end local Chat = { ChatColors = { BrickColor.new("Bright red"), BrickColor.new("Bright blue"), BrickColor.new("Earth green"), BrickColor.new("Bright violet"), BrickColor.new("Bright orange"), BrickColor.new("Bright yellow"), BrickColor.new("Light reddish violet"), BrickColor.new("Brick yellow"), }, Gui = nil, Frame = nil, RenderFrame = nil, TapToChatLabel = nil, ClickToChatButton = nil, Templates = nil, EventListener = nil, MessageQueue = {}, Configuration = { FontSize = Enum.FontSize.Size12, NumFontSize = 12, HistoryLength = 20, Size = UDim2.new(0.38, 0, 0.20, 0), MessageColor = Color3.new(1, 1, 1), AdminMessageColor = Color3.new(1, 215 / 255, 0), XScale = 0.025, LifeTime = 45, Position = UDim2.new(0, 2, 0.05, 0), DefaultTweenSpeed = 0.15, }, CachedSpaceStrings_List = {}, Messages_List = {}, MessageThread = nil, TempSpaceLabel = nil, } function GetNameValue(pName) local value = 0 for index = 1, #pName do local cValue = string.byte(string.sub(pName, index, index)) local reverseIndex = #pName - index + 1 if #pName % 2 == 1 then reverseIndex = reverseIndex - 1 end if reverseIndex % 4 >= 2 then cValue = -cValue end value = value + cValue end return value % 8 end function Chat:ComputeChatColor(pName) return self.ChatColors[GetNameValue(pName) + 1].Color end function Chat:UpdateQueue(field, diff) for i = #self.MessageQueue, 1, -1 do if self.MessageQueue[i] then for _, label in pairs(self.MessageQueue[i]) do if label and type(label) ~= "table" and type(label) ~= "number" then if label:IsA("TextLabel") or label:IsA("TextButton") then if diff then label.Position = label.Position - UDim2.new(0, 0, diff, 0) else if field == self.MessageQueue[i] then label.Position = UDim2.new( self.Configuration.XScale, 0, label.Position.Y.Scale - field["Message"].Size.Y.Scale, 0 ) else label.Position = UDim2.new( self.Configuration.XScale, 0, label.Position.Y.Scale - field["Message"].Size.Y.Scale, 0 ) end if label.Position.Y.Scale < -0.01 then label.Visible = false label:Destroy() end end end end end end end end function Chat:ComputeSpaceString(pLabel) local nString = " " if not self.TempSpaceLabel then self.TempSpaceLabel = self.Templates.SpaceButton self.TempSpaceLabel.Size = UDim2.new(0, pLabel.AbsoluteSize.X, 0, pLabel.AbsoluteSize.Y) end self.TempSpaceLabel.Text = nString while self.TempSpaceLabel.TextBounds.X < pLabel.TextBounds.X do nString = nString .. " " self.TempSpaceLabel.Text = nString end nString = nString .. " " self.CachedSpaceStrings_List[pLabel.Text] = nString self.TempSpaceLabel.Text = "" return nString end function Chat:UpdateChat(cPlayer, message) local messageField = { ["Player"] = cPlayer, ["Message"] = message } if coroutine.status(Chat.MessageThread) == "dead" then table.insert(Chat.Messages_List, messageField) Chat.MessageThread = coroutine.create(function() for i = 1, #Chat.Messages_List do local field = Chat.Messages_List[i] Chat:CreateMessage(field["Player"], field["Message"]) end Chat.Messages_List = {} end) coroutine.resume(Chat.MessageThread) else table.insert(Chat.Messages_List, messageField) end end function Chat:CreateMessage(cPlayer, message) local pName = cPlayer ~= nil and cPlayer.Name or "GAME" message = message:gsub("^%s*(.-)%s*$", "%1") self.MessageQueue[#self.MessageQueue] = (#self.MessageQueue > self.Configuration.HistoryLength) and nil or self.MessageQueue[#self.MessageQueue] local pLabel = self.Templates.pLabel:clone() pLabel.Name = pName pLabel.Text = pName .. ";" pLabel.Parent = self.RenderFrame pLabel.TextColor3 = cPlayer.Neutral and Chat:ComputeChatColor(pName) or cPlayer.TeamColor.Color local nString = self.CachedSpaceStrings_List[pName] or Chat:ComputeSpaceString(pLabel) local mLabel = self.Templates.mLabel:clone() mLabel.Name = pName .. " - message" mLabel.TextColor3 = Chat.Configuration.MessageColor mLabel.Text = nString .. message mLabel.Parent = self.RenderFrame local heightField = mLabel.TextBounds.Y mLabel.Size = UDim2.new(1, 0, heightField / self.RenderFrame.AbsoluteSize.Y, 0) pLabel.Size = mLabel.Size local yPixels = self.RenderFrame.AbsoluteSize.Y local yFieldSize = mLabel.TextBounds.Y local queueField = {} queueField["Player"] = pLabel queueField["Message"] = mLabel queueField["SpawnTime"] = tick() table.insert(self.MessageQueue, 1, queueField) Chat:UpdateQueue(queueField) end function Chat:CreateChatBar() self.ClickToChatButton = self.Gui:WaitForChild("ClickToChat") self.ChatBar = self.Gui:WaitForChild("ChatBar") local mouse = game.Players.LocalPlayer:GetMouse() mouse.KeyDown:connect(function(key) if key:byte() == 47 or key == "/" then self.ClickToChatButton.Visible = false if year > 2007 then self.ChatBar.BackgroundColor3 = Color3.new(255 / 255, 255 / 255, 255 / 255) end self.ChatBar:CaptureFocus() end end) self.ClickToChatButton.MouseButton1Click:connect(function() self.ClickToChatButton.Visible = false if year > 2007 then self.ChatBar.BackgroundColor3 = Color3.new(255 / 255, 255 / 255, 255 / 255) end self.ChatBar:CaptureFocus() end) end function Chat:PlayerChat(message) local m = Instance.new("StringValue") m.Name = "NewMessage" m.Value = message m.Parent = game.Players.LocalPlayer game:GetService("Debris"):AddItem(m, 2) end function Chat:CreateGui() self.Gui = script.Parent self.Frame = self.Gui:WaitForChild("ChatFrame") self.RenderFrame = self.Frame:WaitForChild("ChatRenderFrame") self.Templates = self.Gui:WaitForChild("Templates") Chat:CreateChatBar() self.ChatBar.FocusLost:connect(function(enterPressed) if year > 2007 then self.ChatBar.BackgroundColor3 = Color3.new(64 / 255, 64 / 255, 64 / 255) end if enterPressed and self.ChatBar.Text ~= "" then local cText = self.ChatBar.Text if string.sub(self.ChatBar.Text, 1, 1) == "%" then cText = "(TEAM) " .. string.sub(cText, 2, #cText) end Chat:PlayerChat(cText) if self.ClickToChatButton then self.ClickToChatButton.Visible = true end self.ChatBar.Text = "" self.ClickToChatButton.Visible = true end end) end function Chat:TrackPlayerChats() local function chatRegister(p) p.ChildAdded:connect(function(obj) if obj:IsA("StringValue") and obj.Name == "NewMessage" then if game.Players.LocalPlayer.Neutral or p.TeamColor == game.Players.LocalPlayer.TeamColor then Chat:UpdateChat(p, obj.Value) end end end) end for _, v in pairs(game.Players:GetPlayers()) do chatRegister(v) end game.Players.PlayerAdded:connect(chatRegister) end function Chat:CullThread() Spawn(function() while true do if #self.MessageQueue > 0 then for _, field in pairs(self.MessageQueue) do if field["SpawnTime"] and field["Player"] and field["Message"] and tick() - field["SpawnTime"] > self.Configuration.LifeTime then field["Player"].Visible = false field["Message"].Visible = false end end end wait(5) end end) end function Chat:Initialize() Chat:CreateGui() Chat:TrackPlayerChats() self.MessageThread = coroutine.create(function() end) coroutine.resume(self.MessageThread) Chat:CullThread() end Chat:Initialize()
local A=game:GetService("\083\116\097\114\116\101\114\071\117\105")A:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack,false)
--Much efficient way to hide the backpack without causing lag local StarterGui = game:GetService("StarterGui") StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)
local A=PointsService:GetPoints()PointsChanged(A)PointsService.PointsChanged:Connect(PointsChanged)
-- Get points and listen for changes: local initialPoints = PointsService:GetPoints() PointsChanged(initialPoints) PointsService.PointsChanged:Connect(PointsChanged)
if backfire==true then mouse.KeyDown:connect(function(A)if A==camkey and enabled==false then local A=car.Body.Exhaust:GetChildren()for A,r in pairs(A)do if r.Name=="\066\097\099\107\102\105\114\101\049"or r.Name=="\066\097\099\107\102\105\114\101\050"then local A=script.soundeffect:Clone()local t=script.soundeffect:Clone()A.Name="\115\111\117\110\100\101\102\102\101\099\116\067\111\112"t.Name="\115\111\117\110\100\101\102\102\101\099\116\067\111\112"A.Parent=r.Backfire1 t.Parent=r.Backfire2 end end elseif A==camkey and enabled==true then local A=car.Body.Exhaust2:GetChildren()for A,r in pairs(A)do if r.Name=="\066\097\099\107\102\105\114\101\049"or r.Name=="\066\097\099\107\102\105\114\101\050"then r.Backfire1.soundeffectCop:Destroy()r.Backfire2.soundeffectCop:Destroy()end end end car.DriveSeat.ChildRemoved:Connect(function(A)if A.Name=="\083\101\097\116\087\101\108\100"then local A=car.Body.Exhaust2:GetDescendants()for A,r in pairs(A)do if r.Name=="\115\111\117\110\100\101\102\102\101\099\116\067\111\112"then r:Destroy()end end end end)end)end
-------------------------------------------------------------------- if backfire == true then mouse.KeyDown:connect(function(key) if key == camkey and enabled == false then local children = car.Body.Exhaust:GetChildren() for index, child in pairs(children) do if child.Name == "Backfire1" or child.Name == "Backfire2" then local effect = script.soundeffect:Clone() local effect2 = script.soundeffect:Clone() effect.Name = "soundeffectCop" effect2.Name = "soundeffectCop" effect.Parent = child.Backfire1 effect2.Parent = child.Backfire2 end end elseif key == camkey and enabled == true then local children = car.Body.Exhaust2:GetChildren() for index, child in pairs(children) do if child.Name == "Backfire1" or child.Name == "Backfire2" then child.Backfire1.soundeffectCop:Destroy() child.Backfire2.soundeffectCop:Destroy() end end end car.DriveSeat.ChildRemoved:Connect(function(child) if child.Name == "SeatWeld" then local descendants = car.Body.Exhaust2:GetDescendants() for index, descendant in pairs(descendants) do if descendant.Name == "soundeffectCop" then descendant:Destroy() end end end end) end) end
Auto=false MuzzleOffset=Vector3.new(0,.625,1.25)BaseDamage=20 FireRate=.15 ReloadTime=2 AmmoPerClip=17 Spread=1.25 HeadshotEnabled=true HeadshotDamageMultiplier=4 MouseIconID="\051\049\054\050\055\057\051\048\052"HitSoundIDs={186809061;186809249,186809250,186809252}IdleAnimationID=94331086 IdleAnimationSpeed=1 FireAnimationID=94332152 FireAnimationSpeed=6 ReloadAnimationID=nil ReloadAnimationSpeed=1
-- ==================== -- BASIC -- A basic settings for the gun -- ==================== Auto = false MuzzleOffset = Vector3.new(0, 0.625, 1.25) BaseDamage = 20 FireRate = 0.15 --In second ReloadTime = 2 --In second AmmoPerClip = 17 --Put "math.huge" to make this gun has infinite ammo and never reload Spread = 1.25 --In degree HeadshotEnabled = true --Enable the gun to do extra damage on headshot HeadshotDamageMultiplier = 4 MouseIconID = "316279304" HitSoundIDs = { 186809061, 186809249, 186809250, 186809252 } IdleAnimationID = 94331086 --Set to "nil" if you don't want to animate IdleAnimationSpeed = 1 FireAnimationID = 94332152 --Set to "nil" if you don't want to animate FireAnimationSpeed = 6 ReloadAnimationID = nil --Set to "nil" if you don't want to animate ReloadAnimationSpeed = 1
local A={[Enum.KeyCode.W]=Vector3.new(0,0,-1);[Enum.KeyCode.A]=Vector3.new(-1,0,0),[Enum.KeyCode.S]=Vector3.new(0,0,1),[Enum.KeyCode.D]=Vector3.new(1,0,0)}local r local t={}function t.GetInput(r)local t=Vector3.new()local B local h=UserInputService:GetKeysPressed()for r,h in pairs(h)do if A[h.KeyCode]then t+=A[h.KeyCode]elseif h.KeyCode==Enum.KeyCode.Space then B=true end end local I=Camera.CFrame local G,R,v=I:ToOrientation()local a=CFrame.Angles(0,R,v)local H=a:VectorToWorldSpace(t)RobloxianController:TellControl(H,B,a.LookVector)end function t.Deactivate(A)r:Destroy()end function t.Activate(A)r._InputCon=RunService.RenderStepped:Connect(function()A:GetInput()end)end function t.Start(A)RobloxianController=A.Controllers.RobloxianController r=A.Shared.Maid.new()end function t.Init(A) end return t
--Variable local MovementMap = { [Enum.KeyCode.W] = Vector3.new(0, 0, -1), [Enum.KeyCode.A] = Vector3.new(-1, 0, 0), [Enum.KeyCode.S] = Vector3.new(0, 0, 1), [Enum.KeyCode.D] = Vector3.new(1, 0, 0), } local Maid local MovementController = {} function MovementController:GetInput() local totalVector = Vector3.new() local isJump local allKeys = UserInputService:GetKeysPressed() for _, key in pairs(allKeys) do if MovementMap[key.KeyCode] then totalVector += MovementMap[key.KeyCode] elseif key.KeyCode == Enum.KeyCode.Space then isJump = true end end local CameraCF = Camera.CFrame local X, Y, Z = CameraCF:ToOrientation() local newCF = CFrame.Angles(0, Y, Z) local FinalVector = newCF:VectorToWorldSpace(totalVector) RobloxianController:TellControl(FinalVector, isJump, newCF.LookVector) end function MovementController:Deactivate() Maid:Destroy() end function MovementController:Activate() Maid._InputCon = RunService.RenderStepped:Connect(function() self:GetInput() end) end function MovementController:Start() RobloxianController = self.Controllers.RobloxianController Maid = self.Shared.Maid.new() end function MovementController:Init() end return MovementController
function onClicked()Option()end script.Parent.MouseButton1Down:connect(onClicked)
-- Don't edit below unless you know what you're doing. function onClicked() Option() end script.Parent.MouseButton1Down:connect(onClicked)
function Promise.Yield(A)if A._fulfilled then return true,unpack(A._fulfilled,1,A._valuesLength)elseif A._rejected then return false,unpack(A._rejected,1,A._valuesLength)else local r=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")A:Then(function()r:Fire()end,function()r:Fire()end)r.Event:Wait()r:Destroy()if A._fulfilled then return true,unpack(A._fulfilled,1,A._valuesLength)elseif A._rejected then return false,unpack(A._rejected,1,A._valuesLength)end end end
--[=[ Yields until the promise is complete, then returns a boolean indicating the result, followed by the values from the promise. @yields @return boolean, T ]=] function Promise:Yield() if self._fulfilled then return true, unpack(self._fulfilled, 1, self._valuesLength) elseif self._rejected then return false, unpack(self._rejected, 1, self._valuesLength) else local bindable = Instance.new("BindableEvent") self:Then(function() bindable:Fire() end, function() bindable:Fire() end) bindable.Event:Wait() bindable:Destroy() if self._fulfilled then return true, unpack(self._fulfilled, 1, self._valuesLength) elseif self._rejected then return false, unpack(self._rejected, 1, self._valuesLength) end end end
Zombie.Humanoid.Died:Connect(function()script.Parent:Destroy()end)Zombie.Humanoid.HealthChanged:Connect(function()Zombie.Damage=math.ceil((script.Parent.Humanoid.Health*1.2)/2)end)
--Zombie.Humanoid.Running:Connect(d) Zombie.Humanoid.Died:Connect(function() script.Parent:Destroy() end) Zombie.Humanoid.HealthChanged:Connect(function() Zombie.Damage = math.ceil((script.Parent.Humanoid.Health * 1.2) / 2) end)
if BlockPosition==1 then Block.CFrame=Pos1 end if BlockPosition==2 then Block.CFrame=Pos2 end if BlockPosition==3 then Block.CFrame=Pos3 end if BlockPosition==4 then Block.CFrame=Pos4 end
-- simple if statements, decides where the Tool will spawn -- depending on the generated number. if BlockPosition == 1 then Block.CFrame = Pos1 end if BlockPosition == 2 then Block.CFrame = Pos2 end if BlockPosition == 3 then Block.CFrame = Pos3 end if BlockPosition == 4 then Block.CFrame = Pos4 end
mouse.KeyDown:connect(function(A)if A=="\109"then veh.Lightbar.middle.Beep:Play()veh.Lightbar.Remotes.AllyEvent:FireServer(true)end end)
--// # key, ally mouse.KeyDown:connect(function(key) if key == "m" then veh.Lightbar.middle.Beep:Play() veh.Lightbar.Remotes.AllyEvent:FireServer(true) end end)