Hey,
You’re doing the replication wrong. You want to set the variable to a repnotify, rather than replicated. Then next you want to set the random int on the server(not multicast).
Then go to functions and there you see a newly created function called OnRepSomething and in that variable do the part that comes behind the int set.
Reason why it doesn’t work is because you’re doing the random on all clients rather than the server.