fix: in scene NetworkObject null reference exception when hit/destroyed [MTT-11939] by fernando-cortez · Pull Request #908 · Unity-Technologies/com.unity.multiplayer.samples.coop

Conversation

@fernando-cortez

Description

This PR fixes a NullReference exception logged when striking a Breakable object with a Melee action. Health NetworkVariables and max hp values have been generated for prefabs generating exceptions.

Issue Number(s)

MTT-11939

Contribution checklist

  • [ N/A ] Tests have been added for boss room and/or utilities pack
  • Release notes have been added to the project changelog file and/or package changelog file
  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • JIRA ticket ID is in the PR title or at least one commit message
  • Include the ticket ID number within the body message of the PR to create a hyperlink
  • [ N/A ] An Index entry has been added in readme.md if applicable

kalmanbalint

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a few questions and nit picks but overall looks good :)

feel free to ignore the nit picks if it's too much hassle to handle them

@kalmanbalint

kalmanbalint

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@fernando-cortez fernando-cortez deleted the fix/in-scene-networkobject-null-reference-exception branch

April 28, 2025 20:22

2 participants

@fernando-cortez @kalmanbalint