Jump to content




Help. term.setBackgroundColor(data.readAll())

help

3 replies to this topic

#1 LabyStudio

  • Members
  • 39 posts

Posted 15 July 2013 - 02:37 PM

"color" file:
Spoiler


local data = fs.open("color", "r")
if data then
term.setBackgroundColor(data.readAll())
data.close()
end

3: Expected number

please help :/

#2 LBPHacker

  • Members
  • 766 posts
  • LocationBudapest, Hungary

Posted 15 July 2013 - 02:39 PM

You didn't provide any error message, but I assume you get something like "number expected". tunumber the input.
term.setBackgroundColor(tonumber(data.readAll()))


#3 LabyStudio

  • Members
  • 39 posts

Posted 15 July 2013 - 02:43 PM

View PostLBPHacker, on 15 July 2013 - 02:39 PM, said:

You didn't provide any error message, but I assume you get something like "number expected". tunumber the input.
term.setBackgroundColor(tonumber(data.readAll()))



I have posted the error message.

thank you;)

#4 Lyqyd

    Lua Liquidator

  • Moderators
  • 8,459 posts

Posted 15 July 2013 - 04:15 PM

Change the title back to something useful.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users