Jump to content

Recommended Posts

Posted

Okay so im making a sign with monitors and computer craft but how do i make mutiple lines of writing i can only make one how do i make more heres the coding

mon=peripheral.wrap("right")

mon.clear()

mon.setTextScale(5)

mon.setCursorPos(4,4)

mon.write("Hello")

Posted

You're better off not using the peripheral api. Simply,

term.clear()

term.setCursorPos(4,4)

print("line 1")

print("line 2")

Etc.

Then when you run the program, do "monitor right [program]". If you want this to be your startup program, create a new program called startup and type:

shell.run(monitor right [program])

I had the same problem today, I have no idea why there is no mon.print() method.

Posted

You only need to use the peripheral api in that way if you want the user to be interacting with the terminal at the same time you are displaying on a monitor.

For example, if you made a connect 4 game, you could display the board on a large monitor with a computer hooked up to wait for rednet messages and update the board accordingly. Each player would then have a computer that sends their move over rednet to the first computer.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...