destroy actor on server but not client

On listen server, is it possible? I know it is possible to do so on the client (delete something only on client side)

When i try deleting something from the server it deletes it from all clients

Hey there @ehownoob! What’s your use case? As the server is supposed to replicate changes to it’s proxies, thus propagate the changes. The only way it would not propogate these changes is if the replication for the object was off, then it would only be client side causing sync issues in many (but not all) games. It’s often better to spawn the object client side instead of destroy it server side.

Yeah i thought so, just wanted a set of weapons to only appear at one of 3 spawn points that would be different for each player, but idk why i thought to delete them after spawning all of them for everyone. is there a way for every client (and the server) to spawn a weapon that only they can see?

You should spawn weapon for each player, but each actor is only net relevant for that one player. This way each one of them will see only actors they need

1 Like

Yep! As IrSoil said, making them random each time, and only net relevant for the specific client should do what you need! Here’s a tutorial on net relevancy, and a bonus resource called the UE4 Networking Compendium which is a great wealth of replication knowledge.

Disclaimer: One or more of these links are unaffiliated with Epic Games. Epic Games is not liable for anything that may occur outside of this Unreal Engine domain. Please exercise your best judgment when following links outside of the forums.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.