mirror of
				https://github.com/TES3MP/openmw-tes3mp.git
				synced 2025-11-04 06:26:42 +00:00 
			
		
		
		
	Fix incorrect reference check
This check was broken for exterior cells (empty cell id). It was superfluous anyway. A CellRef is owned by the cell it is in, so the cell must always exist.
This commit is contained in:
		
							parent
							
								
									e6e02714a0
								
							
						
					
					
						commit
						4d0bb6329a
					
				
					 1 changed files with 0 additions and 4 deletions
				
			
		| 
						 | 
					@ -48,10 +48,6 @@ void CSMTools::ReferenceCheckStage::perform(int stage, CSMDoc::Messages &message
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // Check if referenced object is in valid cell
 | 
					 | 
				
			||||||
    if (mCells.searchId(cellRef.mCell) == -1)
 | 
					 | 
				
			||||||
        messages.push_back(std::make_pair(id, " is referencing object from non existing cell " + cellRef.mCell));
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    // If object have owner, check if that owner reference is valid
 | 
					    // If object have owner, check if that owner reference is valid
 | 
				
			||||||
    if (!cellRef.mOwner.empty() && mReferencables.searchId(cellRef.mOwner) == -1)
 | 
					    if (!cellRef.mOwner.empty() && mReferencables.searchId(cellRef.mOwner) == -1)
 | 
				
			||||||
        messages.push_back(std::make_pair(id, " has non existing owner " + cellRef.mOwner));
 | 
					        messages.push_back(std::make_pair(id, " has non existing owner " + cellRef.mOwner));
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue