Photon healthbar ui not updated

I have an NPC who is placed in the scene (not instantiated)

Then i have the following script:

private void Update()
        {
            if (photonView.IsMine)
            {
                _hitRatio = CurrentHitPoint / MaxHitPoint;
                CurrentHitPointImage.rectTransform.localScale = new Vector3(_hitRatio, 1, 1);
               
            }
        }

However it is not updating the scale can anyone tell me what i might be missing?

In this case, everyone should see the scaling, not just the client which controls the character.
So the “IsMine” condition is not what you want in this case.