Protagonist95 Posted April 9, 2016 Posted April 9, 2016 Is it possible to execute whole function with variables,loops etc in "execute command"(default admin panel),or is it only one command at a time? If it is,it would be great to have some examples.
Noki Posted April 9, 2016 Posted April 9, 2016 I believe it is, as admin uses runcode, which allows you to execute Lua code like any other resource. So if I ran function foo() outputChatBox("Someone is using runcode", root) end in runcode, then called 'foo()' after it or in another runcode command, it would output the message to all players. I've seen people use runcode with loops and timers before. So basically anything you can do in a normal script, you can do in runcode. It's quite the handy tool.
Protagonist95 Posted April 9, 2016 Author Posted April 9, 2016 I believe it is, as admin uses runcode, which allows you to execute Lua code like any other resource.So if I ran function foo() outputChatBox("Someone is using runcode", root) end in runcode, then called 'foo()' after it or in another runcode command, it would output the message to all players. I've seen people use runcode with loops and timers before. So basically anything you can do in a normal script, you can do in runcode. It's quite the handy tool. Got it,thank you
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