Replicated random character selector

Hello, I made a function where it makes the base character a random character mesh for my multiplayer game. I tried making the function replicated by making custom events but it doesn’t seem to work.

https://i.gyazo.com/4a18568975d82eb0a1cb4d94c701f7a4.png - The random character selector function

https://i.gyazo.com/6e3fc57d04bff58601ab921ee831d16c.png -custom event thing

I’d suggest using a RepNotify property.

  1. On the server pick a random integer in range and set a RepNotify property to the random value selected.
  2. In the RepNotify function, put your “Select” logic using the property value.

This will mean that the server picks a random character and then replicates the selected character index to all clients.

1 Like

It seems to work but when I create widgets that show the characters Icon characters they don’t work.

The server is ghost face but it is showing the pyramid head icon, sometimes the client’s icon matches with the characters model but sometimes it doesn’t

Hard to tell what’s going on without seeing the blueprints but the logs suggest the logic is running for both characters on both client and server.

It’s fine I fixed the problem

This actually works great. Thanks.