Ad
Still have questions? Join our Discord server and get real time help.
Log in to vote
0

How would I make an NPC who can only be damaged by a specific team?

Asked by
Galicate 106
2 years ago

How would i make an npc/Model with a humanoid that can only take damage from a specific team. I have guns that only damage players on different teams, but it only applys to players.

2 answers

Log in to vote
0
Answered by
Paldi 109
2 years ago

in the weapon, you would need to make it find the player's team and look if he can damage the npc if he is in the right team

Ad
Log in to vote
0
Answered by
Lolnox 47
2 years ago

You'd need to put something like a StringValue into the npc and make its value the name of a team which can damage an npc and in the script of a gun check if player's team name is the value of that string value.

Answer this question