SyncCharacter.RpcReceiveDamage C# (CSharp) Method

RpcReceiveDamage() private method

private RpcReceiveDamage ( float damage, float bonusCristal, bool isPlayer ) : void
damage float
bonusCristal float
isPlayer bool
return void
    private void RpcReceiveDamage(float damage, float bonusCristal, bool isPlayer)
    {
        if (isLocalPlayer)
        {
            float armor = this.inventory.Armor + bonusCristal;
            this.Life -= 100 * damage / armor;
            if (this.Life == 0 && isPlayer)
                CmdIncrementKill();
        }
    }