Now also combat works no matter what's on the ground. Closes #81.
This commit is contained in:
parent
f84b63f0e6
commit
05d54ff661
5 changed files with 19 additions and 23 deletions
|
@ -186,7 +186,7 @@ TEST_CASE("SpatialMap::find", "[spatialmap-find]") {
|
|||
REQUIRE(no_collide != should_collide);
|
||||
}
|
||||
|
||||
TEST_CASE("SpatialMap::neighbors", "[spatialmap]") {
|
||||
TEST_CASE("SpatialMap::neighbors", "[spatialmap-neighbors]") {
|
||||
DinkyECS::World world;
|
||||
SpatialMap map;
|
||||
|
||||
|
@ -203,7 +203,7 @@ TEST_CASE("SpatialMap::neighbors", "[spatialmap]") {
|
|||
|
||||
auto result = map.neighbors(at, true);
|
||||
REQUIRE(result.found);
|
||||
REQUIRE(result.nearby.size() > 0);
|
||||
REQUIRE(result.nearby.size() == 2);
|
||||
|
||||
bool maybe = result.nearby[0] == enemy1 || result.nearby[1] == enemy1;
|
||||
REQUIRE(maybe);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue