DOTSNET icon indicating copy to clipboard operation
DOTSNET copied to clipboard

Allow for user defined transform sync handling

Open Will-Carson opened this issue 3 years ago • 2 comments

Is your feature request related to a problem? Please describe. Currently all network entities have their transforms sync'd as a part of the NetworkIdentity component. I would like the option of having the transform sync'd at spawn and then handled however the user likes, with the "default" option being the old NetworkTransform component. Some use-cases include:

  • Spawning projectiles with an initial position, vector, and velocity and then allowing the client and server to both simulate the entity separately.
  • Using a NavMesh agent to move your entities around and only syncing the current destination to the client.
  • Probably some other stuff idk.

Describe the solution you'd like Bring back the NetworkTransform/decouple it from the NetworkEntity component. In my opinion you could strip down the Network

Describe alternatives you've considered

  • Add a "StripNetworkComponentsTagAuthoring" to entites so that after they're spawned another system can come in and strip away now unnecessary network components. The flaw with this one is that it makes it so you can't unspawn or perform really any actions on the network entity after that.
  • Add a third "DO_NOT_SYNC" to the sync direction enum. This is a fix that is technically sound but is strange from a design perspective.

Additional context The most frustrating part about this to me is that we already had this, but we took a step backwards instead of forwards by merging NetworkTransform with the NetworkEntity.

Will-Carson avatar Feb 03 '22 00:02 Will-Carson

I strongly agree with this perspective.

There are, for our applications, a lot of entities for which we never want to pay the price of delivering a transform over the network, but for which we do want some network syncing happening.

ghost avatar Feb 03 '22 22:02 ghost

+1 for that. Implementing custom interpolation. So I would like to sync them myself.

Emanx140 avatar Feb 04 '22 14:02 Emanx140