mirror of
https://github.com/halpz/re3.git
synced 2025-07-23 07:59:45 +00:00
@ -27,14 +27,14 @@ IsBuildingPointerValid(CBuilding* pBuilding)
|
||||
if (!pBuilding)
|
||||
return false;
|
||||
if (pBuilding->GetIsATreadable()) {
|
||||
int index = CPools::GetTreadablePool()->GetJustIndex((CTreadable*)pBuilding);
|
||||
int index = CPools::GetTreadablePool()->GetJustIndex_NoFreeAssert((CTreadable*)pBuilding);
|
||||
#ifdef FIX_BUGS
|
||||
return index >= 0 && index < CPools::GetTreadablePool()->GetSize();
|
||||
#else
|
||||
return index >= 0 && index <= CPools::GetTreadablePool()->GetSize();
|
||||
#endif
|
||||
} else {
|
||||
int index = CPools::GetBuildingPool()->GetJustIndex(pBuilding);
|
||||
int index = CPools::GetBuildingPool()->GetJustIndex_NoFreeAssert(pBuilding);
|
||||
#ifdef FIX_BUGS
|
||||
return index >= 0 && index < CPools::GetBuildingPool()->GetSize();
|
||||
#else
|
||||
|
@ -58,7 +58,7 @@ IsDummyPointerValid(CDummy* pDummy)
|
||||
{
|
||||
if (!pDummy)
|
||||
return false;
|
||||
int index = CPools::GetDummyPool()->GetJustIndex(pDummy);
|
||||
int index = CPools::GetDummyPool()->GetJustIndex_NoFreeAssert(pDummy);
|
||||
#ifdef FIX_BUGS
|
||||
if (index < 0 || index >= CPools::GetDummyPool()->GetSize())
|
||||
#else
|
||||
|
Reference in New Issue
Block a user