mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-06 11:57:10 +00:00
Timings: added timings for Player->checkNearEntities()
This commit is contained in:
parent
3ee6bfca2a
commit
2eaba7c936
@ -1709,7 +1709,9 @@ class Player extends Human implements CommandSender, ChunkLoader, IPlayer{
|
||||
Timings::$timerEntityBaseTick->stopTiming();
|
||||
|
||||
if(!$this->isSpectator() and $this->isAlive()){
|
||||
Timings::$playerCheckNearEntitiesTimer->startTiming();
|
||||
$this->checkNearEntities($tickDiff);
|
||||
Timings::$playerCheckNearEntitiesTimer->stopTiming();
|
||||
|
||||
if($this->speed !== null){
|
||||
if($this->onGround){
|
||||
|
@ -71,6 +71,8 @@ abstract class Timings{
|
||||
/** @var TimingsHandler */
|
||||
public static $entityMoveTimer;
|
||||
/** @var TimingsHandler */
|
||||
public static $playerCheckNearEntitiesTimer;
|
||||
/** @var TimingsHandler */
|
||||
public static $tickEntityTimer;
|
||||
/** @var TimingsHandler */
|
||||
public static $tickTileEntityTimer;
|
||||
@ -126,6 +128,7 @@ abstract class Timings{
|
||||
self::$permissionDefaultTimer = new TimingsHandler("Default Permission Calculation");
|
||||
|
||||
self::$entityMoveTimer = new TimingsHandler("** entityMove");
|
||||
self::$playerCheckNearEntitiesTimer = new TimingsHandler("** checkNearEntities");
|
||||
self::$tickEntityTimer = new TimingsHandler("** tickEntity");
|
||||
self::$tickTileEntityTimer = new TimingsHandler("** tickTileEntity");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user