So im trying to do an initiative system for turn based combat and while i managed to make the tyrns themselves im struggling in making it so when a character's turn ends, the next to go is the one with the highest initative (ie if the first chaarcter has initiative of 5, the next to go is the one with initative 3., and then the one with 1)
(By extension you could also say this could help with checking between who has the highest or lowest value between all actors on the map, but for the sake of the question i wanna focus on initiative for now)