luki123luk Posted November 8, 2016 Share Posted November 8, 2016 Hello, I have a problem with the function loadString because he wants to call functions as sub-functions from another script by the argument sub-functions Code: function input () outputChatBox("asd") end calling ( input() ) function calling ( func ) loadstring(func)() -- Did not work pcall(func)() -- Did not work outputChatBox("Taken functions: "..tostring(func) ) end Link to comment
MIKI785 Posted November 8, 2016 Share Posted November 8, 2016 As the name suggests, loadstring takes a string. So the way to do it would be loadstring("input()") Why would you even want to do it this way? It makes no sense, just call input() directly. Or you could use call. Link to comment
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