فهرست منبع

CGSubterraneanGate::postInit put const back

Originally I removed it when change this code to actually change object.
Though this sorting can work with constant object just fine.
ArseniyShestakov 10 سال پیش
والد
کامیت
606013c535
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      lib/mapObjects/MiscObjects.cpp

+ 1 - 1
lib/mapObjects/MiscObjects.cpp

@@ -977,7 +977,7 @@ void CGSubterraneanGate::postInit( CGameState * gs ) //matches subterranean gate
 	}
 	}
 
 
 	//sort by position
 	//sort by position
-	std::sort(gatesSplit[0].begin(), gatesSplit[0].end(), [](CGSubterraneanGate * a, CGSubterraneanGate * b)
+	std::sort(gatesSplit[0].begin(), gatesSplit[0].end(), [](const CGObjectInstance * a, const CGObjectInstance * b)
 	{
 	{
 		return a->pos < b->pos;
 		return a->pos < b->pos;
 	});
 	});