menu
#9648797 Implicit conversion from float -4943.778472290934 to int loses precision

Submitted by PocketMine-MP 5.8.1

General information

Version: 5.8.1
Git commit: 75a39491
Plugin involvement: Indirect
Report date: 2023-11-21 01:00:52 +0000 UTC
Server uptime: 0 days 0 hours 2 minutes 32 seconds

System Information

PHP version: 8.1.22
JIT status: Not available
Operating system: win
System banner: Windows NT IC17 10.0 build 22621 (Windows 11) AMD64

Error information

Warning: a plugin was indirectly involved in this crash. This may be a false positive. Please contact the plugin author before opening a bug ticket.
Thread: Main
Message: Implicit conversion from float -4943.778472290934 to int loses precision
File: pmsrc/src/world/World
Line: #1851
Type: ErrorException
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
	/**
* Gets the Block object at the specified coordinates.
*
* Note for plugin developers: If you are using this method a lot (thousands of times for many positions for
* example), you may want to set addToCache to false to avoid using excessive amounts of memory.
*
* @param bool $cached Whether to use the block cache for getting the block (faster, but may be inaccurate)
* @param bool $addToCache Whether to cache the block object created by this method call.
*/
public function getBlockAt(int $x, int $y, int $z, bool $cached = true, bool $addToCache = true) : Block{
$relativeBlockHash = null;
$chunkHash = World::chunkHash($x >> Chunk::COORD_BIT_SIZE, $z >> Chunk::COORD_BIT_SIZE);

if($this->isInWorld($x, $y, $z)){
$relativeBlockHash = World::chunkBlockHash($x, $y, $z);

if($cached && isset($this->blockCache[$chunkHash][$relativeBlockHash])){
return $this->blockCache[$chunkHash][$relativeBlockHash];
}

#0 pmsrc/src/world/World(1851): pocketmine\errorhandler\ErrorToExceptionHandler::handle(int 8192, string[72] Implicit conversion from float -4943.778472290934 to int loses precision, string[67] phar://C:/Portable/pmmp-api5/PocketMine-MP.phar/src/world/World.php, int 1851)
#1 C:/Users/Rene/PhpstormProjects/Plugins-API5/AdvancedVehicles/src/entities/WaterVehicle(223): pocketmine\world\World->getBlockAt(float -4943.7784722909, float 39.7, float 230.38593922682)
#2 C:/Users/Rene/PhpstormProjects/Plugins-API5/AdvancedVehicles/src/entities/WaterVehicle(126): DataLioness\AdvancedVehicles\entities\WaterVehicle->move(float -0.30763061598508, float -0.01, float 0.017000414954883)
#3 pmsrc/src/entity/Entity(1006): DataLioness\AdvancedVehicles\entities\WaterVehicle->entityBaseTick(int 1)
#4 C:/Users/Rene/PhpstormProjects/Plugins-API5/AdvancedVehicles/src/entities/VehicleBase(95): pocketmine\entity\Entity->onUpdate(int 2993)
#5 pmsrc/src/world/World(997): DataLioness\AdvancedVehicles\entities\VehicleBase->onUpdate(int 2993)
#6 pmsrc/src/world/World(922): pocketmine\world\World->actuallyDoTick(int 2993)
#7 pmsrc/src/world/WorldManager(351): pocketmine\world\World->doTick(int 2993)
#8 pmsrc/src/Server(1798): pocketmine\world\WorldManager->tick(int 2993)
#9 pmsrc/src/Server(1680): pocketmine\Server->tick()
#10 pmsrc/src/Server(1065): pocketmine\Server->tickProcessor()
#11 pmsrc/src/PocketMine(334): pocketmine\Server->__construct(object pocketmine\thread\ThreadSafeClassLoader#6, object pocketmine\utils\MainLogger#3, string[22] C:\Portable\pmmp-api5\, string[30] C:\Portable\pmmp-api5\plugins\)
#12 pmsrc/src/PocketMine(357): pocketmine\server()
#13 pmsrc(11): require(string[66] phar://C:/Portable/pmmp-api5/PocketMine-MP.phar/src/PocketMine.php)

Loaded Plugins

  • Show

Server Settings

  • Show

Installed Composer Dependencies

Installed PHP Extensions

  • Show