From 64479b54a300028ebcff0fd4f46b13ae9890d938 Mon Sep 17 00:00:00 2001 From: metalgearsloth Date: Thu, 22 Apr 2021 19:54:12 +1000 Subject: [PATCH] GridTileLookupTest changes for broadphase update --- Content.IntegrationTests/Tests/GridTileLookupTest.cs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Content.IntegrationTests/Tests/GridTileLookupTest.cs b/Content.IntegrationTests/Tests/GridTileLookupTest.cs index 9ea66e9c38..d67d570a3d 100644 --- a/Content.IntegrationTests/Tests/GridTileLookupTest.cs +++ b/Content.IntegrationTests/Tests/GridTileLookupTest.cs @@ -53,15 +53,13 @@ namespace Content.IntegrationTests.Tests entityManager.SpawnEntity("Dummy", new EntityCoordinates(gridOne.GridEntityId, Vector2.One)); var entityTiles = tileLookup.GetIndices(entityOne); - Assert.That(entityTiles.Count, Is.EqualTo(4)); + Assert.That(entityTiles.Count, Is.EqualTo(1)); entities = tileLookup.GetEntitiesIntersecting(entityOne).ToList(); - Assert.That(entities.Count, Is.EqualTo(5)); - - // Both dummies should be in each corner of the 0,0 tile but only one dummy intersects -1,-1 - entities = tileLookup.GetEntitiesIntersecting(gridOne.Index, new Vector2i(-1, -1)).ToList(); Assert.That(entities.Count, Is.EqualTo(1)); + entityManager.SpawnEntity("Dummy", new EntityCoordinates(gridOne.GridEntityId, Vector2.Zero)); + entities = tileLookup.GetEntitiesIntersecting(gridOne.Index, new Vector2i(0, 0)).ToList(); Assert.That(entities.Count, Is.EqualTo(2)); });