-
Notifications
You must be signed in to change notification settings - Fork 61
Expand file tree
/
Copy pathUniversal.lua
More file actions
9157 lines (8879 loc) · 336 KB
/
Universal.lua
File metadata and controls
9157 lines (8879 loc) · 336 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
local GuiLibrary = shared.GuiLibrary
local playersService = game:GetService("Players")
local identifyexecutor = identifyexecutor or function() return 'Unknown' end
local getconnections = getconnections or function() return {} end
local queueonteleport = syn and syn.queue_on_teleport or queue_on_teleport or function() end
local setclipboard = setclipboard or function(data) writefile('clipboard.txt', data) end
local httpService = game:GetService('HttpService')
local lplr = playersService.LocalPlayer
local coreGui
local suc, err = pcall(function()
coreGui = game:GetService("CoreGui")
end)
if err then coreGui = lplr.PlayerGui end
getgenv().coreGui = coreGui
local textService = game:GetService("TextService")
local lightingService = game:GetService("Lighting")
local textChatService = game:GetService("TextChatService")
local inputService = game:GetService("UserInputService")
local runService = game:GetService("RunService")
local replicatedStorage = game:GetService("ReplicatedStorage")
local HWID = game:GetService('RbxAnalyticsService'):GetClientId()
local tweenService = game:GetService("TweenService")
local gameCamera = workspace.CurrentCamera
local vapeConnections = {}
local vapeCachedAssets = {}
local vapeTargetInfo = shared.VapeTargetInfo
local vapeInjected = true
table.insert(vapeConnections, workspace:GetPropertyChangedSignal("CurrentCamera"):Connect(function()
gameCamera = workspace.CurrentCamera or workspace:FindFirstChildWhichIsA("Camera")
end))
local RenderFunctions = {}
local VoidwareStore = {
jumptick = tick(),
}
local httprequest = (http and http.request or http_request or fluxus and fluxus.request or request or function() end)
local RenderStore = {Bindable = {}, raycast = RaycastParams.new(), MessageReceived = Instance.new('BindableEvent'), tweens = {}, ping = 0, platform = inputService:GetPlatform(), LocalPosition = Vector3.zero}
getgenv().RenderStore = RenderStore
local vec3 = Vector3.new
local vec2 = Vector2.new
local isfile = isfile or function(file)
local suc, res = pcall(function() return readfile(file) end)
return suc and res ~= nil
end
local colors = {
White = Color3.fromRGB(255, 255, 255),
Black = Color3.fromRGB(0, 0, 0),
Red = Color3.fromRGB(255, 0, 0),
Green = Color3.fromRGB(0, 255, 0),
Blue = Color3.fromRGB(0, 0, 255),
Yellow = Color3.fromRGB(255, 255, 0),
Cyan = Color3.fromRGB(0, 255, 255),
Magenta = Color3.fromRGB(255, 0, 255),
Gray = Color3.fromRGB(128, 128, 128),
DarkGray = Color3.fromRGB(64, 64, 64),
LightGray = Color3.fromRGB(192, 192, 192),
Orange = Color3.fromRGB(255, 165, 0),
Pink = Color3.fromRGB(255, 192, 203),
Purple = Color3.fromRGB(128, 0, 128),
Brown = Color3.fromRGB(139, 69, 19),
LimeGreen = Color3.fromRGB(50, 205, 50),
NavyBlue = Color3.fromRGB(0, 0, 128),
Olive = Color3.fromRGB(128, 128, 0),
Teal = Color3.fromRGB(0, 128, 128),
Maroon = Color3.fromRGB(128, 0, 0),
Gold = Color3.fromRGB(255, 215, 0),
Silver = Color3.fromRGB(192, 192, 192),
SkyBlue = Color3.fromRGB(135, 206, 235),
Violet = Color3.fromRGB(238, 130, 238)
}
getgenv().ColorTable = colors
if readfile == nil then
task.spawn(error, 'Voidware - Exploit not supported. Your exploit doesn\'t have filesystem support.')
while task.wait() do end
end
pcall(function() core = game:GetService('CoreGui') end)
local function vapeGithubRequest(scripturl)
if not isfile('vape/'..scripturl) then
local suc, res = pcall(function()
return game:HttpGet('https://raw.githubusercontent.com/VapeVoidware/vapevoidware/'..readfile('vape/commithash.txt')..'/'..scripturl, true)
end)
if not suc or res == '404: Not Found' then
suc, res = pcall(function()
return game:HttpGet("https://raw.githubusercontent.com/Erchobg/vapevoidware/"..readfile("vape/commithash.txt").."/"..scripturl, true)
end)
end
assert(suc, res)
assert(res ~= '404: Not Found', res)
if scripturl:find('.lua') then
res = '--This watermark is used to delete the file if its cached, remove it to make the file persist after commits.\n'..res
end
writefile('vape/'..scripturl, res)
end
return readfile('vape/'..scripturl)
end
shared.vapeGithubRequest = vapeGithubRequest
table.insert(vapeConnections, workspace:GetPropertyChangedSignal('CurrentCamera'):Connect(function()
gameCamera = workspace.CurrentCamera or workspace:FindFirstChildWhichIsA('Camera')
end))
local RenderFunctions = loadstring(vapeGithubRequest("Libraries/voidwarefunctions.lua"))()
local isAlive = function() return false end
local playSound = function() end
local dumptable = function() return {} end
local sendmessage = function() end
local sendprivatemessage = function() end
local characterDescendant = function() return nil end
local playerRaycasted = function() return true end
local GetTarget = function() return {} end
local GetAllTargets = function() return {} end
local getnewserver = function() return nil end
local switchserver = function() end
local getTablePosition = function() return 1 end
local warningNotification = function() end
local InfoNotification = function() end
local errorNotification = function() end
local networkownerswitch = tick()
local isnetworkowner = function(part)
local suc, res = pcall(function() return gethiddenproperty(part, "NetworkOwnershipRule") end)
if suc and res == Enum.NetworkOwnership.Manual then
sethiddenproperty(part, "NetworkOwnershipRule", Enum.NetworkOwnership.Automatic)
networkownerswitch = tick() + 8
end
return networkownerswitch <= tick()
end
local vapeAssetTable = {["vape/assets/VapeCape.png"] = "rbxassetid://18341361652", ["vape/assets/ArrowIndicator.png"] = "rbxassetid://13350766521"}
local getcustomasset = getsynasset or getcustomasset or function(location) return vapeAssetTable[location] or "" end
local queueonteleport = syn and syn.queue_on_teleport or queue_on_teleport or function() end
local synapsev3 = syn and syn.toast_notification and "V3" or ""
local worldtoscreenpoint = function(pos)
if synapsev3 == "V3" then
local scr = worldtoscreen({pos})
return scr[1] - Vector3.new(0, 36, 0), scr[1].Z > 0
end
return gameCamera.WorldToScreenPoint(gameCamera, pos)
end
local worldtoviewportpoint = function(pos)
if synapsev3 == "V3" then
local scr = worldtoscreen({pos})
return scr[1], scr[1].Z > 0
end
return gameCamera.WorldToViewportPoint(gameCamera, pos)
end
local function downloadVapeAsset(path)
if not isfile(path) then
task.spawn(function()
local textlabel = Instance.new("TextLabel")
textlabel.Size = UDim2.new(1, 0, 0, 36)
textlabel.Text = "Downloading "..path
textlabel.BackgroundTransparency = 1
textlabel.TextStrokeTransparency = 0
textlabel.TextSize = 30
textlabel.Font = Enum.Font.SourceSans
textlabel.TextColor3 = Color3.new(1, 1, 1)
textlabel.Position = UDim2.new(0, 0, 0, -36)
textlabel.Parent = GuiLibrary.MainGui
--repeat task.wait() until isfile(path)
task.wait(0.2)
textlabel:Destroy()
end)
local suc, req = pcall(function() return vapeGithubRequest(path:gsub("vape/assets", "assets")) end)
if suc and req then
writefile(path, req)
else
return ""
end
end
if not vapeCachedAssets[path] then vapeCachedAssets[path] = getcustomasset(path) end
return vapeCachedAssets[path]
end
local function warningNotification(title, text, delay)
local suc, res = pcall(function()
local frame = GuiLibrary.CreateNotification(title, text, delay, "assets/WarningNotification.png")
frame.Frame.Frame.ImageColor3 = Color3.fromRGB(236, 129, 44)
return frame
end)
return (suc and res)
end
InfoNotification = function(title, text, delay)
local success, frame = pcall(function()
GuiLibrary.CreateNotification(title, text, delay)
end)
return success and frame
end
errorNotification = function(title, text, delay)
local success, frame = pcall(function()
local notification = GuiLibrary.CreateNotification(title, text, delay or 6.5, 'assets/WarningNotification.png')
notification.IconLabel.ImageColor3 = Color3.new(220, 0, 0)
notification.Frame.Frame.ImageColor3 = Color3.new(220, 0, 0)
end)
return success and frame
end
local function removeTags(str)
str = str:gsub("<br%s*/>", "\n")
return (str:gsub("<[^<>]->", ""))
end
local function run(name, func)
local function displayErrorPopup(text, funclist)
local oldidentity = getidentity()
setidentity(8)
local ErrorPrompt = getrenv().require(game:GetService("CoreGui").RobloxGui.Modules.ErrorPrompt)
local prompt = ErrorPrompt.new("Default")
prompt._hideErrorCode = true
local gui = Instance.new("ScreenGui", game:GetService("CoreGui"))
prompt:setErrorTitle("Vape")
local funcs
if funclist then
funcs = {}
local num = 0
for i,v in pairs(funclist) do
num = num + 1
table.insert(funcs, {
Text = i,
Callback = function()
prompt:_close()
v()
end,
Primary = num == #funclist
})
end
end
prompt:updateButtons(funcs or {{
Text = "OK",
Callback = function()
prompt:_close()
end,
Primary = true
}}, 'Default')
prompt:setParent(gui)
prompt:_open(text)
setidentity(oldidentity)
shared.VapeOpenGui = false
end
local function errorNotification(title, text, delay)
local suc, res = pcall(function()
local frame = GuiLibrary.CreateNotification(title, text, delay, "assets/InfoNotification.png")
frame.Frame.Frame.ImageColor3 = Color3.fromRGB(220, 0, 0)
return frame
end)
warn(title..": "..text)
return (suc and res)
end
local function performanceWarning(title, text, delay)
local suc, res = pcall(function()
local frame = GuiLibrary.CreateNotification(title, text, delay, "assets/WarningNotification.png")
frame.Frame.Frame.ImageColor3 = Color3.fromRGB(255, 165, 0)
return frame
end)
warn(title..": "..text)
return (suc and res)
end
local ModuleName
local ModuleFunction
if name then
if type(name) == "string" then
ModuleName = name
if func and type(func) == "function" then ModuleFunction = func end
elseif type(name) == "function" then
if func then errorNotification("VoidwareErrorHandler", "Unknown type of function use done! func specified type: "..type(func), 20) else
ModuleFunction = name
ModuleName = "Not specified"
end
end
end
if ModuleFunction then
local startTime = os.clock()
local startMem = collectgarbage("count")
local suc, err = xpcall(function() task.spawn(function() ModuleFunction() end) end, function() print("Error") end)
local endTime = os.clock()
local endMem = collectgarbage("count")
local execTime = endTime - startTime
local memUsage = endMem - startMem
if err then
local text = "A module failed to load! ModuleName: "..ModuleName.." Error: "..err
displayErrorPopup(text)
errorNotification("VoidwareErrorHandler", text, 20)
else
if execTime > 1 then -- Example threshold for execution time
if shared.VapeDeveloper then
performanceWarning("Performance Warning", "ModuleName: "..ModuleName.." took "..execTime.." seconds to execute.", 20)
end
end
if memUsage > 100 then -- Example threshold for memory usage (in KB)
if shared.VapeDeveloper then
performanceWarning("Memory Warning", "ModuleName: "..ModuleName.." used "..memUsage.." KB of memory.", 20)
end
end
end
else
if ModuleName then
local text = "Failure trying to load a module! Unknown use of function. Error log: name: "..ModuleName.." Unknown function!"
displayErrorPopup(text)
errorNotification("VoidwareErrorHandler", text, 20)
else
local text = "Failure trying to load a module completely! No name and no function!!!"
displayErrorPopup(text)
errorNotification("VoidwareErrorHandler", text, 20)
end
end
end
getgenv().run = run
getgenv().runcode = getgenv().run
getgenv().runFunction = getgenv().run
local function isFriend(plr, recolor)
if GuiLibrary.ObjectsThatCanBeSaved["Use FriendsToggle"].Api.Enabled then
local friend = table.find(GuiLibrary.ObjectsThatCanBeSaved.FriendsListTextCircleList.Api.ObjectList, plr.Name)
friend = friend and GuiLibrary.ObjectsThatCanBeSaved.FriendsListTextCircleList.Api.ObjectListEnabled[friend]
if recolor then
friend = friend and GuiLibrary.ObjectsThatCanBeSaved["Recolor visualsToggle"].Api.Enabled
end
return friend
end
return nil
end
local function isTarget(plr)
local friend = table.find(GuiLibrary.ObjectsThatCanBeSaved.TargetsListTextCircleList.Api.ObjectList, plr.Name)
friend = friend and GuiLibrary.ObjectsThatCanBeSaved.TargetsListTextCircleList.Api.ObjectListEnabled[friend]
return friend
end
local function isVulnerable(plr)
return plr.Humanoid.Health > 0 and not plr.Character.FindFirstChildWhichIsA(plr.Character, "ForceField")
end
local function getPlayerColor(plr)
if isFriend(plr, true) then
return Color3.fromHSV(GuiLibrary.ObjectsThatCanBeSaved["Friends ColorSliderColor"].Api.Hue, GuiLibrary.ObjectsThatCanBeSaved["Friends ColorSliderColor"].Api.Sat, GuiLibrary.ObjectsThatCanBeSaved["Friends ColorSliderColor"].Api.Value)
end
return tostring(plr.TeamColor) ~= "White" and plr.TeamColor.Color
end
local whitelist = {data = {WhitelistedUsers = {}}, hashes = {}, said = {}, alreadychecked = {}, customtags = {}, loaded = false, localprio = 0, hooked = false, get = function() return 0, true end}
local function isEnabled(module)
return GuiLibrary.ObjectsThatCanBeSaved[module] and GuiLibrary.ObjectsThatCanBeSaved[module].Api.Enabled and true or false
end
task.spawn(function()
local function chatfunc(plr)
table.insert(vapeConnections, plr.Chatted:Connect(function(message)
RenderStore.MessageReceived:Fire(plr, message)
end))
end
table.insert(vapeConnections, textChatService.MessageReceived:Connect(function(data)
local success, player = pcall(function()
return playersService:GetPlayerByUserId(data.TextSource.UserId)
end)
if success then
RenderStore.MessageReceived:Fire(player, data.Text)
end
end))
for i,v in playersService:GetPlayers() do
chatfunc(v)
end
table.insert(vapeConnections, playersService.PlayerAdded:Connect(chatfunc))
end)
getTablePosition = function(tab, val, first)
local count = 0
for i,v in tab do
count = count + 1
if (first and i or v) == val then
break
end
end
return count
end
isAlive = function(plr, nohealth)
plr = plr or lplr
local alive = false
if plr.Character and plr.Character:FindFirstChildWhichIsA('Humanoid') and plr.Character.PrimaryPart and plr.Character:FindFirstChild('Head') then
alive = true
end
local success, health = pcall(function() return plr.Character:FindFirstChildWhichIsA('Humanoid').Health end)
if success and health <= 0 and not nohealth then
alive = false
end
return alive
end
playSound = function(soundID, loop)
soundID = (soundID or ''):gsub('rbxassetid://', '')
local sound = Instance.new('Sound')
sound.Looped = loop and true or false
sound.Parent = workspace
sound.SoundId = 'rbxassetid://'..soundID
sound:Play()
sound.Ended:Connect(function() sound:Destroy() end)
return sound
end
dumptable = function(tab, tabtype, sortfunction)
local data = {}
for i,v in next, (tab) do
local tabtype = tabtype and tabtype == 1 and i or v
table.insert(data, tabtype)
end
if sortfunction and type(sortfunction) == 'function' then
table.sort(data, sortfunction)
end
return data
end
playerRaycasted = function(plr, customvector)
plr = plr or lplr
return workspace:Raycast(plr.Character.PrimaryPart.Position, customvector or Vector3.new(0, -10000, 0), RenderStore.objectraycast)
end
GetTarget = function(distance, healthmethod, raycast, npc, team)
local magnitude, target = (distance or healthmethod and 0 or math.huge), {}
for i,v in playersService:GetPlayers() do
if v ~= lplr and isAlive(v) and isAlive(lplr, true) then
--[[if not RenderFunctions:GetPlayerType(2) then
continue
end--]]
if not ({shared.vapewhitelist:get(v)})[2] then
continue
end
if not shared.vapeentity.isPlayerTargetable(v) then
continue
end
if not playerRaycasted(v) and raycast then
continue
end
if healthmethod and v.Character.Humanoid.Health < magnitude then
magnitude = v.Character.Humanoid.Health
target.Human = true
target.RootPart = v.Character.HumanoidRootPart
target.Humanoid = v.Character.Humanoid
target.Player = v
continue
end
local playerdistance = (lplr.Character.HumanoidRootPart.Position - v.Character.HumanoidRootPart.Position).Magnitude
if playerdistance < magnitude then
magnitude = playerdistance
target.Human = true
target.RootPart = v.Character.HumanoidRootPart
target.Humanoid = v.Character.Humanoid
target.Player = v
end
end
end
return target
end
characterDescendant = function(object)
for i,v in playersService:GetPlayers() do
if v.Character and object:IsDescendantOf(v.Character) then
return v
end
end
end
GetAllTargets = function(distance, sort)
local targets = {}
for i,v in playersService:GetPlayers() do
if v ~= lplr and isAlive(v) and isAlive(lplr, true) then
--[[if not RenderFunctions:GetPlayerType(2) then
continue
end--]]
if not ({shared.vapewhitelist:get(v)})[2] then
continue
end
if not entityLibrary.isPlayerTargetable(v) then
continue
end
local playerdistance = (lplr.Character.HumanoidRootPart.Position - v.Character.HumanoidRootPart.Position).Magnitude
if playerdistance <= (distance or math.huge) then
table.insert(targets, {Human = true, RootPart = v.Character.PrimaryPart, Humanoid = v.Character.Humanoid, Player = v})
end
end
end
if sort then
table.sort(targets, sort)
end
return targets
end
getnewserver = function(customgame, popular, performance)
local players, server = 0, nil
local success, serverTable = pcall(function() return httpService:JSONDecode(game:HttpGet('https://games.roblox.com/v1/games/'..(customgame or game.PlaceId)..'/servers/Public?sortOrder=Asc&limit=100', true)) end)
if success and type(serverTable) == 'table' and type(serverTable.data) == 'table' then
for i,v in serverTable.data do
if v.id and v.playing and v.maxPlayers and tonumber(v.maxPlayers) > tonumber(v.playing) and tonumber(v.playing) > 0 then
if v.id == tostring(game.JobId) then
continue
end
if tonumber(v.playing) < players and popular then
continue
end
if performance and v.ping and tonumber(v.ping) > 170 then
continue
end
players = tonumber(v.playing)
server = v.id
end
end
end
return server
end
switchserver = function(onfound)
local server
onfound = onfound or function() end
repeat server = getnewserver() task.wait() until server
task.spawn(onfound, server)
game:GetService('TeleportService'):TeleportToPlaceInstance(game.PlaceId, server, lplr)
end
sendmessage = function(text)
if textChatService.ChatVersion == Enum.ChatVersion.TextChatService then
textChatService.ChatInputBarConfiguration.TargetTextChannel:SendAsync(text)
else
replicatedStorageService.DefaultChatSystemChatEvents.SayMessageRequest:FireServer(text, 'All')
end
end
sendprivatemessage = function(player, text)
if player then
if textChatService.ChatVersion == Enum.ChatVersion.TextChatService then
local oldchannel = textChatService.ChatInputBarConfiguration.TargetTextChannel
local whisperchannel = game:GetService('RobloxReplicatedStorage').ExperienceChat.WhisperChat:InvokeServer(player.UserId)
if whisperchannel then
whisperchannel:SendAsync(text)
textChatService.ChatInputBarConfiguration.TargetTextChannel = oldchannel
end
else
replicatedStorageService.DefaultChatSystemChatEvents.SayMessageRequest:FireServer('/w '..player.Name.." "..text, 'All')
end
end
end
local entityLibrary = loadstring(vapeGithubRequest("Libraries/entityHandler.lua"))()
shared.vapeentity = entityLibrary
do
entityLibrary.selfDestruct()
table.insert(vapeConnections, GuiLibrary.ObjectsThatCanBeSaved.FriendsListTextCircleList.Api.FriendRefresh.Event:Connect(function()
entityLibrary.fullEntityRefresh()
end))
table.insert(vapeConnections, GuiLibrary.ObjectsThatCanBeSaved["Teams by colorToggle"].Api.Refresh.Event:Connect(function()
entityLibrary.fullEntityRefresh()
end))
local oldUpdateBehavior = entityLibrary.getUpdateConnections
entityLibrary.getUpdateConnections = function(newEntity)
local oldUpdateConnections = oldUpdateBehavior(newEntity)
table.insert(oldUpdateConnections, {Connect = function()
newEntity.Friend = isFriend(newEntity.Player) and true
newEntity.Target = isTarget(newEntity.Player) and true
return {Disconnect = function() end}
end})
return oldUpdateConnections
end
entityLibrary.isPlayerTargetable = function(plr)
if isFriend(plr) then return false end
if not whitelist:get(plr) == 2 then return false end
if (not GuiLibrary.ObjectsThatCanBeSaved["Teams by colorToggle"].Api.Enabled) then return true end
if (not lplr.Team) then return true end
if (not plr.Team) then return true end
if plr.Team ~= lplr.Team then return true end
return #plr.Team:GetPlayers() == playersService.NumPlayers
end
entityLibrary.fullEntityRefresh()
entityLibrary.LocalPosition = Vector3.zero
task.spawn(function()
local postable = {}
repeat
task.wait()
if entityLibrary.isAlive then
table.insert(postable, {Time = tick(), Position = entityLibrary.character.HumanoidRootPart.Position})
if #postable > 100 then
table.remove(postable, 1)
end
local closestmag = 9e9
local closestpos = entityLibrary.character.HumanoidRootPart.Position
local currenttime = tick()
for i, v in pairs(postable) do
local mag = 0.1 - (currenttime - v.Time)
if mag < closestmag and mag > 0 then
closestmag = mag
closestpos = v.Position
end
end
entityLibrary.LocalPosition = closestpos
end
until not vapeInjected
end)
end
local function calculateMoveVector(cameraRelativeMoveVector)
local c, s
local _, _, _, R00, R01, R02, _, _, R12, _, _, R22 = gameCamera.CFrame:GetComponents()
if R12 < 1 and R12 > -1 then
c = R22
s = R02
else
c = R00
s = -R01*math.sign(R12)
end
local norm = math.sqrt(c*c + s*s)
return Vector3.new(
(c*cameraRelativeMoveVector.X + s*cameraRelativeMoveVector.Z)/norm,
0,
(c*cameraRelativeMoveVector.Z - s*cameraRelativeMoveVector.X)/norm
)
end
local raycastWallProperties = RaycastParams.new()
local function raycastWallCheck(char, checktable)
if not checktable.IgnoreObject then
checktable.IgnoreObject = raycastWallProperties
local filter = {lplr.Character, gameCamera}
for i,v in pairs(entityLibrary.entityList) do
if v.Targetable then
table.insert(filter, v.Character)
end
end
for i,v in pairs(checktable.IgnoreTable or {}) do
table.insert(filter, v)
end
raycastWallProperties.FilterDescendantsInstances = filter
end
local ray = workspace.Raycast(workspace, checktable.Origin, (char[checktable.AimPart].Position - checktable.Origin), checktable.IgnoreObject)
return not ray
end
local function EntityNearPosition(distance, checktab)
checktab = checktab or {}
if entityLibrary.isAlive then
local sortedentities = {}
for i, v in pairs(entityLibrary.entityList) do -- loop through playersService
if not v.Targetable then continue end
if isVulnerable(v) then -- checks
local playerPosition = v.RootPart.Position
local mag = (entityLibrary.character.HumanoidRootPart.Position - playerPosition).magnitude
if checktab.Prediction and mag > distance then
mag = (entityLibrary.LocalPosition - playerPosition).magnitude
end
if mag <= distance then -- mag check
table.insert(sortedentities, {entity = v, Magnitude = v.Target and -1 or mag})
end
end
end
table.sort(sortedentities, function(a, b) return a.Magnitude < b.Magnitude end)
for i, v in pairs(sortedentities) do
if checktab.WallCheck then
if not raycastWallCheck(v.entity, checktab) then continue end
end
return v.entity
end
end
end
local function EntityNearMouse(distance, checktab)
checktab = checktab or {}
if entityLibrary.isAlive then
local sortedentities = {}
local mousepos = inputService.GetMouseLocation(inputService)
for i, v in pairs(entityLibrary.entityList) do
if not v.Targetable then continue end
if isVulnerable(v) then
local vec, vis = worldtoscreenpoint(v[checktab.AimPart].Position)
local mag = (mousepos - Vector2.new(vec.X, vec.Y)).magnitude
if vis and mag <= distance then
table.insert(sortedentities, {entity = v, Magnitude = v.Target and -1 or mag})
end
end
end
table.sort(sortedentities, function(a, b) return a.Magnitude < b.Magnitude end)
for i, v in pairs(sortedentities) do
if checktab.WallCheck then
if not raycastWallCheck(v.entity, checktab) then continue end
end
return v.entity
end
end
end
local function AllNearPosition(distance, amount, checktab)
local returnedplayer = {}
local currentamount = 0
checktab = checktab or {}
if entityLibrary.isAlive then
local sortedentities = {}
for i, v in pairs(entityLibrary.entityList) do
if not v.Targetable then continue end
if isVulnerable(v) then
local playerPosition = v.RootPart.Position
local mag = (entityLibrary.character.HumanoidRootPart.Position - playerPosition).magnitude
if checktab.Prediction and mag > distance then
mag = (entityLibrary.LocalPosition - playerPosition).magnitude
end
if mag <= distance then
table.insert(sortedentities, {entity = v, Magnitude = mag})
end
end
end
table.sort(sortedentities, function(a, b) return a.Magnitude < b.Magnitude end)
for i,v in pairs(sortedentities) do
if checktab.WallCheck then
if not raycastWallCheck(v.entity, checktab) then continue end
end
table.insert(returnedplayer, v.entity)
currentamount = currentamount + 1
if currentamount >= amount then break end
end
end
return returnedplayer
end
local sha = loadstring(vapeGithubRequest("Libraries/sha.lua"))()
run("plrstr", function() local olduninject
function whitelist:get(plr)
local plrstr = self:hash(plr.Name..plr.UserId)
for i,v in self.data.WhitelistedUsers do
if v.hash == plrstr then
return v.level, v.attackable or whitelist.localprio >= v.level, v.tags
end
end
if plr == game:GetService("Players").LocalPlayer then
for i,v in self.data.WhitelistedUsers do
if v.hash == "defaultdata" then
return v.level, v.attackable or whitelist.localprio >= v.level, v.tags
end
end
end
return 0, true
end
function whitelist:isingame()
for i, v in playersService:GetPlayers() do
if self:get(v) ~= 0 then
return true
end
end
return false
end
function whitelist:tag(plr, text, rich)
local plrtag = ({self:get(plr)})[3] or self.customtags[plr.Name] or {}
if not text then return plrtag end
local newtag = ''
for i, v in plrtag do
newtag = newtag..(rich and '<font color="#'..v.color:ToHex()..'">['..v.text..']</font>' or '['..removeTags(v.text)..']')..' '
end
return newtag
end
function whitelist:hash(str)
if self.hashes[str] == nil and sha then
self.hashes[str] = sha.sha512(str..'SelfReport')
end
return self.hashes[str] or ''
end
function whitelist:getplayer(arg)
if arg == 'default' and self.localprio == 0 then return true end
if arg == 'private' and self.localprio == 1 then return true end
if arg and lplr.Name:lower():sub(1, arg:len()) == arg:lower() then return true end
return false
end
function whitelist:playeradded(v, joined)
if self:get(v) ~= 0 then
if self.alreadychecked[v.UserId] then return end
self.alreadychecked[v.UserId] = true
self:hook()
if self.localprio == 0 then
olduninject = GuiLibrary.SelfDestruct
GuiLibrary.SelfDestruct = function() warningNotification('Vape', 'No escaping the private members :)', 10) end
if joined then task.wait(10) end
if textChatService.ChatVersion == Enum.ChatVersion.TextChatService then
local oldchannel = textChatService.ChatInputBarConfiguration.TargetTextChannel
local newchannel = cloneref(game:GetService('RobloxReplicatedStorage')).ExperienceChat.WhisperChat:InvokeServer(v.UserId)
if newchannel then newchannel:SendAsync('helloimusinginhaler') end
textChatService.ChatInputBarConfiguration.TargetTextChannel = oldchannel
elseif replicatedStorage:FindFirstChild('DefaultChatSystemChatEvents') then
replicatedStorage.DefaultChatSystemChatEvents.SayMessageRequest:FireServer('/w '..v.Name..' helloimusinginhaler', 'All')
end
end
end
end
function whitelist:checkmessage(msg, plr)
local otherprio = self:get(plr)
if plr == lplr and msg == 'helloimusinginhaler' then return true end
if self.localprio > 0 and self.said[plr.Name] == nil and msg == 'helloimusinginhaler' and plr ~= lplr then
self.said[plr.Name] = true
warningNotification('Vape', plr.Name..' is using vape!', 60)
self.customtags[plr.Name] = {{text = 'VAPE USER', color = Color3.new(1, 1, 0)}}
local newent = entityLibrary.getEntity(plr)
if newent then entityLibrary.Events.EntityUpdated:Fire(newent) end
return true
end
if self.localprio < otherprio or plr == lplr then
local args = msg:split(' ')
table.remove(args, 1)
if self:getplayer(args[1]) then
table.remove(args, 1)
for i,v in self.commands do
if msg:len() >= (i:len() + 1) and msg:sub(1, i:len() + 1):lower() == ";"..i:lower() then
v(plr, args)
return true
end
end
end
end
return false
end
function whitelist:newchat(obj, plr, skip)
obj.Text = self:tag(plr, true, true)..obj.Text
local sub = obj.ContentText:find(': ')
if sub then
if not skip and self:checkmessage(obj.ContentText:sub(sub + 3, #obj.ContentText), plr) then
obj.Visible = false
end
end
end
function whitelist:oldchat(func)
local msgtable = debug.getupvalue(func, 3)
if typeof(msgtable) == 'table' and msgtable.CurrentChannel then
whitelist.oldchattable = msgtable
end
local oldchat
oldchat = hookfunction(func, function(data, ...)
local plr = playersService:GetPlayerByUserId(data.SpeakerUserId)
if plr then
data.ExtraData.Tags = data.ExtraData.Tags or {}
for i, v in self:tag(plr) do
table.insert(data.ExtraData.Tags, {TagText = v.text, TagColor = v.color})
end
if data.Message and self:checkmessage(data.Message, plr) then data.Message = '' end
end
return oldchat(data, ...) end)
table.insert(vapeConnections, {Disconnect = function() hookfunction(func, oldchat) end})
end
function whitelist:hook()
if self.hooked then return end
self.hooked = true
local exp = coreGui:FindFirstChild('ExperienceChat')
if exp then
local bubblechat = exp:WaitForChild('bubbleChat', 5)
if bubblechat then
table.insert(vapeConnections, bubblechat.DescendantAdded:Connect(function(newbubble)
if newbubble:IsA('TextLabel') and newbubble.Text:find('helloimusinginhaler') then
newbubble.Parent.Parent.Visible = false
end
end))
end
end
if textChatService.ChatVersion == Enum.ChatVersion.TextChatService then
if exp then
table.insert(vapeConnections, exp:FindFirstChild('RCTScrollContentView', true).ChildAdded:Connect(function(obj)
local plr = playersService:GetPlayerByUserId(tonumber(obj.Name:split('-')[1]) or 0)
obj = obj:FindFirstChild('TextMessage', true)
if obj then
if plr then
self:newchat(obj, plr, true)
obj:GetPropertyChangedSignal('Text'):Wait()
self:newchat(obj, plr)
end
if obj.ContentText:sub(1, 35) == 'You are now privately chatting with' then
obj.Visible = false
end
end
end))
end
elseif replicatedStorage:FindFirstChild('DefaultChatSystemChatEvents') then
pcall(function()
for i, v in getconnections(replicatedStorage.DefaultChatSystemChatEvents.OnNewMessage.OnClientEvent) do
if v.Function and table.find(debug.getconstants(v.Function), 'UpdateMessagePostedInChannel') then
whitelist:oldchat(v.Function)
break
end
end
for i, v in getconnections(replicatedStorage.DefaultChatSystemChatEvents.OnMessageDoneFiltering.OnClientEvent) do
if v.Function and table.find(debug.getconstants(v.Function), 'UpdateMessageFiltered') then
whitelist:oldchat(v.Function)
break
end
end
end)
end
end
function whitelist:check(first)
local whitelistloaded, err = pcall(function()
local _, subbed = pcall(function() return game:HttpGet('https://github.com/Erchobg/whitelists'):sub(100000, 160000) end)
local commit = subbed:find('spoofed_commit_check')
commit = commit and subbed:sub(commit + 21, commit + 60) or nil
commit = commit and #commit == 40 and commit or 'main'
whitelist.textdata = game:HttpGet('https://raw.githubusercontent.com/Erchobg/whitelists/'..commit..'/PlayerWhitelist.json', true)
end)
if not whitelistloaded or not sha or not whitelist.get then return true end
whitelist.loaded = true
if not first or whitelist.textdata ~= whitelist.olddata then
if not first then
whitelist.olddata = isfile('vape/profiles/whitelist.json') and readfile('vape/profiles/whitelist.json') or nil
end
whitelist.data = game:GetService('HttpService'):JSONDecode(whitelist.textdata)
whitelist.localprio = whitelist:get(lplr)
for i, v in whitelist.data.WhitelistedUsers do
if v.tags then
for i2, v2 in v.tags do
v2.color = Color3.fromRGB(unpack(v2.color))
end
end
end
for i, v in playersService:GetPlayers() do whitelist:playeradded(v) end
if not whitelist.connection then
whitelist.connection = playersService.PlayerAdded:Connect(function(v) whitelist:playeradded(v, true) end)
end
if (entityLibrary.isAlive or #entityLibrary.entityList > 0) then
entityLibrary.fullEntityRefresh()
end
if whitelist.textdata ~= whitelist.olddata then
if whitelist.data.Announcement.expiretime > os.time() then
local targets = whitelist.data.Announcement.targets == 'all' and {tostring(lplr.UserId)} or targets:split(',')
if table.find(targets, tostring(lplr.UserId)) then
local hint = Instance.new('Hint')
hint.Text = 'VAPE ANNOUNCEMENT: '..whitelist.data.Announcement.text
hint.Parent = workspace
game:GetService('Debris'):AddItem(hint, 20)
end
end
whitelist.olddata = whitelist.textdata
pcall(function() writefile('vape/profiles/whitelist.json', whitelist.textdata) end)
end
if whitelist.data.KillVape then
GuiLibrary.SelfDestruct()
return true
end
if whitelist.data.BlacklistedUsers[tostring(lplr.UserId)] then
task.spawn(lplr.kick, lplr, whitelist.data.BlacklistedUsers[tostring(lplr.UserId)])
return true
end
end
end
whitelist.commands = {
byfron = function()
task.spawn(function()
if setthreadcaps then setthreadcaps(8) end
if setthreadidentity then setthreadidentity(8) end
local UIBlox = getrenv().require(game:GetService('CorePackages').UIBlox)
local Roact = getrenv().require(game:GetService('CorePackages').Roact)
UIBlox.init(getrenv().require(game:GetService('CorePackages').Workspace.Packages.RobloxAppUIBloxConfig))
local auth = getrenv().require(coreGui.RobloxGui.Modules.LuaApp.Components.Moderation.ModerationPrompt)
local darktheme = getrenv().require(game:GetService('CorePackages').Workspace.Packages.Style).Themes.DarkTheme
--local Montserrat = getrenv().require(game:GetService('CorePackages').Workspace.Packages.Style).Fonts.Montserrat
local tLocalization = getrenv().require(game:GetService('CorePackages').Workspace.Packages.RobloxAppLocales).Localization
local a = getrenv().require(game:GetService('CorePackages').Workspace.Packages.Localization).LocalizationProvider
lplr.PlayerGui:ClearAllChildren()
vape.gui.Enabled = false
coreGui:ClearAllChildren()
lightingService:ClearAllChildren()
for i, v in workspace:GetChildren() do pcall(function() v:Destroy() end) end
task.wait(0.2)
lplr.kick(lplr)
guiService:ClearError()
task.wait(2)
local gui = Instance.new('ScreenGui')
gui.IgnoreGuiInset = true
gui.Parent = coreGui
local frame = Instance.new('ImageLabel')
frame.BorderSizePixel = 0
frame.Size = UDim2.fromScale(1, 1)