コード例 #1
0
 private static AvailableNetworkSessionCollection Find(NetworkSessionType sessionType, int hostGamer, int maxLocalGamers, NetworkSessionProperties searchProperties)
 {
     try
     {
         if (maxLocalGamers < 1 || maxLocalGamers > 4)
         {
             throw new ArgumentOutOfRangeException("maxLocalGamers must be between 1 and 4.");
         }
         List <AvailableNetworkSession> list = new List <AvailableNetworkSession>();
         MonoGamerPeer.Find(sessionType);
         return(new AvailableNetworkSessionCollection((IList <AvailableNetworkSession>)list));
     }
     finally
     {
     }
 }