World: don't assume that random Vector3 are int vectors

we can safely assume this for blocks (though the type info doesn't reflect it) but this is not safe to assume for random APIs that might be used by plugins.
This commit is contained in:
Dylan K. Taylor
2023-11-06 17:15:17 +00:00
parent bbe66e8e09
commit d09af2e30d
3 changed files with 24 additions and 18 deletions

View File

@ -425,6 +425,21 @@ parameters:
count: 3
path: ../../../src/block/tile/Spawnable.php
-
message: "#^Parameter \\#1 \\$x of method pocketmine\\\\world\\\\World\\:\\:getPotentialLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/block/utils/CropGrowthHelper.php
-
message: "#^Parameter \\#2 \\$y of method pocketmine\\\\world\\\\World\\:\\:getPotentialLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/block/utils/CropGrowthHelper.php
-
message: "#^Parameter \\#3 \\$z of method pocketmine\\\\world\\\\World\\:\\:getPotentialLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/block/utils/CropGrowthHelper.php
-
message: "#^Cannot call method addParticle\\(\\) on pocketmine\\\\world\\\\World\\|null\\.$#"
count: 1
@ -910,11 +925,6 @@ parameters:
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#1 \\$x of method pocketmine\\\\world\\\\World\\:\\:getFullLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#1 \\$x of method pocketmine\\\\world\\\\World\\:\\:getTileAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
@ -940,11 +950,6 @@ parameters:
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#2 \\$y of method pocketmine\\\\world\\\\World\\:\\:getFullLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#2 \\$y of method pocketmine\\\\world\\\\World\\:\\:getTileAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
@ -975,11 +980,6 @@ parameters:
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#3 \\$z of method pocketmine\\\\world\\\\World\\:\\:getFullLightAt\\(\\) expects int, float\\|int given\\.$#"
count: 1
path: ../../../src/world/World.php
-
message: "#^Parameter \\#3 \\$z of method pocketmine\\\\world\\\\World\\:\\:getTileAt\\(\\) expects int, float\\|int given\\.$#"
count: 1