Roblox Studio scripts not working?
Hello, I wanted to start making Roblox games. I've already learned a bit about Roblox Studio and know, for example, how to create parts, decals, and how to create a rope between two parts.
So I wanted to start learning scripting. I already know what variables are, how to use if and else, etc. Now I'm just starting to apply these things in Roblox Studio.
Unfortunately, my scripts aren't working, but there are no errors. I even wrote scripts from tutorials exactly the same way, but it didn't work. Besides, printing the output works, and now I'm wondering what the problem is.
I don't know if I'm typing the script incorrectly or if I need to configure something else. I've searched the internet several times for solutions, but I haven't found anything. I'm getting pretty desperate at this point, so I'll show you a few photos to help you understand.
- Photo: So you can see the script I made, and I tried changing the color of a part called "Test." I printed a word after each line, and you can see in Photo 2 that it worked. (You can't see it, but there were no errors.)
- Photo: You can see that the color has not changed but the words from the script have been printed.
I thank everyone who helps me to find a solution π
I hope someone can help me
You wrote the test the same as the color.
But you probably want to change the color of test. Go ahead.
I would recommend you to do it like this:
Because you will need it very often π
Thank you.
Look here, please.
https://devforum.roblox.com/t/change-a-parts-color/1099694/2
and here:
https://create.roblox.com/docs/tutorials/fundamentals/coding-1/object-properties
I think that’s what you’re looking for.
Addendum: In your script you create a color. That’s right, but it’s not enough. You also need to assign the color to the scene object, and as far as I see, you don’t.
Thank you.