Is it possible to have a client Actor be destroyed by Server Actor?

Basically I am just trying to have the server spawn an actor and simultaneously have the client spawn a similar actor that can be destroyed by the Server actor later.

This works for just spawning the two types of actors, however, I have no way to tell the Client Actor to be destroyed when the Server Actor triggers their own destruction. Essentially I have no way to pass a reference for either actor to the other. Any help would be amazing, and if clarification is needed please let me know.

Normally you wouldn’t do it like that.

Only the server should spawn an object which then gets created on the client with replication, which means you have one connected object.
And if the server destroys that object later, it also gets destroyed on the client.

Thats what I did initially, but the object is running physics and it is super choppy and is unsatisfying. I have the second Actor spawned just to fulfil that satisfying tumbling object. The problem is that the Client actor sometimes lasts way longer than the server Actor so it will sometimes look like a duplication error, but it would look way better if the Client Actors were destroyed when the Server actor sleeps or is destroyed.

k if it is only something visual with no need to be replicated on client-server you have a view options on how to kill it

  1. just give it a certain life time and it dies on its own
  2. on spawn store a pointer to the spawned object in an object that replicates and use that object to control the life time, server tell that third object to kill the spawned object and it will be send to the client and kill the same object

Something like that should work
Blueprint is for the spawn controller actor that has to be replicated

Unless I missed something, This doesnt work because the Server Actor is a different actor to the Client side ones. The Server Actor re-adds a clone of itself to an ISM, then deletes itself, if the Clients also were to do this, it would create a load of ghost Instances client side (this was the first issue I had). Also, this doesnt work because there is no way to store the Server actor and Client actor in the same array/map, also storing them in two Maps/Arrays and just getting a reference from the matching IDs doesnt work either because you can only return a copy.

the id is just an integer communicated to everyone
when objects are spawned a pointer to the object is stored together with that integer
and when you want to kill the spawned object you just look into the map for the thing with that integer and kill it

the object that holds the map needs to be replicated so the one that has the blueprint I showed.
Should be a Manager/Controller something class
Maybe as a component on the playstate

I ended up resolving this by updating to the newest Hotfix and the Replication was updated to not be as jerky, so I decided to revert back to just creating the actor on the server and just replicating/ replicating movement.