Take a look at if statements, Player.Team, and ProximityPrompt.Triggered; you should be able to do it on you own. There’s quite a few articles as well where people have had similar questions. Here’s one of them.
Learning how to do it yourself is 10x more valuable than someone copying and pasting code here!
Just to keep it more organized in my workspace. It does not matter if it’s in it, I just prefer it to be outside the proximity prompt. Personal preference is all.