Ejemplo n.º 1
0
 /// <summary>
 /// Unregisters a gravity source, if it exists
 /// </summary>
 /// <param name="source">A gravity source</param>
 public static void Unregister(GravitySource source)
 {
     Debug.Assert(
         _sources.Contains(source),
         "Unregistration of unknown gravity source!", source
         );
     _sources.Remove(source);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Registers a new gravity source
 /// </summary>
 /// <param name="source">A gravity source</param>
 public static void Register(GravitySource source)
 {
     Debug.Assert(
         !_sources.Contains(source),
         "Duplicate registration of gravity source!", source
         );
     _sources.Add(source);
 }