0

# How do you use Script.Source with multiple lines?

im making a plugin, and it should make a script but i dont know how it would make multiple lines, my current code

local toolbar = plugin:CreateToolbar("Create Part")
local CHS = game:GetService("ChangeHistoryService")

button.Click:Connect(function()
leaderstats.Source = "-- i need help here lol"
end)


0
wf_sh 15
3 months ago

You can create a multi-line string literal using either double square brackets or the \n (newline) escape sequence.

print([[
Hello
World!
]])

print("Hello\nWorld!")


In your case, I would simply use the first option and copy paste the code into the string.