Replace the face if one is equiped

So I want to make a script where if one face is equipped that script can change it

Here is the code i tried:

local Player = game.Players.LocalPlayer
local decal = part.Decal
local character = Player.Character

if character.Head.face.Texture == "rbxassetid://28999175" then
	character.Head.face.Texture = "rbxassetid://56936322"

Btw this script is in StarterCharacterScripts.

You will want to use Instance:WaitForChild() to firstly find if the face decal even exists. When the Character first loads in, there is a chance not everything will be available to reference right away. If you run this script before the face has loaded in, it will error as it cannot find it.

:WaitForChild(object, 2) would be better as WaitForChild(object) yeilds until it finds the object.