Dear scripters, I need help making a Face-Changer-Gui!
Could you guys please help me out?
Ilyax
Before Starting:
I am going to be telling you how to do this, guessing that you already have a ScreenGui
in StarterGui
, and inside the ScreenGui
, Insert a frame. Now, you should already have the right sizes and positions for this.
Let's Begin
Inside the frame, Insert an ImageButton
, do this and change the position of the different image buttons that you want. In this case, I am only going to do 2. Now for the Images you want the face to change to, put the decal id inside of the image label. Once all this is done, we will start scripting. Put a local script inside of your frame, and edit it accordingly.
Lets do some Variables:
local player = script.Parent.Parent.Parent.Parent local Face1 = script.Parent.Face1 local Face2 = script.Parent.Face2--Obviously what you named the face image buttons
I think that will be it for the variables, but let's finish the script
local player = script.Parent.Parent.Parent.Parent local Face1 = script.Parent.Face1 local Face2 = script.Parent.Face2 function face1 () player.face.Image = Face1.Image end function face2 () player.face.Image = Face2.Image end Face1.MouseButton1Click:Connect(face1) Face2.MouseButton1Click:Connect(face2)