keeping randomness consistent for all players online

jackhenjackhen Posts: 26Member
edited August 7 in GUI

I am making an auto battler and am currently working on the ai for the bots. I have not implemented online capabilities yet. Im wondering how randomness works for different players online. If I call randomize(), im assuming it will generate different random seeds for each online player. But I would like all bots in the game to get seeds that are consistent for all players. How could I do this? If I use the same randomGenerator for all players will it make all online players games consistent?


  • MegalomaniakMegalomaniak Posts: 2,898Admin

    depends, are you calling it on the server side or client side. You likely want the generation be seed based and generate the seed on server then send that to clients to generate a thing off of that.

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file