1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 19:19:56 +00:00

[Client] Ensure that objects searched for have a valid reference number

This commit is contained in:
David Cernat 2017-08-31 03:40:36 +03:00
parent 92553b8e29
commit f6d36d5d80

View file

@ -526,6 +526,10 @@ namespace MWWorld
*/
Ptr CellStore::searchExact (unsigned int refNumIndex, unsigned int mpNum)
{
// Ensure that all objects searched for have a valid reference number
if (refNumIndex == 0 && mpNum == 0)
return 0;
SearchExactVisitor<MWWorld::Ptr> searchVisitor;
searchVisitor.mRefNumIndexToFind = refNumIndex;
searchVisitor.mMpNumToFind = mpNum;