So I've been confused at how people are setting the source of a LocalScript and then running it. It's just like on Script Builder, I am not sure how they do it.. Can anyone give me some help?
I see a lot of loadstring() but that's only for server-sided scripts from what I know of.
I know I am kind of asking, but I am working on a game and I am adding a control pannel, it would be nice to execute both Local and Non-Local scripts!
-Thanks!
~Expresssion
Hello, Expression!
So the loadString()
function does not run scripts. It actually runs strings. The inputted string would run like a command.
loadString("game.Players.RadioactiveSherbet.Character.Head:Destroy()")
This would run a string that would act like a command. This string would destroy my head (if I was playing).
You can learn more here
So for your case
Maybe in the GUI have a text input. And then when they type in a command and then click maybe a button. The string inside the input would run.
If this helped you, please upvote and accept answer, it helps both of us :)
Hopefully this helps, Radio
Happy coding!