Replicate Components Part 2

Hi @Pete_Baron / @acecase / @MyCody ,

I saw your other discussion on “Why did Replicate components work?”.

I too was confused as there was no good explanation as to why ticking this box was needed. The discussions in the thread about how this just made movement more accurate was concerning as well. I investigated this a little and I do think I have a slightly better explanation.

I couldn’t understand why the box would not move with the parent when we are moving the parent location and that location is replicated but this in fact does work. If you untick replicate components and also untick simulate physics on the cube, you will see that the cube will correctly translate up when we set the actor location.

The problem comes in when you are simulating physics and that likely has to do with how it is calculating the physics internally. If we don’t replicate the component, it looks like we are getting a smaller jump because it looks like we are just performing the velocity at the apex of the “jump”. You will then see that it tries to correct itself as the parent changes location.

My guess is that it is operating on an old transform of the cube when simulating physics on the client side because it isn’t being replicated from the server.

Hopefully this provides more insight into why this was needed.

Also I’m no expert on this so this could all be wrong but it makes sense to me and my experimentation checks out :slight_smile:

It is an interesting idea but the tick box relates to the components of an actor and physics really shouldn’t be affecting the replication. So, unticking replicating components just means the actor replicates but the component doesn’t and most importantly, doesn’t mean the components stays still. Let me explain why.

If you move the actual actor, the components themselves should move as they are located relative to their parent actor and this would be expected, after all the actor still replicates its transform. If however you move the component relative to its parent, changes shouldn’t be replicated if unchecked.

Privacy & Terms