I have an advanced computer connected to a moniter and a disk drive but cannot figure out how to make the treasure disk display on the monitor. The treasure disk is "alongtimeago".
Please help!
Thanks in advance. :)
Treasure disk displayed on moniter?
Started by Me!, Apr 01 2014 06:12 PM
6 replies to this topic
#1
Posted 01 April 2014 - 06:12 PM
#2
Posted 02 April 2014 - 02:20 AM
The only way I can find out is to run the monitor program using shell.run.
Create a file in root (This has disk. rom, etc.) called monlnch.
Type:
shell.run("cd","disk")
shell.run("monitor","alongtimeago")
Then save and exit
Then type monlnch.
monlnch = what you want the name of the launching program to be
alongtimeago = the program you want to launch
Also, you have to hold Ctrl-T to exit the program.
Create a file in root (This has disk. rom, etc.) called monlnch.
Type:
shell.run("cd","disk")
shell.run("monitor","alongtimeago")
Then save and exit
Then type monlnch.
monlnch = what you want the name of the launching program to be
alongtimeago = the program you want to launch
Also, you have to hold Ctrl-T to exit the program.
Edited by Lua.is.the.best, 02 April 2014 - 02:22 AM.
#3
Posted 02 April 2014 - 02:31 AM
The monitor program requires the monitor side as an argument, for instance:
shell.run("monitor top alongtimeago")
#5
Posted 02 April 2014 - 07:11 PM
Lyqyd, on 02 April 2014 - 02:31 AM, said:
The monitor program requires the monitor side as an argument, for instance:
shell.run("monitor top alongtimeago")
shell.run(string program, string parameters)
So:
shell.run("monitor","top","alongtimeago")
EDIT: Wow.. How did I correct a.. admin?
Edited by Lua.is.the.best, 02 April 2014 - 07:19 PM.
#6
Posted 02 April 2014 - 07:16 PM
Lua.is.the.best, on 02 April 2014 - 07:11 PM, said:
This is what the syntax should be"
shell.run(string program, string parameters)
So:
shell.run("monitor","top","alongtimeago")
shell.run(string program, string parameters)
So:
shell.run("monitor","top","alongtimeago")
You can put all of your arguments in one string using shell.run just like in Lyqyd's example.
#7
Posted 02 April 2014 - 10:50 PM
Lua.is.the.best, on 02 April 2014 - 07:11 PM, said:
Lyqyd, on 02 April 2014 - 02:31 AM, said:
The monitor program requires the monitor side as an argument, for instance:
shell.run("monitor top alongtimeago")
shell.run(string program, string parameters)
So:
shell.run("monitor","top","alongtimeago")
EDIT: Wow.. How did I correct a.. admin?
shell.run concatenates its arguments into a single string before parsing out the command, so it doesn't matter either way. You can have any combination, like shell.run("monitor top", "alongtimeago"), the function doesn't care. Future advice for correcting people: review the ComputerCraft code to be sure you know what you're talking about first. The wiki is not authoritative.
Also, the main point of my post was that you missed the monitor side argument.
2 user(s) are reading this topic
0 members, 2 guests, 0 anonymous users











