diff --git a/GSChaos/CFeatureShuffleEntitiesPositions.cpp b/GSChaos/CFeatureShuffleEntitiesPositions.cpp index 692bfc2c..e795627c 100644 --- a/GSChaos/CFeatureShuffleEntitiesPositions.cpp +++ b/GSChaos/CFeatureShuffleEntitiesPositions.cpp @@ -13,6 +13,7 @@ void CFeatureShuffleEntitiesPositions::ActivateFeature() std::mt19937 randMT(randDev()); std::vector entPositions; + std::vector entNumbers; edict_t* e; for (int i = 1; i < sv->num_edicts; i++) @@ -30,6 +31,7 @@ void CFeatureShuffleEntitiesPositions::ActivateFeature() continue; entPositions.push_back(e->v.origin); + entNumbers.push_back(i); } } @@ -37,7 +39,7 @@ void CFeatureShuffleEntitiesPositions::ActivateFeature() for (size_t i = 0; i < entPositions.size(); i++) { - e = ORIG_EDICT_NUM(i + 1); + e = ORIG_EDICT_NUM(entNumbers[i]); if (e) { if (e->v.flags & FL_CLIENT) diff --git a/GSChaos/GSChaos.vcxproj.filters b/GSChaos/GSChaos.vcxproj.filters index 67723c6d..3a1731fd 100644 --- a/GSChaos/GSChaos.vcxproj.filters +++ b/GSChaos/GSChaos.vcxproj.filters @@ -313,6 +313,12 @@ Effects + + Effects + + + Effects + @@ -723,6 +729,12 @@ Effects + + Effects + + + Effects +