View difference between Paste ID: kcApDNqH and EpnYcD3f
SHOW: | | - or go back to the newest paste.
1
--[[
2
		Game Link: https://www.roblox.com/games/606849621/Jailbreak-JETPACKS
3
	       https://v3rmillion.net/showthread.php?tid=688367 
4
	Edited By LuaPhysics#6400 (Broke When Jewelry Store Is Opened)	
5
	      ***NOTE: Jewelry Removed Bescause Of The Error.***
6
 __                        ____    __                                           
7
/\ \                      /\  _`\ /\ \                      __                  
8
\ \ \      __  __     __  \ \ \L\ \ \ \___   __  __    ____/\_\    ___    ____  
9
 \ \ \  __/\ \/\ \  /'__`\ \ \ ,__/\ \  _ `\/\ \/\ \  /',__\/\ \  /'___\ /',__\ 
10
  \ \ \L\ \ \ \_\ \/\ \L\.\_\ \ \/  \ \ \ \ \ \ \_\ \/\__, `\ \ \/\ \__//\__, `\
11
   \ \____/\ \____/\ \__/.\_\\ \_\   \ \_\ \_\/`____ \/\____/\ \_\ \____\/\____/
12
    \/___/  \/___/  \/__/\/_/ \/_/    \/_/\/_/`/___/> \/___/  \/_/\/____/\/___/ 
13
                                                 /\___/                         
14
                                                 \/__/                          
15
--]]
16
if not getrawmetatable then
17
	local h = Instance.new("Hint",workspace)
18
	h.Text = "Incompatible exploit."
19
	wait(2)
20
	h:Destroy()
21
	return
22
end
23
local player = game:GetService("Players").LocalPlayer or game:GetService("Players"):GetPropertyChangedSignal("LocalPlayer"):Wait() or game:GetService("Players").LocalPlayer
24
local stepconn,uptorso,humanoid
25
local root = {}
26
local v30=Vector3.new()
27
local HOLD_E = false
28
local abort = false
29
local green,red=Color3.fromRGB(0,230,0),Color3.fromRGB(230,0,0)
30
local settings = {enabled=true,jewlAllowCrims=false,preferLongTP=false,bankRadius2=19,preferUnsafeEsc=false,warnSeconds=1.5}
31
local settingsModified = false
32
if readfile then
33
	pcall(function()
34
		local new = game:GetService("HttpService"):JSONDecode(readfile("JBAR.txt"))
35
		--corruption?
36
		local doOverwrite=false
37
		for k,v in pairs(new) do
38
			if settings[k]==nil then
39
				doOverwrite=true
40
				new[k]=nil
41
			end
42
		end
43
		for k,v in pairs(settings) do
44
			if new[k]==nil then
45
				doOverwrite=true
46
				new[k]=v
47
			end
48
		end
49
		--use input
50
		if doOverwrite then
51
			settingsModified = true
52
			writefile("JBAR.txt",game:GetService("HttpService"):JSONEncode(new))
53
		end
54
		settings = new
55
	end)
56
end
57
--// handle character //
58
local Stepped = game:GetService("RunService").Stepped
59
local NCparts = {}
60
local NCconn
61
local NCfunc = function()
62
	for i=1,#NCparts do
63
		NCparts[i].CanCollide=false
64
	end
65
end
66
local function noclip()
67
	if not NCconn then
68
		NCconn = Stepped:Connect(NCfunc)
69
	end
70
end
71
local function yesclip()
72
	if NCconn then
73
		NCconn:Disconnect()
74
		NCconn = nil
75
	end
76
end
77
local lastRootCf
78
local function onRootChanged()
79
	if (root.CFrame.p-Vector3.new(-177.3,19.6,1013.2)).magnitude < 1 then
80
		root.CFrame = lastRootCf
81
	end
82
end
83
local function newchar(char)
84
	if char then
85
		root = char:WaitForChild("HumanoidRootPart")
86
		root:GetPropertyChangedSignal("CFrame"):Connect(onRootChanged)
87
		uptorso = char:WaitForChild("UpperTorso")
88
		humanoid = char:WaitForChild("Humanoid")
89
		wait(0.2)
90
		NCparts = {}
91
		for _,v in ipairs(char:GetChildren()) do
92
			if v:IsA("BasePart") then
93
				NCparts[#NCparts+1]=v
94
			end
95
		end
96
	end
97
end
98
newchar(player.Character)
99
player.CharacterAdded:Connect(newchar)
100
Stepped:Connect(function()
101
	lastRootCf = root.CFrame
102
end)
103
--// interface //
104
Create = function(class,parent,props)
105
	local new = Instance.new(class)
106
	for k,v in next,props do
107
		new[k]=v
108
	end
109
	new.Parent = parent
110
	return new
111
end
112
113
gui=Create("ScreenGui",game.CoreGui,{Name="AutoRob", ResetOnSpawn=false, ZIndexBehavior="Sibling"})
114
main=Create("Frame",gui,{Name="Main", ClipsDescendants=true, Draggable=true, Active=true, Size=UDim2.new(0,333,0,140), Position=UDim2.new(0.1,0,0.3,0), BackgroundColor3=Color3.new(0,0.118,0.239)})
115
homeFrame=Create("Frame",main,{Name="homeFrame", BackgroundTransparency=1, Size=UDim2.new(1,-30,1,-55), Position=UDim2.new(0,15,0,40)})
116
AbortBtn=Create("TextButton",homeFrame,{Name="AbortBtn", Size=UDim2.new(0.48,0,0.3,0), Text="ABORT", Font="SourceSans", Position=UDim2.new(0.52,0,0.25,0), TextSize=23, 
117
	BackgroundColor3=Color3.new(0.502,0.498,0.506), AutoButtonColor=false})
118
Shade=Create("Frame",AbortBtn,{Name="Shade", BackgroundTransparency=0.89999997615814, Size=UDim2.new(1,0,0.5,0), Position=UDim2.new(0,0,0.5,0), BackgroundColor3=Color3.new(), Visible=false})
119
Status=Create("TextLabel",homeFrame,{Name="Status", Size=UDim2.new(1,0,0.27,0), Text="Status: Loading...", TextSize=15, TextXAlignment="Left", Font="Code", 
120
	BackgroundTransparency=0.25, Position=UDim2.new(0,0,0.73,0), BackgroundColor3=Color3.new(1,1,1)})
121
ToggleBtn=Create("TextButton",homeFrame,{Name="ToggleBtn", Size=UDim2.new(0.48,0,0.3,0), Text="TOGGLE", Font="SourceSans", Position=UDim2.new(0,0,0.25,0), TextSize=23, 
122
	BackgroundColor3=settings.enabled and green or red})
123
Shade_2=Create("Frame",ToggleBtn,{Name="Shade", BackgroundTransparency=0.89999997615814, Size=UDim2.new(1,0,0.5,0), Position=UDim2.new(0,0,0.5,0), BackgroundColor3=Color3.new()})
124
availabels=Create("Frame",homeFrame,{Name="availabels", BackgroundTransparency=1, Size=UDim2.new(1,0,0.23,0), Position=UDim2.new(0,0,-0.12,0), BackgroundColor3=Color3.new(1,1,1)})
125
jewelryLbl=Create("TextLabel",availabels,{Name="jewelryLbl", Size=UDim2.new(0.2,0,1,0), Text="Jewel", TextSize=18, Font="SourceSansLight", BackgroundTransparency=1, 
126
	Position=UDim2.new(0.2,0,0,0), TextColor3=Color3.new(1,1,1), BackgroundColor3=Color3.new(1,1,1)})
127
trainLbl=Create("TextLabel",availabels,{Name="trainLbl", Size=UDim2.new(0.2,0,1,0), Text="Train", TextSize=18, Font="SourceSansLight", BackgroundTransparency=1, 
128
	Position=UDim2.new(0.6,0,0,0), TextColor3=Color3.new(1,1,1), BackgroundColor3=Color3.new(1,1,1)})
129
bankLbl=Create("TextLabel",availabels,{Name="bankLbl", Size=UDim2.new(0.2,0,1,0), Text="Bank", TextSize=18, Font="SourceSansLight", BackgroundTransparency=1, 
130
	Position=UDim2.new(0.8,0,0,0), TextColor3=Color3.new(1,1,1), BackgroundColor3=Color3.new(1,1,1)})
131
airdropLbl=Create("TextLabel",availabels,{Name="airdropLbl", Size=UDim2.new(0.2,0,1,0), Text="Airdrop", TextSize=18, Font="SourceSansLight", BackgroundTransparency=1, 
132
	Position=UDim2.new(0.4,0,0,0), TextColor3=Color3.new(1,1,1), BackgroundColor3=Color3.new(1,1,1)})
133
museumLbl=Create("TextLabel",availabels,{Name="museumLbl", Size=UDim2.new(0.2,0,1,0), Text="Museum", TextSize=18, Font="SourceSansLight", BackgroundTransparency=1, 
134
	TextColor3=Color3.new(1,1,1), BackgroundColor3=Color3.new(1,1,1)})
135
CloseBtn=Create("TextButton",main,{Name="CloseBtn", TextWrapped=true, TextStrokeTransparency=0.69999998807907, Size=UDim2.new(0,25,0,25), TextColor3=Color3.new(0.9,0.9,0.9), Text="X", 
136
	BackgroundTransparency=1, Font="GothamBold", Position=UDim2.new(1,-22,0,0), TextScaled=true})
137
CogBtn=Create("ImageButton",main,{Name="CogBtn", Image="rbxassetid://135740223", Size=UDim2.new(0,25,0,25), Position=UDim2.new(0,0,0,2), BackgroundTransparency=1})
138
setsframe=Create("Frame",main,{Name="setsframe", BackgroundTransparency=0.019999999552965, Size=UDim2.new(1,-10,0.8,-10), Position=UDim2.new(-1,5,0.2,5), BorderSizePixel=0, BackgroundColor3=Color3.new(1,1,1)})
139
Frame=Create("Frame",setsframe,{BackgroundTransparency=1, Size=UDim2.new(1,0,0.25,0)})
140
BankRadiusBox=Create("TextBox",Frame,{Name="BankRadiusBox", TextWrapped=true, Size=UDim2.new(0,40,0,15), Text=settings.bankRadius2, Font="GothamSemibold", Position=UDim2.new(0.78,0,0.2,0), 
141
	TextScaled=true, BackgroundColor3=Color3.new(1,1,1)})
142
Label=Create("TextLabel",Frame,{TextWrapped=true, Size=UDim2.new(0.8,0,1,0), Text="Bank Cops Danger Range", TextSize=15, Font="Code", BackgroundTransparency=1})
143
Frame_2=Create("Frame",setsframe,{BackgroundTransparency=0.93000000715256, Size=UDim2.new(1,0,0.25,0), Position=UDim2.new(0,0,0.25,0), BackgroundColor3=Color3.new()})
144
JewlSetBtn=Create("TextButton",Frame_2,{Name="JewlSetBtn", Size=UDim2.new(0,25,0,15), Text=settings.jewlAllowCrims and 'X' or '', Font="SourceSansSemibold", Position=UDim2.new(0.8,0,0.2,0), TextSize=20, 
145
	BackgroundColor3=Color3.new(1,1,1)})
146
Label_2=Create("TextLabel",Frame_2,{TextWrapped=true, Size=UDim2.new(0.8,0,1,0), Text="Let Crims Enter Jewelry", TextSize=15, Font="Code", BackgroundTransparency=1})
147
Frame_3=Create("Frame",setsframe,{BackgroundTransparency=1, Size=UDim2.new(1,0,0.25,0), Position=UDim2.new(0,0,0.5,0)})
148
WarnSetBtn=Create("TextButton",Frame_3,{Name="WarnSetBtn", Size=UDim2.new(0,25,0,15), Text=settings.warnSeconds>1.51 and 'X' or '', Font="SourceSansSemibold", Position=UDim2.new(0.8,0,0.2,0), TextSize=20, 
149
	BackgroundColor3=Color3.new(1,1,1)})
150
Label_3=Create("TextLabel",Frame_3,{TextWrapped=true, Size=UDim2.new(0.8,0,1,0), Text="Prefer Longer Warnings", TextSize=15, Font="Code", BackgroundTransparency=1})
151
Frame_4=Create("Frame",setsframe,{BackgroundTransparency=0.93000000715256, Size=UDim2.new(1,0,0.25,0), Position=UDim2.new(0,0,0.75,0), BackgroundColor3=Color3.new()})
152
EscSetBtn=Create("TextButton",Frame_4,{Name="EscSetBtn", Size=UDim2.new(0,25,0,15), Text=settings.preferUnsafeEsc and 'X' or '', Font="SourceSansSemibold", Position=UDim2.new(0.8,0,0.2,0), TextSize=20, 
153
	BackgroundColor3=Color3.new(1,1,1)})
154
Label_4=Create("TextLabel",Frame_4,{TextWrapped=true, Size=UDim2.new(0.8,0,1,0), Text="Remember Your Position", TextSize=15, Font="Code", BackgroundTransparency=1})
155
Title=Create("TextLabel",main,{Name="Title", TextWrapped=true, Size=UDim2.new(0.5,0,0,20), Text="Jailbreak Auto-Rob", TextSize=18, Font="Highway", 
156
	BackgroundTransparency=1, Position=UDim2.new(0.24,0,0,3), TextColor3=Color3.new(0.9,0.9,0.9), BackgroundColor3=Color3.new(1,1,1)})
157
SaveSetsBtn=Create("TextButton",main,{Name="SaveSetsBtn", Size=UDim2.new(0,60,0,25), Text="Save", Font="SourceSans", Style="RobloxRoundDefaultButton", Position=UDim2.new(0,30,0,-25), 
158
	TextSize=20})
159
	
160
--gui code
161
CloseBtn.MouseButton1Click:Connect(function() gui:Destroy() abort=true end)
162
CloseBtn.MouseEnter:Connect(function() CloseBtn.TextColor3=red end)
163
CloseBtn.MouseLeave:Connect(function() CloseBtn.TextColor3=Color3.new(0.9,0.9,0.9) end)
164
local function toggleCanAbort(bool)
165
	AbortBtn.AutoButtonColor=bool
166
	AbortBtn.BackgroundColor3 = bool and Color3.new(0.353,0.557,0.914) or Color3.new(0.502,0.498,0.506)
167
	Shade.Visible = bool
168
	abort=false
169
end
170
AbortBtn.MouseButton1Click:Connect(function()
171
	if AbortBtn.AutoButtonColor then
172
		if stepconn then stepconn:Disconnect() end
173
		local hit,p = workspace:FindPartOnRay(Ray.new(player.Character.Head.Position+Vector3.new(0,10,0),Vector3.new(0,20,0)))
174
		if hit then
175
			player.Character:MoveTo(p)
176
		else
177
			local angle = math.random()*math.pi*2
178
			local door = workspace.Apartments.Skyscraper1.ExitDoor.Touch
179
			local oldcf = door.CFrame
180
			door.CFrame = root.CFrame
181
			wait()
182
			door.CFrame = oldcf
183
			root.CFrame = root.CFrame+Vector3.new(80*math.cos(angle),math.max(0,200-root.CFrame.y),80*math.sin(angle))
184
		end
185
		toggleCanAbort(false)
186
		abort=true
187
		AbortBtn.Text = "Aborted."
188
		wait(2.8)
189
		AbortBtn.Text = "ABORT"
190
	end
191
end)
192
local function setStatus(txt)
193
	Status.Text = "Status: "..txt
194
end
195
local tweenCogOut = game:GetService("TweenService"):Create(CogBtn,TweenInfo.new(0.25),{Rotation=135})
196
local tweenCogIn = game:GetService("TweenService"):Create(CogBtn,TweenInfo.new(0.25),{Rotation=0})
197
local cogOut = false
198
CogBtn.MouseButton1Click:Connect(function()
199
	cogOut = not cogOut
200
	if cogOut then
201
		setsframe:TweenPosition(UDim2.new(0,5,0.2,5),nil,"Quart",0.3,true)
202
		homeFrame:TweenPosition(UDim2.new(1,15,0,40),nil,"Quart",0.3,true)
203
		if writefile then SaveSetsBtn:TweenPosition(UDim2.new(0,30,0,2),nil,"Quart",0.3,true) end
204
		tweenCogOut:Play()
205
	else
206
		setsframe:TweenPosition(UDim2.new(-1,5,0.2,5),nil,"Quart",0.3,true)
207
		homeFrame:TweenPosition(UDim2.new(0,15,0,40),nil,"Quart",0.3,true)
208
		SaveSetsBtn:TweenPosition(UDim2.new(0,30,0,-25),nil,"Quart",0.3,true)
209
		tweenCogIn:Play()
210
	end
211
end)
212
local bankBoxOld=BankRadiusBox.Text
213
BankRadiusBox:GetPropertyChangedSignal("Text"):Connect(function()
214
	BankRadiusBox.Text=BankRadiusBox.Text:sub(1,4)
215
	local num = tonumber(BankRadiusBox.Text)
216
	if num then
217
		if num>99 then
218
			BankRadiusBox.Text = '99'
219
		end
220
	elseif BankRadiusBox.Text~='' then
221
		BankRadiusBox.Text = bankBoxOld
222
	end
223
	bankBoxOld = BankRadiusBox.Text
224
end)
225
BankRadiusBox.FocusLost:Connect(function()
226
	if tonumber(BankRadiusBox.Text) then
227
		settings.bankRadius2=tonumber(BankRadiusBox.Text)
228
	end
229
	BankRadiusBox.Text=tostring(settings.bankRadius2)
230
end)
231
JewlSetBtn.MouseButton1Click:Connect(function()
232
	settings.jewlAllowCrims = not settings.jewlAllowCrims
233
	JewlSetBtn.Text = settings.jewlAllowCrims and "X" or ""
234
end)
235
WarnSetBtn.MouseButton1Click:Connect(function()
236
	settings.warnSeconds = settings.warnSeconds>1.51 and 1.5 or 3
237
	WarnSetBtn.Text = settings.warnSeconds>1.51 and "X" or ""
238
end)
239
EscSetBtn.MouseButton1Click:Connect(function()
240
	settings.preferUnsafeEsc = not settings.preferUnsafeEsc
241
	EscSetBtn.Text = settings.preferUnsafeEsc and "X" or ""
242
end)
243
SaveSetsBtn.MouseButton1Click:Connect(function()
244
	if writefile and SaveSetsBtn.Style.Name=="RobloxRoundDefaultButton" then
245
		SaveSetsBtn.Style="RobloxRoundButton"
246
		writefile("JBAR.txt",game:GetService("HttpService"):JSONEncode(settings))
247
		SaveSetsBtn.Text="Saved."
248
		wait(1)
249
		SaveSetsBtn.Text="Save"
250
		SaveSetsBtn.Style="RobloxRoundDefaultButton"
251
	end
252
end)
253
ToggleBtn.MouseButton1Click:Connect(function()
254
	settings.enabled = not settings.enabled
255
	ToggleBtn.BackgroundColor3 = settings.enabled and green or red
256
end)
257
local function warnFlash(s)
258
	setStatus(s.." ready.")
259
	local col0 = main.BackgroundColor3
260
	local elapsed = 0
261
	while elapsed < settings.warnSeconds do
262
		for a=0,1,1/(30*.25) do
263
			main.BackgroundColor3 = col0:lerp(red,a)
264
			elapsed=elapsed+wait()
265
		end
266
		for a=0,1,1/(30*.25) do
267
			main.BackgroundColor3 = red:lerp(col0,a)
268
			elapsed=elapsed+wait()
269
		end
270
	end
271
	main.BackgroundColor3 = col0
272
end
273
--// vitals //
274
player:WaitForChild("PlayerScripts"):WaitForChild("LocalScript")
275
wait(0.5)
276
wait(5 - workspace.DistributedGameTime)
277
local oldWTSP = workspace.CurrentCamera.WorldToScreenPoint
278
local MT = getrawmetatable(game)
279
if setreadonly then
280
	setreadonly(MT,false)
281
elseif make_writeable then
282
	make_writeable(MT)
283
end
284
local old__namecall = MT.__namecall
285
function MT:__namecall(...)
286
	local args = {...}
287
	local m = args[#args]
288
	if m=="WorldToScreenPoint" and self.ClassName=="Camera" then
289
		local ret = oldWTSP(self,...)
290
		return ret,true
291
	elseif m=="FindPartOnRay" and args[1].Origin==uptorso.Position and args[1].Direction.Y==-8 then
292
		return nil, args[1].Origin+args[1].Direction, v30, Enum.Material.Air
293
	elseif m=="ChangeState" and args[1].Name=="FallingDown" then
294
		workspace.CurrentCamera.CameraSubject = humanoid
295
		for _,e in next, Enum.HumanoidStateType:GetEnumItems() do
296
			if e ~= Enum.HumanoidStateType.None and e ~= Enum.HumanoidStateType.Dead then
297
				humanoid:SetStateEnabled(e, true)
298
			end
299
		end
300
		return wait(9e9)
301
	end
302
	return old__namecall(self,...)
303
end
304
getupvalues = getupvalues or debug.getupvalues
305
local punchSpec, specs
306
if (getreg or debug.getregistry) and getupvalues then
307
	local reg = (getreg or debug.getregistry)()
308
	for a=1,#reg do
309
		local f = reg[a]
310
		if type(f)=="function" then
311
			for _,t in next,getupvalues(f) do
312
				if type(t)=="table" then
313
					if specs==nil and t.Specs and t.Frame and #t==0 then
314
						specs = t.Specs
315
					elseif punchSpec==nil and #t==3 then
316
						for b=1,3 do
317
							if type(t[b])=="table" and t[b].Name=="Punch" then
318
								punchSpec = t[b]
319
								if (getconsts or debug.getconstants) then
320
									for c,v in next,(getconsts or debug.getconstants)(punchSpec.Callback) do
321
										if v == 0.5 then
322
											(setconst or setconstant or debug.setconstant)(punchSpec.Callback,c,0)
323
										end
324
									end
325
								end
326
							end
327
						end
328
					end
329
				end
330
			end
331
		end
332
		if specs and punchSpec then
333
			break
334
		end
335
	end
336
end
337
--// misc code //
338
local windowFocused = false
339
game:GetService("UserInputService").WindowFocused:Connect(function() windowFocused=true end)
340
game:GetService("UserInputService").WindowFocusReleased:Connect(function() windowFocused=false end)
341
spawn(function()
342
	game:GetService("UserInputService").InputBegan:Wait()
343
	windowFocused=true
344
end)
345
for _,part in ipairs(workspace.Buildings:GetChildren()) do
346
	if (part.Position-Vector3.new(-302.6,30.3,1431.9)).magnitude < 1 then
347
		part.CanCollide=false
348
	end
349
end
350
for _,part in ipairs(workspace.Jewelrys:GetChildren()[1].Building:GetChildren()) do
351
	if part.Name=="Part" and (part.Position-Vector3.new(157.8,63.4,1336.6)).magnitude < 1 then
352
		part.CanCollide = false
353
	end
354
end
355
local museumArray = { {CFrame.new(1053.6,101.7,1245.6),workspace.Museum.MummyCase.Mummy.Head},{CFrame.new(1037.1,116.6,1254.8),workspace.Museum.Reference.Items.Gold},
356
	{CFrame.new(1046.8,116.6,1262.7),workspace.Museum.Reference.Items.SpinnerRim},{CFrame.new(1029.4,116.6,1247.7),workspace.Museum.Reference.Items.Cone.Cone},
357
	{CFrame.new(1038.8,101.7,1238.7),workspace.Museum.EgyptionCase.Mask},{CFrame.new(1105.3,101.7,1151),workspace.Museum.JewelCase.Jewel} }
358
--// subroutines //
359
local function keyclick(num)
360
	if windowFocused and keypress and keyrelease then
361
		keypress(num)
362
		wait()
363
		keyrelease(num)
364
	end
365
end
366
local function exitVehicle()
367
	if humanoid.Sit then
368
		keyclick(0x20)
369
		wait(0.07)
370
		humanoid.Jump=true
371
		wait(0.3)
372
	end
373
end
374
local function perfectTP(cf)
375
	local oldg = workspace.Gravity
376
	workspace.Gravity = 0
377
	local door = workspace.Apartments.Skyscraper1.ExitDoor.Touch
378
	local oldcf = door.CFrame
379
	local elapsed = 0
380
	while (root.Position-cf.p).magnitude > 14 and elapsed < 9 and not abort do
381
		door.CFrame = root.CFrame
382
		elapsed=elapsed+wait()
383
		door.CFrame = oldcf
384
		root.CFrame = cf
385
		root.Velocity,root.RotVelocity=v30,v30
386
		elapsed=elapsed+wait(0.5)
387
	end
388
	workspace.Gravity = oldg
389
end
390
local function miniTP(cf)
391
	local cf0 = (cf-cf.p) + root.Position + Vector3.new(0,4,0)
392
	local diff = cf.p - root.Position
393
	local oldg = workspace.Gravity
394
	workspace.Gravity = 0
395
	for i=0,diff.magnitude,1.8 do
396
		if abort then break end
397
		root.CFrame = cf0 + diff.Unit * i
398
		root.Velocity,root.RotVelocity=v30,v30
399
		wait()
400
	end
401
	if not abort then root.CFrame = cf end
402
	workspace.Gravity = oldg
403
end
404
local function strToNum(str)
405
	return tonumber((tostring(str):gsub("%D", "")))
406
end
407
local function isBagFull()
408
	return player.PlayerGui.MainGui.CollectMoney.Visible and strToNum(player.PlayerGui.MainGui.CollectMoney.Money.Text)+2 > strToNum(player.PlayerGui.MainGui.CollectMoney.Maximum.Text)
409
end
410
local vault
411
local function isVaultOpen()
412
	return (vault.Door.Closed.CFrame.lookVector - vault.Door.Hinge.CFrame.lookVector).magnitude > 0.1
413
end
414
local function copsTooClose(radius)
415
	local players = game:GetService("Teams").Police:GetPlayers()
416
	for i=1,#players do
417
		local p = players[i]
418
		if p.Character and p.Character:FindFirstChild("HumanoidRootPart") and p.Character:FindFirstChild("Humanoid") then
419
			local rootp = p.Character.HumanoidRootPart.Position
420
			if (vault.Door.Hinge.Position - rootp).magnitude < radius and p.Character.Humanoid.Health>0 and workspace:FindPartOnRayWithWhitelist(Ray.new(rootp,vault.TriggerDoor.Position - vault.Door.Hinge.CFrame.lookVector*3 - rootp),{vault.Decoration,vault.Parent.Parent.TopFloor})==nil then
421
				return true
422
			end
423
		end
424
	end
425
	return false
426
end
427
local function waitWhile(t,exitFunc)
428
	local elapsed = 0
429
	local increment = 0.1
430
	t = (t == nil or t <= 0) and 0.001 or t
431
	increment = (increment > t) and t or increment
432
	while elapsed < t and abort == false and (exitFunc==nil or exitFunc(elapsed)) do
433
		elapsed = elapsed + wait(t-elapsed < increment and t-elapsed or increment)
434
	end
435
	return elapsed
436
end
437
local function jailbreak()
438
	if player.Team.Name=="Prisoner" then
439
		--jailbreak :^)
440
		setStatus("Breaking out...")
441
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
442
		waitWhile(4,function() return player.Team.Name=="Prisoner" end)
443
	end
444
end
445
--// entity status //
446
local isSteamEngineOpen = workspace.Trains:FindFirstChild("SteamEngine")~=nil
447
local current_boxcar = workspace.Trains:FindFirstChild("BoxCar")
448
local temp_boxcar = current_boxcar or {} --bugfix for multiple boxcar attempts
449
workspace.Trains.ChildAdded:Connect(function(child)
450
	wait(math.random())
451
	if child.Name=="SteamEngine" then
452
		isSteamEngineOpen = true
453
	elseif child.Name=="BoxCar" and current_boxcar==nil and temp_boxcar.Parent==nil then
454
		temp_boxcar = child
455
		wait(24 + math.random()*53) --confuse cops
456
		if child.Parent and current_boxcar==nil then
457
			current_boxcar = child
458
		end
459
	end
460
	trainLbl.TextColor3 = (current_boxcar or isSteamEngineOpen) and green or Color3.new(1,1,1)
461
end)
462
workspace.Trains.ChildRemoved:Connect(function(child)
463
	if current_boxcar == child then
464
		current_boxcar = nil
465
	elseif child.Name=="SteamEngine" then
466
		isSteamEngineOpen = false
467
	end
468
	trainLbl.TextColor3 = (current_boxcar or isSteamEngineOpen) and green or Color3.new(1,1,1)
469
end)
470
trainLbl.TextColor3 = (current_boxcar or isSteamEngineOpen) and green or Color3.new(1,1,1)
471
local airdrops = {}
472
local function checkNewDrop(child)
473
	local briefcase = child:WaitForChild("Briefcase",2)
474
	if briefcase then
475
		local e=0
476
		while true do
477
			e=e+wait(0.25)
478
			local hitpart = workspace:FindPartOnRayWithIgnoreList(Ray.new(briefcase.Position,Vector3.new(0,-17,0)),{child},false,true)
479
			if e>25 or (hitpart and hitpart.CanCollide) or child:FindFirstChild("Parachute")==nil then
480
				break
481
			end
482
		end
483
		if child.Parent and briefcase.Parent then
484
			airdrops[#airdrops+1]=child
485
			airdropLbl.TextColor3 = green
486
		end
487
	end
488
end
489
for _,child in ipairs(workspace:GetChildren()) do
490
	if child.Name=="Drop" and child.ClassName=="Model" then
491
		spawn(function() checkNewDrop(child) end)
492
	end
493
end
494
workspace.ChildAdded:Connect(function(child)
495
	if child.Name=="Drop" and child.ClassName=="Model" then
496
		checkNewDrop(child)
497
	end
498
end)
499
workspace.ChildRemoved:Connect(function(child)
500
	if child.Name=="Drop" and child.ClassName=="Model" then
501
		for i=1,#airdrops do
502
			if airdrops[i]==child then
503
				table.remove(airdrops,i)
504
				airdropLbl.TextColor3 = #airdrops>0 and green or Color3.new(1,1,1)
505
				break
506
			end
507
		end
508
	end
509
end)
510
local bankSign = workspace.Banks:GetChildren()[1].Extra.Sign.Decal
511
local museumPart = workspace.Museum.Roof.Hole.Part
512
local isBankOpen = bankSign.Transparency>0.01
513
local isMuseumOpen = not museumPart.CanCollide
514
local isBankCalm = #workspace.Ringers.Bank:GetChildren()==0
515
bankSign:GetPropertyChangedSignal("Transparency"):Connect(function()
516
	wait()
517
	isBankOpen = bankSign.Transparency>0.01
518
	bankLbl.TextColor3 = isBankOpen and green or Color3.new(1,1,1)
519
	if not isBankOpen then
520
		isBankCalm=true
521
	end
522
end)
523
524
museumPart:GetPropertyChangedSignal("CanCollide"):Connect(function()
525
	wait()
526
	isMuseumOpen = not museumPart.CanCollide
527
	museumLbl.TextColor3 = isMuseumOpen and green or Color3.new(1,1,1)
528
end)
529
bankLbl.TextColor3 = isBankOpen and green or Color3.new(1,1,1)
530
museumLbl.TextColor3 = isMuseumOpen and green or Color3.new(1,1,1)
531
workspace.Ringers.Bank.ChildAdded:Connect(function() isBankCalm=false end)
532
workspace.Ringers.Jewelry.ChildAdded:Connect(function() isJewlCalm=false end)
533
--// rob funcs //
534
local function robBank()
535
	toggleCanAbort(true)
536
	warnFlash("Bank")
537
	if humanoid==nil or humanoid.Health<1 then wait(5) end
538
	if abort or not settings.enabled then return true end
539
	exitVehicle()
540
	jailbreak()
541
	local formerCF = root.CFrame
542
	setStatus("TPing to bank...")
543
	--enter
544
	perfectTP(CFrame.new(23.6, 18.07, 853.5))
545
	waitWhile(2,function() return isBankCalm end)
546
	if abort then return true end
547
	setStatus("Opening vault...")
548
	vault = workspace.Banks:GetChildren()[1].Layout:GetChildren()[1]
549
	local vaultcf = vault.Door.Hinge.CFrame
550
	perfectTP(vaultcf + vaultcf.lookVector*-3 + vaultcf.rightVector*6)
551
	if abort then return end
552
	--get in vault
553
	if (vaultcf.p - vault.Money.CFrame.p).magnitude < 30 then
554
		if vault.Name=="TheMint" then
555
			root.CFrame = vaultcf + vaultcf.lookVector*3 + vaultcf.rightVector*13.5
556
		else
557
			root.CFrame = vaultcf + vaultcf.lookVector*3 + vaultcf.rightVector*-5.5 + Vector3.new(0,3,0)
558
		end
559
	else
560
		if vault:FindFirstChild("Lasers") then
561
			for _,laser in ipairs(vault.Lasers:GetChildren()) do
562
				if laser.Name=="LaserTrack" then
563
					laser:Destroy()
564
				end
565
			end
566
		end
567
		root.CFrame = vault.Money.CFrame
568
	end
569
	--wait until open
570
	waitWhile(300,function() return isBankOpen and isVaultOpen()==false end)
571
	waitWhile(3,function() return isBankOpen and (not (isVaultOpen() and copsTooClose(settings.bankRadius2))) end)
572
	setStatus("Robbery started!")
573
	--wait for bag to fill or player leaves
574
	waitWhile(80,function() return isBagFull()==false and isBankOpen and (not (isVaultOpen() and copsTooClose(settings.bankRadius2))) end)
575
	setStatus("Escaping...")
576
	--escape
577
	if settings.preferUnsafeEsc then
578
		perfectTP(formerCF)
579
	else
580
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
581
	end
582
end
583
local function robBoxcar()
584
	toggleCanAbort(true)
585
	warnFlash("Train")
586
	if humanoid==nil or humanoid.Health<1 then wait(5) end
587
	if abort or not settings.enabled then return true end
588
	local gold = current_boxcar.Model.Rob.Gold
589
	local trainFront = workspace.Trains.LocomotiveFront.Model.Front
590
	exitVehicle()
591
	jailbreak()
592
	local formerCF = root.CFrame
593
	setStatus("TPing to train...")
594
	--enter
595
	perfectTP(root.CFrame)
596
	if abort then return true end
597
	if current_boxcar.Parent then
598
		if specs then
599
			local trainDoorSpec,trainVaultSpec
600
			for i=1,#specs do
601
				local s = specs[i]
602
				if not s then
603
				elseif trainDoorSpec==nil and s.Name=="Open Door" and tostring(s.Part)=="RoofDoorClosed" and current_boxcar:IsAncestorOf(s.Part) then
604
					trainDoorSpec = s
605
				elseif trainVaultSpec==nil and s.Name=="Breach Vault" and current_boxcar:IsAncestorOf(s.Part) then
606
					trainVaultSpec = s
607
				end
608
			end
609
			if trainDoorSpec then
610
				trainDoorSpec:Callback(true)
611
			end
612
			if trainVaultSpec then
613
				trainVaultSpec:Callback(true)
614
			end
615
		else
616
			setStatus("Opening door...")
617
			--open door
618
			stepconn = Stepped:Connect(function()
619
				root.CFrame = current_boxcar.Skeleton.RoofDoorClosed.CFrame + Vector3.new(0,-5,0)
620
				root.Velocity,root.RotVelocity=v30,v30
621
			end)
622
			waitWhile(0.5)
623
			HOLD_E = true
624
			waitWhile(9,function() return (current_boxcar.Skeleton.RoofDoor.Position-current_boxcar.Skeleton.RoofDoorClosed.Position).Magnitude < 1 end)
625
			stepconn:Disconnect()
626
			waitWhile()
627
			HOLD_E = false
628
			setStatus("Opening vault...")
629
			--open vault
630
			stepconn = Stepped:Connect(function()
631
				root.CFrame = gold.CFrame+(gold.CFrame.lookVector*4.5)
632
				root.Velocity,root.RotVelocity=v30,v30
633
			end)
634
			waitWhile(0.5)
635
			HOLD_E = true
636
			waitWhile(9,function() return current_boxcar.Skeleton.Vault.Part.RotVelocity.Magnitude < .001 end)
637
			stepconn:Disconnect()
638
			waitWhile(0.2)
639
			HOLD_E = false
640
		end
641
		setStatus("Robbery started!")
642
		--get gold
643
		stepconn = Stepped:Connect(function()
644
			root.CFrame = gold.CFrame
645
			root.Velocity,root.RotVelocity=v30,v30
646
		end)
647
		waitWhile(65,function() return isBagFull()==false and trainFront.Position.X > -1584 end)
648
		stepconn:Disconnect()
649
		--if trainFront.Position.X < -1200 and trainFront.Position.Z < 550 then
650
		--	boxcars={}
651
		--end
652
	end
653
	setStatus("Escaping...")
654
	--escape
655
	if settings.preferUnsafeEsc then
656
		perfectTP(formerCF)
657
	else
658
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
659
	end
660
end
661
local function robMuseum()
662
	toggleCanAbort(true)
663
	warnFlash("Museum")
664
	if humanoid==nil or humanoid.Health<1 then wait(5) end
665
	if abort or not settings.enabled then return true end
666
	exitVehicle()
667
	jailbreak()
668
	local formerCF = root.CFrame
669
	setStatus("TPing to museum...")
670
	--enter
671
	perfectTP(CFrame.new(1067.8,102.8,1193.8))
672
	if abort then return true end
673
	--collect artifacts
674
	setStatus("Robbery started!")
675
	if specs then
676
		for i=1,#specs do
677
			local s = specs[i]
678
			if s and s.Name and s.Name:sub(1,5)=="Grab " and workspace.Museum:IsAncestorOf(s.Part) then
679
				s:Callback(true)
680
				wait()
681
			end
682
		end
683
	else
684
		local bag = player.PlayerGui.MainGui.MuseumBag.TextLabel
685
		bag.Text = "9".. bag.Text:sub(2)
686
		for i=1,#museumArray do
687
			local tpcf = museumArray[i][1]
688
			local part = museumArray[i][2]
689
			if part.Transparency < .99 then
690
				if abort or isMuseumOpen==false or bag.Text:sub(1,1) == bag.Text:sub(5,5) then
691
					break
692
				end
693
				perfectTP(tpcf)
694
				HOLD_E = true
695
				waitWhile(9,function() return part.Transparency < .99 end)
696
				HOLD_E = false
697
				waitWhile(0.1)
698
			end
699
		end
700
	end
701
	--go back
702
	if settings.preferUnsafeEsc then
703
		perfectTP(formerCF)
704
	else
705
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
706
	end
707
	setStatus("Bypassing by waiting...")
708
	waitWhile(16)
709
	exitVehicle()
710
	formerCF = root.CFrame
711
	--tp to collector
712
	setStatus("Selling...")
713
	perfectTP(CFrame.new(1639,50,-1800))
714
	waitWhile(5,function() return player.PlayerGui.MainGui.MuseumBag.Visible end)
715
	setStatus("Escaping...")
716
	--escape
717
	if settings.preferUnsafeEsc then
718
		perfectTP(formerCF)
719
	else
720
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
721
	end
722
end
723
local function robSteamEngine()
724
	toggleCanAbort(true)
725
	warnFlash("Steam engine")
726
	if humanoid==nil or humanoid.Health<1 then wait(5) end
727
	if abort or not settings.enabled then return true end
728
	exitVehicle()
729
	jailbreak()
730
	local formerCF = root.CFrame
731
	--collect items
732
	setStatus("Robbery started!")
733
	local grabNum=0
734
	for j=1,2 do
735
		for i=1,#specs do
736
			local s = specs[i]
737
			if s and s.Enabled and s.Name and s.Name:sub(1,5)=="Grab " and workspace.Trains:IsAncestorOf(s.Part) then
738
				if j==2 or s.Name:sub(7)=="riefcase" then
739
					waitWhile(1.35)
740
					s:Callback(true)
741
					grabNum=grabNum+1
742
					if abort or grabNum>9 then
743
						break
744
					end
745
				end
746
			end
747
		end
748
		if abort or grabNum>9 then
749
			break
750
		end
751
	end
752
	exitVehicle()
753
	formerCF = root.CFrame
754
	setStatus("Selling...")
755
	--tp to collector
756
	perfectTP(CFrame.new(1639,50,-1800))
757
	waitWhile(5,function() return player.PlayerGui.MainGui.MuseumBag.Visible end)
758
	setStatus("Escaping...")
759
	--escape
760
	if settings.preferUnsafeEsc then
761
		perfectTP(formerCF)
762
	else
763
		perfectTP(CFrame.new(-298+math.random()*10,18,1430))
764
	end
765
end
766
local function robAirdrop()
767
	toggleCanAbort(true)
768
	warnFlash("Airdrop")
769
	if humanoid==nil or humanoid.Health<1 then wait(5) end
770
	if abort or not settings.enabled then return true end
771
	local current_airdrop = airdrops[1]
772
	if current_airdrop and current_airdrop.Parent and current_airdrop:FindFirstChild("Briefcase") then
773
		local briefcase = current_airdrop.Briefcase
774
		exitVehicle()
775
		jailbreak()
776
		local formerCF = root.CFrame
777
		--enter
778
		setStatus("TPing to airdrop...")
779
		noclip()
780
		root.Velocity,root.RotVelocity=v30,v30
781
		perfectTP(briefcase.CFrame+Vector3.new(0,-6,0))
782
		if abort then
783
			yesclip()
784
			return true
785
		elseif briefcase.Parent then
786
			--collect
787
			setStatus("Robbery started!")
788
			root.CFrame = briefcase.CFrame + Vector3.new(0,-6,0)
789
			root.Anchored = true
790
			waitWhile(0.1)
791
			if specs then
792
				for i=1,#specs do
793
					local s = specs[i]
794
					if s and s.Name and s.Name:lower()=="pick up briefcase" and current_airdrop:IsAncestorOf(s.Part) then
795
						s:Callback(true)
796
						break
797
					end
798
				end
799
			else
800
				HOLD_E = true
801
				waitWhile(18,function()
802
					root.CFrame = briefcase.CFrame + Vector3.new(0,-6,0)
803
					return briefcase.Parent ~= nil
804
				end)
805
				HOLD_E = false
806
			end
807
			root.Anchored = false
808
		end
809
		yesclip()
810
		--escape
811
		setStatus("Escaping...")
812
		if settings.preferUnsafeEsc then
813
			perfectTP(formerCF)
814
		else
815
			perfectTP(CFrame.new(-298+math.random()*10,18,1430))
816
		end
817
	end
818
end
819
--HOLD_E thread
820
if keypress then
821
	spawn(function()
822
		while wait(0.2) and gui.Parent do
823
			if HOLD_E then
824
				keyclick(0x45)
825
				while wait(0.1) and HOLD_E do
826
					if windowFocused then
827
						keypress(0x45)
828
					end
829
				end
830
				keyrelease(0x45)
831
			end
832
		end
833
	end)
834
end
835
--notification
836
if specs or keypress then
837
	game:GetService("StarterGui"):SetCore("SendNotification",{Title="Auto-Rob by sirelKilla",Text=settingsModified and "Settings changed!" or ''})
838
else
839
	game:GetService("StarterGui"):SetCore("SendNotification",{Title="Auto-Rob by sirelKilla",Text="Your exploit does NOT support AFK",Button1="OK",Duration=20})
840
end
841
--// main loop //
842
local waiti=0
843
local idleTick=0
844
local airdropTick = 0
845
while wait(0.5) and gui.Parent do
846
	if workspace.Trains:FindFirstChild("LocomotiveFront") then --avoid train tunnel
847
		local trainpos = workspace.Trains.LocomotiveFront.Model.Front.Position
848
		if trainpos.X < -1300 and trainpos.Z < 350 then
849
			current_boxcar=nil
850
		end
851
	end --avoid train stop
852
	if (fireclickdetector or click_detector) and workspace.Switches.BranchBack.Rail.Transparency < .9 then
853
		(fireclickdetector or click_detector)(workspace.Switches.BranchBack.Lever.Click.ClickDetector,1)
854
	end --avoid afk
855
	if tick()-idleTick > 60 then
856
		idleTick=tick()
857
		game:GetService("VirtualUser"):CaptureController()
858
		game:GetService("VirtualUser"):ClickButton2(Vector2.new())
859
	end
860
	player.PlayerGui.MainGui.CollectMoney.Visible=false
861
	if settings.enabled then
862
		if isMuseumOpen then
863
			if not robMuseum() then
864
				isMuseumOpen=false
865
				museumLbl.TextColor3 = Color3.new(1,1,1)
866
				setStatus("Museum success!")
867
			end
868
			toggleCanAbort(false)
869
			wait(2)
870
		elseif #airdrops > 0 and tick()-airdropTick > 20 then
871
			if not robAirdrop() then
872
				airdropTick = tick()
873
				setStatus("Airdrop success!")
874
			end
875
			toggleCanAbort(false)
876
			wait(2)
877
		elseif isSteamEngineOpen and specs then
878
			if not robSteamEngine() then
879
				isSteamEngineOpen=false
880
				trainLbl.TextColor3 = Color3.new(1,1,1)
881
				setStatus("Train success!")
882
			end
883
			toggleCanAbort(false)
884
			wait(2)
885
		elseif current_boxcar then
886
			if not robBoxcar() then
887
				current_boxcar = nil
888
				trainLbl.TextColor3 = Color3.new(1,1,1)
889
				setStatus("Train success!")
890
			end
891
			toggleCanAbort(false)
892
			wait(2)
893
		elseif isBankOpen then
894
			if not robBank() then
895
				isBankOpen=false
896
				bankLbl.TextColor3 = Color3.new(1,1,1)
897
				setStatus("Bank success!")
898
			end
899
			toggleCanAbort(false)
900
			wait(2)
901
		else
902
			setStatus("Wait for stores to open".. string.rep('.',waiti%3+1))
903
			waiti=waiti+1
904
		end
905
	else
906
		setStatus("Disabled.")
907
	end
908
end
909
print("Hello, shelly_issad")
910
print("Player Detection Added By LuaPhysics")
911
print("LuaPhysics#6400 ~Discord~");