Ahh yes. On the Script | Roblox Creator Documentation info article it says the property value type for Source is a string. So that means you would have to use the newline operator \n to start a new line in the string. For example, if I wanted to create a script with the starting line: -- BuilderBob25620 made this and the following line print("Success!") I’d do something like this:
Instance.new("Script",workspace).Source = "-- BuilderBob25620 made this\nprint('Success!')"
That provides me with a new script in the workspace with the source code saying:
Woah, fast replies! Thanks, this helped me alot, I forgot that :JSONEncode has a :JSONDecode counterpart
Ahh yes. On the Script.Source info article it says the property value type for Source is a string. So that means you would have to use the newline operator \n to start a new line in the string. For example, if I wanted to create a script with the starting line: -- BuilderBob25620 made this and the following line print("Success!") I’d do something like this: