Instance.new() assistance needed

Hello, devforum community.

As I’ve started exploring roblox scripting even deeper to get to the most advanced stuff rarely any roblox developers get to, I’ve came to ask this question.

Once a script like this is called:

local Instance1 = Instance.new("ClassName")
Instance1.Name = "Whatever"

As you see, the parent isn’t assigned. Even tho the parent isn’t assigned the object as some data form still exists.

My question is:
Where is it stored and how to access that path?

If you have any questions about this, I’ll explain further.

if you do:

local Instance1 = Instance.new("ClassName")
Instance1.Name = "Whatever"

the instance that you are trying to create isnt anywhere aka it’s Parent is nil so you cannot access/locate where the instance is located because the instance is just nowhere

2 Likes

even if any data exists its just not possible to access or locate the instance you are trying to find.

1 Like

Ah, alright. Thank you. If this question I asked seems kind of “stupid”, just going to say I’m finding some unique methods for an anti cheat.

If it’s related to the client let it go or compensate with good server sanity checks or a server reliable system.

Exploiters can do more than us developers on their client, and not only with local scripts.

1 Like

If you are trying to make an anticheat. I would sincerely recommend making it a serverside. Client side is really easy to bypass. If we take your example of setting a script’s parent to nil by doing like so:

script.Parent = nil

-- Client anticheat code.

For a hacker, it is as easy as to loop through the

getnilinstances()

which returns all the instances which are parented to nil, decompile it and bypass the anticheat.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.