* Remove CellLock class and all cell-level thread locking.

** It was wasting CPU power as cell-level locking is not needed.
** Our multithreading is on map-level, not cell-level.
** CellLock was just a 'proxy' between Cell and CellPair and in some cases carried redundant data.
** Some minor cleanup in Cell::Visit/Map::Visit.

--HG--
branch : trunk
This commit is contained in:
XTZGZoReX
2010-01-23 22:24:41 +01:00
parent fe07518baf
commit 9f00ca3eb8
24 changed files with 110 additions and 212 deletions
+2 -4
View File
@@ -1814,10 +1814,8 @@ void AuraEffect::PeriodicDummyTick(Unit * target, Unit * caster) const
TypeContainerVisitor<Trinity::UnitListSearcher<Trinity::AnyUnfriendlyVisibleUnitInObjectRangeCheck>, GridTypeMapContainer > grid_object_checker(checker);
TypeContainerVisitor<Trinity::UnitListSearcher<Trinity::AnyUnfriendlyVisibleUnitInObjectRangeCheck>, WorldTypeMapContainer > world_object_checker(checker);
CellLock<GridReadGuard> cell_lock(cell, p);
cell_lock->Visit(cell_lock, grid_object_checker, *GetBase()->GetOwner()->GetMap(), *caster, radius);
cell_lock->Visit(cell_lock, world_object_checker, *GetBase()->GetOwner()->GetMap(), *caster, radius);
cell.Visit(p, grid_object_checker, *GetBase()->GetOwner()->GetMap(), *caster, radius);
cell.Visit(p, world_object_checker, *GetBase()->GetOwner()->GetMap(), *caster, radius);
}
if(targets.empty())