CTS can now coexist with other modes as a circuit (which is most official flex ctf maps)
This commit is contained in:
@@ -129,12 +129,10 @@ TEST_CASE ("r2x: a single PlayerSpawn (race) entity can be converted", "[EntityC
|
||||
std::vector<std::string> unused = ec.convert(worldspawn);
|
||||
std::vector<std::string> converted = ec.convert(entity);
|
||||
|
||||
REQUIRE (converted[0] == "\"classname\" \"info_player_race\"\n");
|
||||
REQUIRE (converted[1] == "\"target\" \"cp1\"\n");
|
||||
REQUIRE (converted[2] == "\"race_place\" \"-1\"\n");
|
||||
REQUIRE (converted[0] == "\"classname\" \"info_player_start\"\n");
|
||||
|
||||
// The z (vertical) is offset by +32
|
||||
std::istringstream iss (converted[3]);
|
||||
std::istringstream iss (converted[1]);
|
||||
std::string attribute;
|
||||
std::string coords[2];
|
||||
float offsetCoord;
|
||||
@@ -146,7 +144,7 @@ TEST_CASE ("r2x: a single PlayerSpawn (race) entity can be converted", "[EntityC
|
||||
REQUIRE (fabs(-100.00000 - offsetCoord) <= DELTA);
|
||||
|
||||
SECTION( "Converted angles are valid (Different coordinate system handedness)") {
|
||||
std::istringstream angleLineStream(converted[4]);
|
||||
std::istringstream angleLineStream(converted[2]);
|
||||
std::string angleAttribute;
|
||||
std::string a;
|
||||
float angle;
|
||||
@@ -279,7 +277,7 @@ TEST_CASE ("r2x: a single RaceStart entity can be converted", "[EntityConverter]
|
||||
|
||||
REQUIRE (converted[0] == "\"classname\" \"trigger_race_checkpoint\"\n");
|
||||
REQUIRE (converted[1] == "\"targetname\" \"cp1\"\n");
|
||||
REQUIRE (converted[2] == "\"cnt\" \"1\"\n");
|
||||
REQUIRE (converted[2] == "\"cnt\" \"0\"\n");
|
||||
}
|
||||
|
||||
|
||||
@@ -305,7 +303,7 @@ TEST_CASE ("r2x: a single RaceFinish entity can be converted", "[EntityConverter
|
||||
|
||||
REQUIRE (converted[0] == "\"classname\" \"trigger_race_checkpoint\"\n");
|
||||
REQUIRE (converted[1] == "\"targetname\" \"finish\"\n");
|
||||
REQUIRE (converted[2] == "\"cnt\" \"0\"\n");
|
||||
REQUIRE (converted[2] == "\"cnt\" \"1\"\n");
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user