mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-01 23:59:53 +00:00
Level: clean up and remove checkTime()
This commit is contained in:
parent
22d9260a3b
commit
d850a84d0d
@ -755,17 +755,6 @@ class Level implements ChunkManager, Metadatable{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @internal
|
|
||||||
*/
|
|
||||||
public function checkTime(){
|
|
||||||
if($this->stopTime){
|
|
||||||
return;
|
|
||||||
}else{
|
|
||||||
++$this->time;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @internal
|
* @internal
|
||||||
*
|
*
|
||||||
@ -800,7 +789,9 @@ class Level implements ChunkManager, Metadatable{
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected function actuallyDoTick(int $currentTick) : void{
|
protected function actuallyDoTick(int $currentTick) : void{
|
||||||
$this->checkTime();
|
if(!$this->stopTime){
|
||||||
|
$this->time++;
|
||||||
|
}
|
||||||
|
|
||||||
$this->sunAnglePercentage = $this->computeSunAnglePercentage(); //Sun angle depends on the current time
|
$this->sunAnglePercentage = $this->computeSunAnglePercentage(); //Sun angle depends on the current time
|
||||||
$this->skyLightReduction = $this->computeSkyLightReduction(); //Sky light reduction depends on the sun angle
|
$this->skyLightReduction = $this->computeSkyLightReduction(); //Sky light reduction depends on the sun angle
|
||||||
|
Loading…
x
Reference in New Issue
Block a user