mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 03:59:43 +00:00
12 lines
No EOL
244 B
PHP
12 lines
No EOL
244 B
PHP
<?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();
|
|
}
|
|
} |