How to take input of a clothing ID and putting it on a npc/humanoid

It does not work in the game you sent me it just puts the id into the shirt template and the mannequin doesn’t update.

Here is a solution I found that tackles this problem.