you have to make class with this code: PHP: <?phpnamespace your_namespace;use pocketmine\entity\projectile\Throwable;class Snowball extends Throwable{ public const NETWORK_ID = self::SNOWBALL; public $gravity = 0;} then in function onEnable() put this code: PHP: Entity::registerEntity(Snowball::class, true);
PHP: public function entitymove(EntityMotionEvent $e) { if($entity instanceof Snowball) $e->setCancelled(true);}