sorry to ask something this “easy” but i can’t get the replication system into my mind.
I used the RPC System from Unity before and i thought this was similar, but i already fail at destroying an actor.
First i thought, if i don’t set anything for replicate, neither in function nor on the specific Blueprint i want to destroy, it would only destroy on the player who tries to. But i directly learned that even then the Client can’t do anything.
So that differs from Unity.
Then i thought “Ok, only the Server can destroy it, so i need the client to ask the server to destroy it and than tell everyone that the actor was destroyed”.
Easy said, but i can’t get this to work. Could you be so nice a show me a Blueprint of it so i can get an idea of how to do it?
I watched the tutorial series on Youtube, but i can’t get this worked in my head. Also he never pointed out how the client could activate something. He only showed how the server presses buttons etc.
My first try was to get the Actor with a Linetrace (works) and than look who has the authority. If it’s the user, than use a custom event with “Run on server” and from this i called the destroy function with the actor plugged.
But i think this is not the way to do it, since the server doesn’t know the actor right? In Unity i can give the server the variables he needs. Do i have to save the actor into a replicated actor variable and than use the variable to destroy it?
Is it really that complicated to destroy an actor in the world? ):
I hope that’s not to basic, but i really need an example on that.
Thanks for the answers!