How To Damage A Model and Show A Unique Health Value For Each Player

Hey All,

I am making a Model of a tower that each player will destroy by shooting it. My original plan was to give the Model health by adding Humanoid to the Model. Though there will be multiple players on a server, I want the current health of the tower to be unique and respective for each player. That way Player #1 can work at destroying the tower, with the respective amount of health loss displayed. At the same time Player #2 will see a different health value, respective of the damage they have performed. The tower will ultimately be destroyed (Transparency = 1, CanCollide = false) for each player, individually.

Thought #1- The immediate problem I see is there is a singular health value for the Model tower, as part of Humanoid. It’s Health value cannot be unique for each player.

Thought #2- Instead of adding Humanoid to the tower, give each player an IntValue under their Player. Each time a player hits the tower it will change the IntValue. Once the IntValue reaches a certain value, destroy the tower…(Transparency = 1…) for just that player. Maybe make a unique health GUI for each player to see that represents the tower’s health, based off of that IntValue.

Any thoughts or suggestions?

Could you use a remote event to apply everything to a specific player’s client once the damage value reaches a certain threshold?

For the health being singular but needing enough health for multiple players, the naive solution would be to take the MaxHealth and multiply it by the amount of players who will be attacking the tower. I.e. 150 Health for 5 players = 150x5 MaxHealth for the tower. A much cleaner implementation would use something like IntValues or an array to track the players who have damaged the tower, and how much damage they have dealt.

I believe you can achieve this by making this model a Local Part for each player.
There are two videos that might help you with Local Parts:
AlvinBlox| https://youtu.be/5J6xWj4Oxdk
SteadyOn| https://youtu.be/vVN4gH_fwSU

After that you can make the tower disappear once the player destroyed it.
that will work individually for each player, but make sure to use local scripts to do it