Hello, I am working with Unreal since few years but I am very new to multiplayer. So my question might sound silly or I may have misunderstood the concept. But I couldn’t find a similar question so here it goes.
I have an EnemySpawner class which is responsible from spawning enemies and placing them into the world. Enemies are replicated. This is basically a co-op shooter type of game.
To spawn an enemy on clients and server, I am currently using RPCs. But I’ve read that I should use RPCs for not so important things, such as audio cues, visual effects and so on. Not sure why this is the case since I can set it to Reliable (I assume all players login at the same time and there are no disconnects etc. for now).
So I decided to use OnRep events to spawn enemy in a reliable manner. But I don’t really need a variable for this. So far all the tutorials and lessons that I’ve seen ties an OnRep function to a variable using UFUNCTION(ReplicatedUsing = … ) format. I don’t really need a variable and I just need to call the function. How can I achieve this? Thanks.