generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Output lines from multiline string

Previous Thread :: Next Thread 
petar66 is not online. petar66
Joined: 05 Jul 2012
Total Posts: 44
25 Feb 2017 01:56 PM
I have this multiline string wrapped to a variable, lets call this variable FIRE, and have it nested in the two tables logServer and then Catches

logServer = {
Catches = {
FIRE = ":FireServer"
}
}


function logServer.Catch(input)
for catch,flag in pairs(logServer.Catches) do
if input:match(flag) then
print(logServer.Catches[catch])
end
end
end

logServer.Catch(
[[
Object = game:GetService("ReplicatedStorage")
Object:WaitForChild("Event[SIG]:[RESPAWN]"):FireServer("UX84",2,3,8)
]])


If ran, this code will output ":FireServer", this being the value of FIRE, my question is how can I make the code output the whole line?, that being;
"Object:WaitForChild("Event[SIG]:[RESPAWN]"):FireServer("UX84",2,3,8)"
Report Abuse
petar66 is not online. petar66
Joined: 05 Jul 2012
Total Posts: 44
25 Feb 2017 02:16 PM
b
Report Abuse
petar66 is not online. petar66
Joined: 05 Jul 2012
Total Posts: 44
25 Feb 2017 02:31 PM
b
Report Abuse
petar66 is not online. petar66
Joined: 05 Jul 2012
Total Posts: 44
25 Feb 2017 02:49 PM
b
Report Abuse
10MilesWide is not online. 10MilesWide
Joined: 06 Aug 2014
Total Posts: 2220
25 Feb 2017 03:03 PM
Split the input by "\n"
Report Abuse
10MilesWide is not online. 10MilesWide
Joined: 06 Aug 2014
Total Posts: 2220
25 Feb 2017 03:04 PM
What game is this for?
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
25 Feb 2017 03:21 PM
table.concat or ### = thing..thing..thing..thing etc
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image