When adding in UFUNCTION(reliable, server) causes compile error, why?



UFUNCTION(reliable, server)//set this to a server function
void ServerShouldSprint(bool bSprint);
void ServerShouldSprint_Implementation(bool bSprint);  //<--- You have this function too?  This is described in Cedric's PDF. 


The _Implementation method is the one that is actually defined in the .cpp

Hmmm…just thought of something.

You need to be sure the below include is setup. I put mine a header that is included in every cpp.


// This is NOT included by default in an empty project! It's required for replication and setting of the GetLifetimeReplicatedProps
#include "Net/UnrealNetwork.h"