Skip to content

Commit 929f417

Browse files
authored
Refactor script.js for improved functionality
1 parent e7c2ff7 commit 929f417

1 file changed

Lines changed: 38 additions & 74 deletions

File tree

script.js

Lines changed: 38 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,15 @@
11
(function() {
2-
const LOGO_TEXT = ` _______ __ ___ \n|_ __ \\ [ | .' ..] \n | |__) | .--. | |.--. _| |_ __ _ .--. \n | ___// .'\`\\ \\| '/'\`\\ \\'-| |-'[ | | | ( (\`\\] \n _| |_ | \\__. || \\__/ | | | | \\_/ |, \`'.'. \n|_____| '.__.'[__;.__.' [___] '.__.'_/([__) ) \n [ Pobfus 1.11.01 | Suite Test ]`;
3-
4-
// Complex Test Code: Fibonacci, Print, and Junk Aimbot Logic
5-
const TEST_CODE = `-- Pobfus 1.11.01 HEAVY TEST
6-
print("Initializing CamBuscate 0.2.1 Virtualization...")
7-
8-
-- [1] Fibonacci Sequence Test
9-
local function fib(n)
10-
local a, b = 0, 1
11-
for i = 1, n do
12-
a, b = b, a + b
13-
end
14-
return a
15-
end
16-
print("Fibonacci(10): " .. tostring(fib(10)))
17-
18-
-- [2] Junk Aimbot Logic (Visual Complexity Test)
19-
local Settings = { Enabled = true, FOV = 150, Smoothness = 0.5 }
20-
local function GetClosestPlayer()
21-
local target = nil
22-
local dist = Settings.FOV
23-
-- Fake logic to test table indexing
24-
for _, p in pairs(game:GetService("Players"):GetPlayers()) do
25-
if p.Character and p.Character:FindFirstChild("Head") then
26-
target = p.Character.Head
27-
end
28-
end
29-
return target
30-
end
31-
32-
-- [3] Final Yield Test
33-
task.spawn(function()
34-
while task.wait(1) do
35-
print("Obfuscated background thread heart-beat~")
36-
end
37-
end)
38-
39-
warn("Pobfus 1.11.01: Suite Test Injected Successfully!")`;
2+
const SCRIPTS = {
3+
fib: `-- Fibonacci Algorithm Test\nlocal function fib(n)\n local a, b = 0, 1\n for i = 1, n do a, b = b, a + b end\n return a\nend\nprint("Fibonacci(10): " .. tostring(fib(10)))`,
4+
print: `-- Global Environment Test\nprint("Pobfus Studio: Kernal Check")\nwarn("CamBuscate Virtualization: Operational")\nprint("Target: Lua 5.1/Luau Environment")`,
5+
aim: `-- Userdata/CFrame Logic Test\nlocal Settings = {Smooth = 0.5, FOV = 100}\nlocal function GetTarget()\n local t = nil\n for _,v in pairs(game.Players:GetPlayers()) do \n if v.Character then t = v.Character.Head end \n end\n return t\nend\nprint("Logical Table Mapping Success")`,
6+
full: `-- High-Stress Instruction Suite\nprint("Executing Stress Test...")\nfor i = 1, 100 do\n local res = (i * math.pi) / 2\n if i % 10 == 0 then print("Step: " .. i) end\nend\nwarn("Full Instruction Cycle Complete")`
7+
};
408

419
const ROASTS = [
4210
"your decompiler likes me~ too much...",
43-
"feed me to your poor decompiler senpai!!!~",
4411
"staring at my bytecode again? how lewd~",
45-
"is that a hook? how aggressive, senpai~"
12+
"senpai, your decompiler is crying~"
4613
];
4714

4815
const _barcode = (l) => {
@@ -52,70 +19,67 @@ warn("Pobfus 1.11.01: Suite Test Injected Successfully!")`;
5219
};
5320

5421
window.onload = () => {
55-
document.getElementById('logo').textContent = LOGO_TEXT;
56-
const iEl = document.getElementById('in'), oEl = document.getElementById('out'), sEl = document.getElementById('status');
22+
const iEl = document.getElementById('in'), oEl = document.getElementById('out'),
23+
sEl = document.getElementById('status'), sel = document.getElementById('scriptSelect');
5724

58-
document.getElementById('ts').onclick = () => {
59-
iEl.value = TEST_CODE;
60-
sEl.innerText = "STATUS: HEAVY_SUITE_LOADED";
25+
const updateStatus = (msg, color) => {
26+
sEl.innerText = msg.toUpperCase();
27+
sEl.style.color = color || "var(--acc)";
28+
};
29+
30+
sel.onchange = () => {
31+
if (SCRIPTS[sel.value]) {
32+
iEl.value = SCRIPTS[sel.value];
33+
updateStatus("Loaded: " + sel.options[sel.selectedIndex].text, "var(--suc)");
34+
}
35+
};
36+
37+
document.getElementById('cl').onclick = () => {
38+
iEl.value = ""; oEl.value = ""; updateStatus("Ready", "var(--suc)");
39+
sel.selectedIndex = 0;
6140
};
6241

6342
document.getElementById('go').onclick = function() {
64-
if (!iEl.value.trim()) return;
65-
sEl.innerText = "STATUS: VIRTUALIZING...";
66-
43+
if (!iEl.value.trim()) return updateStatus("Error: No Input", "var(--err)");
44+
updateStatus("Virtualizing...", "var(--acc)");
45+
6746
setTimeout(() => {
6847
try {
69-
const key = Math.floor(Math.random() * 80) + 40;
48+
const key = Math.floor(Math.random() * 90) + 30;
7049
const raw = iEl.value;
7150
let stream = [];
7251

7352
for (let i = 0; i < raw.length; i++) {
7453
stream.push("0x" + (raw.charCodeAt(i) ^ key).toString(16).toUpperCase());
75-
// MOONSEC STYLE: Inject Roasts as table-slop
76-
if (i % 5 === 0) {
77-
const r = ROASTS[Math.floor(Math.random() * ROASTS.length)];
78-
stream.push(`"${r}_${_barcode(3)}"`);
79-
}
54+
if (i % 8 === 0) stream.push(`"${ROASTS[Math.floor(Math.random() * ROASTS.length)]}_${_barcode(3)}"`);
8055
}
8156

82-
const v = { env: _barcode(12), vm: _barcode(14), out: _barcode(10), tab: _barcode(16) };
57+
const v = { env: _barcode(10), vm: _barcode(12), out: _barcode(10), tab: _barcode(15) };
8358

84-
// BUILD THE MOONSEC BRICK
85-
let res = `--[[${LOGO_TEXT}\n[!] POBFUS_1.11.01 // CAMBUSCATE_0.2.1]]\n`;
59+
let res = `--[[ POBFUS_1.11.01 | CAMBUSCATE_VIRTUAL_VM ]]\n`;
8660
res += `local ${v.env}=(getfenv(0) or _G);local ${v.out}="";local ${v.tab}={${stream.join(',')}};`;
8761
res += `local function ${v.vm}(d,k)for _,v in pairs(d)do if type(v)=="\110\117\109\98\101\114"then `;
8862
res += `${v.out}=${v.out}..${v.env}["\115\116\114\105\110\103"]["\99\104\97\114"](${v.env}["\98\105\116\51\50"]["\98\120\111\114"](v,k))`;
8963
res += `else local _="${ROASTS[1]}" end end;`;
90-
res += `local x,e=(loadstring or load)(${v.out});if x then pcall(x)else warn("VM_FATAL_0.2.1")end end;${v.vm}(${v.tab},${key});`;
64+
res += `local x,e=(loadstring or load)(${v.out});if x then pcall(x)else warn("VM_FATAL")end end;${v.vm}(${v.tab},${key});`;
9165

9266
oEl.value = res;
93-
sEl.innerText = "STATUS: SUCCESS_1.11.01";
94-
} catch (e) {
95-
sEl.innerText = "STATUS: ENGINE_CRASH";
96-
}
97-
}, 50);
67+
updateStatus("Obfuscation Complete", "var(--suc)");
68+
} catch (e) { updateStatus("Encryption Error", "var(--err)"); }
69+
}, 100);
9870
};
9971

100-
// Universal Copy
10172
document.getElementById('cp').onclick = () => {
10273
if (!oEl.value) return;
103-
navigator.clipboard.writeText(oEl.value).then(() => {
104-
sEl.innerText = "COPIED!";
105-
});
74+
navigator.clipboard.writeText(oEl.value).then(() => updateStatus("Copied", "var(--suc)"));
10675
};
10776

108-
// Mobile/PC Download
10977
document.getElementById('dl').onclick = () => {
11078
if (!oEl.value) return;
11179
const blob = new Blob([oEl.value], { type: 'text/plain' });
112-
const url = URL.createObjectURL(blob);
11380
const a = document.createElement('a');
114-
const chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
115-
let name = "pobfus-";
116-
for(let i=0; i<20; i++) name += chars.charAt(Math.floor(Math.random() * chars.length));
117-
a.href = url;
118-
a.download = name + ".lua";
81+
a.href = URL.createObjectURL(blob);
82+
a.download = `pobfus_protected.lua`;
11983
a.click();
12084
};
12185
};

0 commit comments

Comments
 (0)