コード例 #1
0
        private void EnsureShuffledDifferent(Fungus.IntCollection col)
        {
            var startval = col.GetSafe(0);

            col.Shuffle();
            //don't let shuffle result in the same seq
            if (col.GetSafe(0) == startval)
            {
                col[0]             = col[col.Count - 1];
                col[col.Count - 1] = startval;
            }
        }
コード例 #2
0
 public void InitTestObjects()
 {
     intColA = new GameObject().AddComponent <Fungus.IntCollection>();
     intColB = new GameObject().AddComponent <Fungus.IntCollection>();
     goCol   = new GameObject().AddComponent <Fungus.GameObjectCollection>();
 }