Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I view a scripts source-code?

Asked by
0x72 20
9 years ago

I've tried to do ;

print(script:FindFirstChild'Source')

1
You can do so by Opening the script. :/ TheeDeathCaster 2368 — 9y
0
I meant printing the scripts source. qq 0x72 20 — 9y

2 answers

Log in to vote
1
Answered by
adark 5487 Badge of Merit Moderation Voter Community Moderator
9 years ago

To put it simply, you cannot.

ROBLOX locked the Source property of Scripts to stop exploits that involved them, and they will never open them again. To access the contents of a script, you're going to have to use a StringObject, and paste the script into it.

Ad
Log in to vote
0
Answered by
M39a9am3R 3210 Moderation Voter Community Moderator
9 years ago

Roblox has RobloxLocked the source property of scripts. This update prevents players from reading, modifying, removing, or adding snippets or in full of the source code due to exploiters and other Roblox Security reasons. So with that, your script will error out all the time unless the script you want to copy code from follows loadstring (off by default due to Roblox Update), and listens to a StringValue called "Source" in which case it should be script:FindFirstChild("Source").Value

0
Not sure why people would rate this down. I rated it up, just to attempt to cancel out the downratings. Nice answer. SlickPwner 534 — 9y

Answer this question