r/ComputerCraft • u/PotatosFan • Mar 20 '24
Starting a program in startup and still being able to use the computer
I have a splash screen that print random char with random color at random position for my monitor and I want to being able to start it and still using my computer
6
Upvotes
6
u/fatboychummy Mar 20 '24 edited Mar 20 '24
The best all-round way is to use
parallel:The above works on both basic and advanced computers, but has a caveat: if the shell exits, so does the splash screen (and vice versa). You can fix this by using
parallel.waitForAllinstead, but that also has a caveat (albeit a much smaller one): if the shell exits, it will wait until the splash screen exits before properly exiting.Alternatively, if you have an advanced computer, you can make use of multishell. Rename your startup splash-screen file to something else, then in a new startup file, write:
This will open a shell tab for the splash screen.
3
u/PotatosFan Mar 20 '24
Here is the splashscreen https://pastebin.com/raw/7qcaBgvX