Typehinted up entity API

Did you guys think ALPHA7 changes were done?!
Sone stuff still needs some work, most notably data-properties can't be typed yet because they are just mushed into a couple of methods.
This commit is contained in:
Dylan K. Taylor
2017-08-16 19:03:39 +01:00
parent ea414ea72d
commit 741394dab1
23 changed files with 197 additions and 149 deletions

View File

@ -70,7 +70,7 @@ class PrimedTNT extends Entity implements Explosive{
}
public function canCollideWith(Entity $entity){
public function canCollideWith(Entity $entity) : bool{
return false;
}
@ -79,7 +79,7 @@ class PrimedTNT extends Entity implements Explosive{
$this->namedtag->Fuse = new ByteTag("Fuse", $this->fuse);
}
public function onUpdate($currentTick){
public function onUpdate(int $currentTick) : bool{
if($this->closed){
return false;