100 posts
Posted 23 March 2013 - 07:31 AM
having issues with this bit of code. its supposed to mirror what you're doing on your computer to a monitor. i'm using advanced an advanced computer and monitors. the error is:
bios:338: [string "startup"]15: <name> or '…' expected
any help would be great. i found this piece from a post over a year ago so hopefully i can get some answers. Here's the code:
local nativeTerm = term.native or term
local function invoke(sMethod, ...)
nativeTerm[sMethod](...)
for k,sSide in pairs(redstone.getSides()) do
if peripheral.isPresent(sSide) and peripheral.getType(sSide) == "monitor" then
peripheral.call(sSide, sMethod, ...)
end
end
end
term.write = function(text) invoke("write", text) end
term.scroll = function(n) invoke("scroll", n) end
term.setCursorPos = function(x, y) invoke("setCursorPos", x, y) end
term.setCursorBlink = function(:o/>/>/>/> invoke("setCursorBlink", :o/>/>/>/> end
term.clear = function() invoke("clear") end
term.clearLine = function() invoke("clearLine") end
nativeTerm.clear()
nativeTerm.setCursorPos(1, 1)
print(os.version())
uploaded to pastebin as requested -
http://pastebin.com/H5hTGi1p
758 posts
Location
Budapest, Hungary
Posted 23 March 2013 - 07:40 AM
The code box broke the code itself - Upload startup to pastebin, please.
100 posts
Posted 23 March 2013 - 08:49 AM
uploaded to pastebin as requested. but i don't understand, what broke the code and why does pastebin fix this?
http://pastebin.com/H5hTGi1p
537 posts
Location
Copenhagen, Denmark
Posted 23 March 2013 - 09:32 AM
It's still broken. Look at the "/>"'s
997 posts
Location
Wellington, New Zealand
Posted 23 March 2013 - 01:40 PM
What's with this?
:o/>/>/>
LBPHacker thought it was a forum glitch, that's why he asked you to upload it to somewhere that's not the forum to make sure - but it's actually part of your code. What's it supposed to be?
537 posts
Location
Copenhagen, Denmark
Posted 23 March 2013 - 09:33 PM
Maybe he just copied the code from the thread and pasted in pastebin?
2088 posts
Location
South Africa
Posted 24 March 2013 - 01:35 AM
It happens because when posting, it tries to make it into an emoticon but it doesn't because it's in the code tags. Same with B)/>
B)/>
:o/>
:P/>
537 posts
Location
Copenhagen, Denmark
Posted 24 March 2013 - 05:18 AM
Get a better BBCODE interpreter, then. @forum admins
7508 posts
Location
Australia
Posted 24 March 2013 - 05:37 AM
any help would be great.
What's with this?
:o/>/>/>/>
What's it supposed to be?
replace both
:o/>/>/>/>
with
o )
and you will be all good.