snowballs and eggs

This commit is contained in:
GameHerobrine 2024-03-24 05:35:38 +03:00
parent 105b09e28f
commit 3df03ae96b
10 changed files with 304 additions and 34 deletions

View file

@ -0,0 +1,11 @@
<?php
class ThrownSnowball extends Projectile{
const TYPE = OBJECT_SNOWBALL;
public function onHit(MovingObjectPosition $hitResult){
if($hitResult->typeOfHit == 1){
$hitResult->entityHit->harm(0, $this->eid);
}
$this->close();
}
}