Beispiel #1
0
        public static Level GetRandomPlayerFromAll()
        {
            int index = new Random().Next(0, ResourcesManager.GetAllPlayerIds().Count);

            return(ResourcesManager.GetPlayer(ResourcesManager.GetAllPlayerIds()[index]));
        }
Beispiel #2
0
        /// <summary>
        ///     This function return the data of a random player in database.
        /// </summary>
        /// <returns>Data of a random player.</returns>
        public static Level GetRandomPlayerFromAll()
        {
            var index = m_vRandomSeed.Next(0, ResourcesManager.GetAllPlayerIds().Count); //accès concurrent KO

            return(ResourcesManager.GetPlayer(ResourcesManager.GetAllPlayerIds()[index]));
        }
Beispiel #3
0
        public static Level GetRandomPlayerFromAll()
        {
            int index = ObjectManager.m_vRandomSeed.Next(0, ResourcesManager.GetAllPlayerIds().Count);

            return(ResourcesManager.GetPlayer(ResourcesManager.GetAllPlayerIds()[index], false));
        }