Skip to content

Commit

Permalink
Format comments and fix spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
toore committed Aug 6, 2023
1 parent 10a55d3 commit 60064df
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/cs/MonoGame.Extended.Collisions/QuadTree/QuadTree.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
namespace MonoGame.Extended.Collisions
{
/// <summary>
/// Class for doing collision handling with a quad tree.
/// Class for doing collision handling with a quad tree.
/// </summary>
public class Quadtree
{
Expand All @@ -15,7 +15,7 @@ public class Quadtree
protected HashSet<QuadtreeData> Contents = new HashSet<QuadtreeData>();

/// <summary>
/// Creates a quad tree with the given bounds.
/// Creates a quad tree with the given bounds.
/// </summary>
/// <param name="bounds">The bounds of the new quad tree.</param>
public Quadtree(RectangleF bounds)
Expand All @@ -30,17 +30,17 @@ public Quadtree(RectangleF bounds)
protected int MaxObjectsPerNode { get; set; } = DefaultMaxObjectsPerNode;

/// <summary>
/// Gets the bounds of the area contained in this quad tree.
/// Gets the bounds of the area contained in this quad tree.
/// </summary>
public RectangleF NodeBounds { get; protected set; }

/// <summary>
/// Gets whether the current node is a leaf node.
/// Gets whether the current node is a leaf node.
/// </summary>
public bool IsLeaf => Children.Count == 0;

/// <summary>
/// Counts the number of unique targets in the current Quadtree.
/// Counts the number of unique targets in the current Quadtree.
/// </summary>
/// <returns>Returns the targets of objects found.</returns>
public int NumTargets()
Expand Down Expand Up @@ -82,7 +82,7 @@ public int NumTargets()
}

/// <summary>
/// Inserts the data into the tree.
/// Inserts the data into the tree.
/// </summary>
/// <param name="data">Data being inserted.</param>
public void Insert(QuadtreeData data)
Expand Down Expand Up @@ -114,7 +114,7 @@ public void Insert(QuadtreeData data)
}

/// <summary>
/// Removes data from the Quadtree
/// Removes data from the Quadtree
/// </summary>
/// <param name="data">The data to be removed.</param>
public void Remove(QuadtreeData data)
Expand All @@ -131,7 +131,7 @@ public void Remove(QuadtreeData data)
}

/// <summary>
/// Removes unneccesary leaf nodes and simplifies the quad tree.
/// Removes unnecessary leaf nodes and simplifies the quad tree.
/// </summary>
public void Shake()
{
Expand Down Expand Up @@ -190,7 +190,7 @@ private void AddToLeaf(QuadtreeData data)
}

/// <summary>
/// Splits a quadtree into quadrants.
/// Splits a quadtree into quadrants.
/// </summary>
public void Split()
{
Expand Down Expand Up @@ -235,7 +235,7 @@ private void Clear()
}

/// <summary>
/// Queries the quadtree for targets that intersect with the given area.
/// Queries the quadtree for targets that intersect with the given area.
/// </summary>
/// <param name="area">The area to query for overlapping targets</param>
/// <returns>A unique list of targets intersected by area.</returns>
Expand Down

0 comments on commit 60064df

Please sign in to comment.