I’m creating a character creation screen using a viewport frame, and my scripts work perfectly fine. Though for some reason the viewport frame doesn’t update the appearance of the character for the first time that I test it in studio. It’s weird because whenever I do it a second time and every time after, it’ll always work as it should. If I also change from the client view to the server view and back during the first time that I test it, it also refreshes it.
In the actual game it doesn’t work at all. Is this simply an issue on Roblox’s end or am I doing something wrong?
Video of refreshing and ‘fixing’ the viewport frame:
I don’t think this is belongs to Scripting Support without you showing the area of issue and console. Before blaming Roblox, I encourage that you use WaitForChild and watch variables / use breakpoints. You can notify us if anything else’s different on first try and second try, or perhaps figure it out yourself.
Interestingly enough, viewports usually have issues when tested through Roblox Studio, but fine on Roblox Standalone (from experience).
I didn’t know what other category it belonged in, sorry.
I’ve used breakpoints, and have used prints throughout my scripts to ensure that my variables are defined correctly. Even when I use WaitForChild to be sure that nothing is going undefined, the issue persists, and has worked once or twice in game, but did not work as intended a majority of the times even with prints in the scripts defining the variables being used in the F9 console. Since I’ve done all of this testing, it leaves me with not many other options to debug the issue. No clue why you think I haven’t tried figuring it out myself before posting.
I found the issue but I’m not sure how to fix it. Changing the hair accessory’s TextureId makes everything else unchangeable, and vice versa. Not sure why the TextureId works this way, or if it was something to do with viewport frames, but I may consider simply keeping original hair textures or removing the option to change the colour if there is no solution. Not using viewport frames may also be my solution.