bocaj1234567 Posted January 9, 2013 Share Posted January 9, 2013 Basically, I want my rules to show on monitors. How do I save my script? Could I make the script out of game? How do I make the script run on that specific computer on startup? Link to comment Share on other sites More sharing options...
disconsented Posted January 9, 2013 Share Posted January 9, 2013 C = 0 sTime = 1 function PrintMessage(message) print(message) sleep(sTime) end while C ~= 0 do PrintMessage("1") PrintMessage("2") PrintMessage("3") PrintMessage("4") end Just change the sTime to the delay between messages Change 1,2,3 and 4 to your rules. If you want extra rules just copy and paste the PrintMessage("1") function and change the message to print. Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 10, 2013 Author Share Posted January 10, 2013 C = 0 sTime = 1 function PrintMessage(message) print(message) sleep(sTime) end while C ~= 0 do PrintMessage("1") PrintMessage("2") PrintMessage("3") PrintMessage("4") end Just change the sTime to the delay between messages Change 1,2,3 and 4 to your rules. If you want extra rules just copy and paste the PrintMessage("1") function and change the message to print. Would that make the code run at restart? How do I save that? Where do I write it? Thank you. Link to comment Share on other sites More sharing options...
disconsented Posted January 10, 2013 Share Posted January 10, 2013 You gotta save it as startup IIRC Link to comment Share on other sites More sharing options...
Portablejim Posted January 10, 2013 Share Posted January 10, 2013 The code exists on the server inside a 'computer' folder that is inside the world save, separated into the id of the computer/turtle the program is on (e.g. for the client on a single player world called "World", editing startup on the first computer they create: <tekkit folder>/saves/World/computer/0/startup). They are just text files, so open them with Notepad (I would recommend Notepad++ (Windows) or TextWrangler (OS X) instead of notepad). Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 10, 2013 Author Share Posted January 10, 2013 The code exists on the server inside a 'computer' folder that is inside the world save, separated into the id of the computer/turtle the program is on (e.g. for the client on a single player world called "World", editing startup on the first computer they create: <tekkit folder>/saves/World/computer/0/startup). They are just text files, so open them with Notepad (I would recommend Notepad++ (Windows) or TextWrangler (OS X) instead of notepad). How can I tell what number in the computer folder is the computer that I am using? Link to comment Share on other sites More sharing options...
theprolo Posted January 10, 2013 Share Posted January 10, 2013 Start up your computer, without starting a program type "lua", then type "os.getComputerID()", without the speech marks of course. If you get that in properly, it'll give you your computer number. Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 10, 2013 Author Share Posted January 10, 2013 Start up your computer, without starting a program type "lua", then type "os.getComputerID()", without the speech marks of course. If you get that in properly, it'll give you your computer number. OK thanks a lot. When I looked in the computer folders, though, I didn't find any startup files for any of the computers. Should I create the file? Link to comment Share on other sites More sharing options...
theprolo Posted January 10, 2013 Share Posted January 10, 2013 Yeah, just create the file in notepad etc. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 10, 2013 Share Posted January 10, 2013 Using the edit start up, will it also re-run when the server is restarted? Link to comment Share on other sites More sharing options...
Portablejim Posted January 10, 2013 Share Posted January 10, 2013 Using the edit start up, will it also re-run when the server is restarted? Only if the chunk gets loaded. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 11, 2013 Share Posted January 11, 2013 Only if the chunk gets loaded. That's great! I will use this in my server then! Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 11, 2013 Author Share Posted January 11, 2013 That's great! I will use this in my server then! What's your server? Link to comment Share on other sites More sharing options...
lukeb28 Posted January 11, 2013 Share Posted January 11, 2013 Its industrial age. Its coming up soon for white list and eventually public. we have one more slot for beta testers if your interested. Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 11, 2013 Author Share Posted January 11, 2013 Its industrial age. Its coming up soon for white list and eventually public. we have one more slot for beta testers if your interested. Oh OK. I own the server zeus.tekkithost.com:25573. I would like to be a beta tester... Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 11, 2013 Author Share Posted January 11, 2013 T Its industrial age. Its coming up soon for white list and eventually public. we have one more slot for beta testers if your interested. There is no one on the server ATM cause it just crashed (if you go on about now) but there were 27. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 11, 2013 Share Posted January 11, 2013 T There is no one on the server ATM cause it just crashed (if you go on about now) but there were 27. Not us. We haven't even posted on the forum yet. I'm actually trying to do that now. just Pm me like a normal whitelist app and I'll see what I can do. Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 12, 2013 Author Share Posted January 12, 2013 C = 0 sTime = 1 function PrintMessage(message) print(message) sleep(sTime) end while C ~= 0 do PrintMessage("1") PrintMessage("2") PrintMessage("3") PrintMessage("4") end Just change the sTime to the delay between messages Change 1,2,3 and 4 to your rules. If you want extra rules just copy and paste the PrintMessage("1") function and change the message to print. Wait a second.... don't I have to specify the monitor? Link to comment Share on other sites More sharing options...
lukeb28 Posted January 12, 2013 Share Posted January 12, 2013 Wait a second.... don't I have to specify the monitor? Looking at it now... Your Right! What kind of code is this? This just won't do for my server! Link to comment Share on other sites More sharing options...
bocaj1234567 Posted January 12, 2013 Author Share Posted January 12, 2013 Looking at it now... Your Right! What kind of code is this? This just won't do for my server! ... It "won't do"? It just requires a simple change I think. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 12, 2013 Share Posted January 12, 2013 ... It "won't do"? It just requires a simple change I think. I have no clue how to code with LUA. If you know the mod that needs to be made to it, why don't you post it? Link to comment Share on other sites More sharing options...
theprolo Posted January 12, 2013 Share Posted January 12, 2013 I'll post one for you, which will hopefully work better. Don't make this one your startup command: print("Message 1") print("Message 2") print ("etc.") Then there's your startup function: side = "right"--change to whatever side your monitor is on shell.run("monitor", side, "Original program name") That should work for you. Copy the print statements in the first one to add more rules, and remember to change the last part of the shell.run to your original programs name. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 12, 2013 Share Posted January 12, 2013 That should work for you. Copy the print statements in the first one to add more rules, and remember to change the last part of the shell.run to your original programs name. Thanks for the help. Funny thing is a little while ago I made a thread asking this same question and never got a response. Link to comment Share on other sites More sharing options...
theprolo Posted January 12, 2013 Share Posted January 12, 2013 I must have not been online If that hits an error, just post it here. Link to comment Share on other sites More sharing options...
lukeb28 Posted January 12, 2013 Share Posted January 12, 2013 I must have not been online If that hits an error, just post it here. I can't do it now but I will ASAP. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now