mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-15 13:55:12 +00:00
Compare commits
20 Commits
Author | SHA1 | Date | |
---|---|---|---|
1bb6ac4fb6 | |||
52a891ba73 | |||
71b813d4f9 | |||
f2540a72ad | |||
7e0f6c02a1 | |||
c023c02b6c | |||
adff561483 | |||
472ffb28ff | |||
726c5652f7 | |||
fc7d297f60 | |||
7b4ef293bd | |||
3683884b9c | |||
db135788b9 | |||
7210db25b0 | |||
ada469bc45 | |||
dc8243f88b | |||
1beec348f9 | |||
7306a2d939 | |||
4bf338f783 | |||
255ff63fda |
9
.github/workflows/draft-release.yml
vendored
9
.github/workflows/draft-release.yml
vendored
@ -35,11 +35,12 @@ jobs:
|
|||||||
- name: Install Composer dependencies
|
- name: Install Composer dependencies
|
||||||
run: composer install --no-dev --prefer-dist --no-interaction --ignore-platform-reqs
|
run: composer install --no-dev --prefer-dist --no-interaction --ignore-platform-reqs
|
||||||
|
|
||||||
- name: Patch VersionInfo
|
- name: Calculate build number
|
||||||
|
id: build-number
|
||||||
run: |
|
run: |
|
||||||
BUILD_NUMBER=2000+$GITHUB_RUN_NUMBER #to stay above jenkins
|
BUILD_NUMBER=2000+$GITHUB_RUN_NUMBER #to stay above jenkins
|
||||||
echo "Build number: $BUILD_NUMBER"
|
echo "Build number: $BUILD_NUMBER"
|
||||||
sed -i "s/const BUILD_NUMBER = 0/const BUILD_NUMBER = ${BUILD_NUMBER}/" src/pocketmine/VersionInfo.php
|
echo ::set-output name=BUILD_NUMBER::$BUILD_NUMBER
|
||||||
|
|
||||||
- name: Minify BedrockData JSON files
|
- name: Minify BedrockData JSON files
|
||||||
run: php src/pocketmine/resources/vanilla/.minify_json.php
|
run: php src/pocketmine/resources/vanilla/.minify_json.php
|
||||||
@ -68,7 +69,7 @@ jobs:
|
|||||||
done
|
done
|
||||||
|
|
||||||
- name: Build PocketMine-MP.phar
|
- name: Build PocketMine-MP.phar
|
||||||
run: php -dphar.readonly=0 build/server-phar.php --git ${{ github.sha }}
|
run: php -dphar.readonly=0 build/server-phar.php --git ${{ github.sha }} --build ${{ steps.build-number.outputs.BUILD_NUMBER }}
|
||||||
|
|
||||||
- name: Get PocketMine-MP release version
|
- name: Get PocketMine-MP release version
|
||||||
id: get-pm-version
|
id: get-pm-version
|
||||||
@ -79,7 +80,7 @@ jobs:
|
|||||||
echo ::set-output name=PM_VERSION_MD::$(php -r 'require "vendor/autoload.php"; echo str_replace(".", "", \pocketmine\BASE_VERSION);')
|
echo ::set-output name=PM_VERSION_MD::$(php -r 'require "vendor/autoload.php"; echo str_replace(".", "", \pocketmine\BASE_VERSION);')
|
||||||
|
|
||||||
- name: Generate build info
|
- name: Generate build info
|
||||||
run: php build/generate-build-info-json.php ${{ github.sha }} ${{ steps.get-pm-version.outputs.PM_VERSION }} ${{ github.repository }} > build_info.json
|
run: php build/generate-build-info-json.php ${{ github.sha }} ${{ steps.get-pm-version.outputs.PM_VERSION }} ${{ github.repository }} ${{ steps.build-number.outputs.BUILD_NUMBER }} > build_info.json
|
||||||
|
|
||||||
- name: Upload release artifacts
|
- name: Upload release artifacts
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<img src="https://github.com/pmmp/PocketMine-MP/workflows/CI/badge.svg" alt="CI" />
|
<img src="https://github.com/pmmp/PocketMine-MP/workflows/CI/badge.svg" alt="CI" />
|
||||||
<a href="https://github.com/pmmp/PocketMine-MP/releases"><img src="https://img.shields.io/github/v/tag/pmmp/PocketMine-MP?label=release&logo=github" alt="GitHub tag (latest semver)" /></a>
|
<img alt="GitHub release (latest SemVer)" src="https://img.shields.io/github/v/release/pmmp/PocketMine-MP?label=release&sort=semver">
|
||||||
<a href="https://hub.docker.com/r/pmmp/pocketmine-mp"><img src="https://img.shields.io/docker/v/pmmp/pocketmine-mp?logo=docker&label=image" alt="Docker image version (latest semver)" /></a>
|
<a href="https://hub.docker.com/r/pmmp/pocketmine-mp"><img src="https://img.shields.io/docker/v/pmmp/pocketmine-mp?logo=docker&label=image" alt="Docker image version (latest semver)" /></a>
|
||||||
<a href="https://discord.gg/bmSAZBG"><img src="https://img.shields.io/discord/373199722573201408?label=discord&color=7289DA&logo=discord" alt="Discord" /></a>
|
<a href="https://discord.gg/bmSAZBG"><img src="https://img.shields.io/discord/373199722573201408?label=discord&color=7289DA&logo=discord" alt="Discord" /></a>
|
||||||
</p>
|
</p>
|
||||||
|
@ -23,15 +23,15 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
require dirname(__DIR__) . '/vendor/autoload.php';
|
require dirname(__DIR__) . '/vendor/autoload.php';
|
||||||
|
|
||||||
if(count($argv) !== 4){
|
if(count($argv) !== 5){
|
||||||
fwrite(STDERR, "required args: <git hash> <tag name> <github repo (owner/name)>");
|
fwrite(STDERR, "required args: <git hash> <tag name> <github repo (owner/name)> <build number>");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
echo json_encode([
|
echo json_encode([
|
||||||
"php_version" => sprintf("%d.%d", PHP_MAJOR_VERSION, PHP_MINOR_VERSION),
|
"php_version" => sprintf("%d.%d", PHP_MAJOR_VERSION, PHP_MINOR_VERSION),
|
||||||
"base_version" => \pocketmine\BASE_VERSION,
|
"base_version" => \pocketmine\BASE_VERSION,
|
||||||
"build" => \pocketmine\BUILD_NUMBER,
|
"build" => (int) $argv[4],
|
||||||
"is_dev" => \pocketmine\IS_DEVELOPMENT_BUILD,
|
"is_dev" => \pocketmine\IS_DEVELOPMENT_BUILD,
|
||||||
"channel" => \pocketmine\BUILD_CHANNEL,
|
"channel" => \pocketmine\BUILD_CHANNEL,
|
||||||
"git_commit" => $argv[1],
|
"git_commit" => $argv[1],
|
||||||
|
@ -24,64 +24,95 @@ declare(strict_types=1);
|
|||||||
namespace pocketmine\build\make_release;
|
namespace pocketmine\build\make_release;
|
||||||
|
|
||||||
use pocketmine\utils\VersionString;
|
use pocketmine\utils\VersionString;
|
||||||
use function count;
|
use function array_keys;
|
||||||
|
use function array_map;
|
||||||
use function dirname;
|
use function dirname;
|
||||||
use function fgets;
|
use function fgets;
|
||||||
use function file_get_contents;
|
use function file_get_contents;
|
||||||
use function file_put_contents;
|
use function file_put_contents;
|
||||||
use function fwrite;
|
use function fwrite;
|
||||||
|
use function getopt;
|
||||||
|
use function is_string;
|
||||||
|
use function max;
|
||||||
use function preg_replace;
|
use function preg_replace;
|
||||||
use function sleep;
|
use function sleep;
|
||||||
use function sprintf;
|
use function sprintf;
|
||||||
|
use function str_pad;
|
||||||
|
use function strlen;
|
||||||
use function system;
|
use function system;
|
||||||
use const pocketmine\BASE_VERSION;
|
use const pocketmine\BASE_VERSION;
|
||||||
|
use const pocketmine\BUILD_CHANNEL;
|
||||||
use const STDERR;
|
use const STDERR;
|
||||||
use const STDIN;
|
use const STDIN;
|
||||||
|
use const STDOUT;
|
||||||
|
use const STR_PAD_LEFT;
|
||||||
|
|
||||||
require_once dirname(__DIR__) . '/vendor/autoload.php';
|
require_once dirname(__DIR__) . '/vendor/autoload.php';
|
||||||
|
|
||||||
function replaceVersion(string $versionInfoPath, string $newVersion, bool $isDev, string $channel) : void{
|
function replaceVersion(string $versionInfoPath, string $newVersion, bool $isDev, string $channel) : void{
|
||||||
$versionInfo = file_get_contents($versionInfoPath);
|
$versionInfo = file_get_contents($versionInfoPath);
|
||||||
$versionInfo = preg_replace(
|
$versionInfo = preg_replace(
|
||||||
$pattern = '/^const BASE_VERSION = "(\d+)\.(\d+)\.(\d+)(?:-(.*))?";$/m',
|
$pattern = '/^([\t ]*public )?const BASE_VERSION = "(\d+)\.(\d+)\.(\d+)(?:-(.*))?";$/m',
|
||||||
'const BASE_VERSION = "' . $newVersion . '";',
|
'$1const BASE_VERSION = "' . $newVersion . '";',
|
||||||
$versionInfo
|
$versionInfo
|
||||||
);
|
);
|
||||||
$versionInfo = preg_replace(
|
$versionInfo = preg_replace(
|
||||||
'/^const IS_DEVELOPMENT_BUILD = (?:true|false);$/m',
|
'/^([\t ]*public )?const IS_DEVELOPMENT_BUILD = (?:true|false);$/m',
|
||||||
'const IS_DEVELOPMENT_BUILD = ' . ($isDev ? 'true' : 'false') . ';',
|
'$1const IS_DEVELOPMENT_BUILD = ' . ($isDev ? 'true' : 'false') . ';',
|
||||||
$versionInfo
|
$versionInfo
|
||||||
);
|
);
|
||||||
$versionInfo = preg_replace(
|
$versionInfo = preg_replace(
|
||||||
'/^const BUILD_CHANNEL = ".*";$/m',
|
'/^([\t ]*public )?const BUILD_CHANNEL = ".*";$/m',
|
||||||
'const BUILD_CHANNEL = "' . $channel . '";',
|
'$1const BUILD_CHANNEL = "' . $channel . '";',
|
||||||
$versionInfo
|
$versionInfo
|
||||||
);
|
);
|
||||||
file_put_contents($versionInfoPath, $versionInfo);
|
file_put_contents($versionInfoPath, $versionInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
const ACCEPTED_OPTS = [
|
||||||
* @param string[] $argv
|
"current" => "Version to insert and tag",
|
||||||
* @phpstan-param list<string> $argv
|
"next" => "Version to put in the file after tagging",
|
||||||
*/
|
"channel" => "Release channel to post this build into"
|
||||||
function main(array $argv) : void{
|
];
|
||||||
if(count($argv) < 2){
|
|
||||||
fwrite(STDERR, "Arguments: <channel> [release version]\n");
|
function main() : void{
|
||||||
exit(1);
|
$filteredOpts = [];
|
||||||
|
foreach(getopt("", ["current:", "next:", "channel:", "help"]) as $optName => $optValue){
|
||||||
|
if($optName === "help"){
|
||||||
|
fwrite(STDOUT, "Options:\n");
|
||||||
|
|
||||||
|
$maxLength = max(array_map(fn(string $str) => strlen($str), array_keys(ACCEPTED_OPTS)));
|
||||||
|
foreach(ACCEPTED_OPTS as $acceptedName => $description){
|
||||||
|
fwrite(STDOUT, str_pad("--$acceptedName", $maxLength + 4, " ", STR_PAD_LEFT) . ": $description\n");
|
||||||
|
}
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
if(!is_string($optValue)){
|
||||||
|
fwrite(STDERR, "--$optName expects exactly 1 value\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
$filteredOpts[$optName] = $optValue;
|
||||||
}
|
}
|
||||||
if(isset($argv[2])){
|
|
||||||
$currentVer = new VersionString($argv[2]);
|
if(isset($filteredOpts["current"])){
|
||||||
|
$currentVer = new VersionString($filteredOpts["current"]);
|
||||||
}else{
|
}else{
|
||||||
$currentVer = new VersionString(BASE_VERSION);
|
$currentVer = new VersionString(BASE_VERSION);
|
||||||
}
|
}
|
||||||
$nextVer = new VersionString(sprintf(
|
if(isset($filteredOpts["next"])){
|
||||||
"%u.%u.%u",
|
$nextVer = new VersionString($filteredOpts["next"]);
|
||||||
$currentVer->getMajor(),
|
}else{
|
||||||
$currentVer->getMinor(),
|
$nextVer = new VersionString(sprintf(
|
||||||
$currentVer->getPatch() + 1
|
"%u.%u.%u",
|
||||||
));
|
$currentVer->getMajor(),
|
||||||
|
$currentVer->getMinor(),
|
||||||
|
$currentVer->getPatch() + 1
|
||||||
|
));
|
||||||
|
}
|
||||||
|
$channel = $filteredOpts["channel"] ?? BUILD_CHANNEL;
|
||||||
|
|
||||||
echo "About to tag version $currentVer. Next version will be $nextVer.\n";
|
echo "About to tag version $currentVer. Next version will be $nextVer.\n";
|
||||||
|
echo "$currentVer will be published on release channel \"$channel\".\n";
|
||||||
echo "please add appropriate notes to the changelog and press enter...";
|
echo "please add appropriate notes to the changelog and press enter...";
|
||||||
fgets(STDIN);
|
fgets(STDIN);
|
||||||
system('git add "' . dirname(__DIR__) . '/changelogs"');
|
system('git add "' . dirname(__DIR__) . '/changelogs"');
|
||||||
@ -91,10 +122,10 @@ function main(array $argv) : void{
|
|||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
$versionInfoPath = dirname(__DIR__) . '/src/pocketmine/VersionInfo.php';
|
$versionInfoPath = dirname(__DIR__) . '/src/pocketmine/VersionInfo.php';
|
||||||
replaceVersion($versionInfoPath, $currentVer->getBaseVersion(), false, $argv[1]);
|
replaceVersion($versionInfoPath, $currentVer->getBaseVersion(), false, $channel);
|
||||||
system('git commit -m "Release ' . $currentVer->getBaseVersion() . '" --include "' . $versionInfoPath . '"');
|
system('git commit -m "Release ' . $currentVer->getBaseVersion() . '" --include "' . $versionInfoPath . '"');
|
||||||
system('git tag ' . $currentVer->getBaseVersion());
|
system('git tag ' . $currentVer->getBaseVersion());
|
||||||
replaceVersion($versionInfoPath, $nextVer->getBaseVersion(), true, "");
|
replaceVersion($versionInfoPath, $nextVer->getBaseVersion(), true, $channel);
|
||||||
system('git add "' . $versionInfoPath . '"');
|
system('git add "' . $versionInfoPath . '"');
|
||||||
system('git commit -m "' . $nextVer->getBaseVersion() . ' is next" --include "' . $versionInfoPath . '"');
|
system('git commit -m "' . $nextVer->getBaseVersion() . ' is next" --include "' . $versionInfoPath . '"');
|
||||||
echo "pushing changes in 5 seconds\n";
|
echo "pushing changes in 5 seconds\n";
|
||||||
@ -102,4 +133,4 @@ function main(array $argv) : void{
|
|||||||
system('git push origin HEAD ' . $currentVer->getBaseVersion());
|
system('git push origin HEAD ' . $currentVer->getBaseVersion());
|
||||||
}
|
}
|
||||||
|
|
||||||
main($argv);
|
main();
|
||||||
|
Submodule build/php updated: 365356dec1...a59722c676
@ -134,13 +134,18 @@ function main() : void{
|
|||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
$opts = getopt("", ["out:", "git:"]);
|
$opts = getopt("", ["out:", "git:", "build:"]);
|
||||||
if(isset($opts["git"])){
|
if(isset($opts["git"])){
|
||||||
$gitHash = $opts["git"];
|
$gitHash = $opts["git"];
|
||||||
}else{
|
}else{
|
||||||
$gitHash = Git::getRepositoryStatePretty(dirname(__DIR__));
|
$gitHash = Git::getRepositoryStatePretty(dirname(__DIR__));
|
||||||
echo "Git hash detected as $gitHash" . PHP_EOL;
|
echo "Git hash detected as $gitHash" . PHP_EOL;
|
||||||
}
|
}
|
||||||
|
if(isset($opts["build"])){
|
||||||
|
$build = (int) $opts["build"];
|
||||||
|
}else{
|
||||||
|
$build = 0;
|
||||||
|
}
|
||||||
foreach(buildPhar(
|
foreach(buildPhar(
|
||||||
$opts["out"] ?? getcwd() . DIRECTORY_SEPARATOR . "PocketMine-MP.phar",
|
$opts["out"] ?? getcwd() . DIRECTORY_SEPARATOR . "PocketMine-MP.phar",
|
||||||
dirname(__DIR__) . DIRECTORY_SEPARATOR,
|
dirname(__DIR__) . DIRECTORY_SEPARATOR,
|
||||||
@ -149,7 +154,8 @@ function main() : void{
|
|||||||
'vendor'
|
'vendor'
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'git' => $gitHash
|
'git' => $gitHash,
|
||||||
|
'build' => $build
|
||||||
],
|
],
|
||||||
<<<'STUB'
|
<<<'STUB'
|
||||||
<?php
|
<?php
|
||||||
|
@ -25,3 +25,11 @@ Plugin developers should **only** update their required API to this version if y
|
|||||||
# 3.25.3
|
# 3.25.3
|
||||||
- Fixed crash when players try to pickup XP while already having max XP.
|
- Fixed crash when players try to pickup XP while already having max XP.
|
||||||
- Added a sanity check to `Human->setCurrentTotalXp()` to try and catch an elusive bug that's been appearing in the wild - please get in touch if you know how to reproduce it!
|
- Added a sanity check to `Human->setCurrentTotalXp()` to try and catch an elusive bug that's been appearing in the wild - please get in touch if you know how to reproduce it!
|
||||||
|
|
||||||
|
# 3.25.4
|
||||||
|
- Fixed a long-standing issue with `Player->removeWindow()` breaking inventory UIs on the client.
|
||||||
|
|
||||||
|
# 3.25.5
|
||||||
|
- Protocol: Fixed incorrect encoding in `StructureSettings`
|
||||||
|
- Fixed reading tags from non-docblock comments in script plugins.
|
||||||
|
- Build number is now defined in phar metadata instead of being patched into the source code directly.
|
||||||
|
@ -38,7 +38,7 @@
|
|||||||
"pocketmine/spl": "^0.4.0"
|
"pocketmine/spl": "^0.4.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"phpstan/phpstan": "1.1.1",
|
"phpstan/phpstan": "1.2.0",
|
||||||
"phpstan/phpstan-phpunit": "^1.0.0",
|
"phpstan/phpstan-phpunit": "^1.0.0",
|
||||||
"phpstan/phpstan-strict-rules": "^1.0.0",
|
"phpstan/phpstan-strict-rules": "^1.0.0",
|
||||||
"phpunit/phpunit": "^9.2"
|
"phpunit/phpunit": "^9.2"
|
||||||
|
69
composer.lock
generated
69
composer.lock
generated
@ -4,7 +4,7 @@
|
|||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "5a6a10488d889d0f844cce59e6c34809",
|
"content-hash": "f13c4ed7311b99ac07dca31d2f77ad1d",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "adhocore/json-comment",
|
"name": "adhocore/json-comment",
|
||||||
@ -484,6 +484,7 @@
|
|||||||
"issues": "https://github.com/pmmp/SPL/issues",
|
"issues": "https://github.com/pmmp/SPL/issues",
|
||||||
"source": "https://github.com/pmmp/SPL/tree/0.4.2"
|
"source": "https://github.com/pmmp/SPL/tree/0.4.2"
|
||||||
},
|
},
|
||||||
|
"abandoned": true,
|
||||||
"time": "2021-01-15T15:15:23+00:00"
|
"time": "2021-01-15T15:15:23+00:00"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
@ -617,16 +618,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "nikic/php-parser",
|
"name": "nikic/php-parser",
|
||||||
"version": "v4.13.0",
|
"version": "v4.13.1",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/nikic/PHP-Parser.git",
|
"url": "https://github.com/nikic/PHP-Parser.git",
|
||||||
"reference": "50953a2691a922aa1769461637869a0a2faa3f53"
|
"reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/50953a2691a922aa1769461637869a0a2faa3f53",
|
"url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/63a79e8daa781cac14e5195e63ed8ae231dd10fd",
|
||||||
"reference": "50953a2691a922aa1769461637869a0a2faa3f53",
|
"reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -667,9 +668,9 @@
|
|||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/nikic/PHP-Parser/issues",
|
"issues": "https://github.com/nikic/PHP-Parser/issues",
|
||||||
"source": "https://github.com/nikic/PHP-Parser/tree/v4.13.0"
|
"source": "https://github.com/nikic/PHP-Parser/tree/v4.13.1"
|
||||||
},
|
},
|
||||||
"time": "2021-09-20T12:20:58+00:00"
|
"time": "2021-11-03T20:52:16+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phar-io/manifest",
|
"name": "phar-io/manifest",
|
||||||
@ -1011,16 +1012,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpstan/phpstan",
|
"name": "phpstan/phpstan",
|
||||||
"version": "1.1.1",
|
"version": "1.2.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/phpstan/phpstan.git",
|
"url": "https://github.com/phpstan/phpstan.git",
|
||||||
"reference": "cb317029197236c571c1b9305b8dd12850d8d85c"
|
"reference": "cbe085f9fdead5b6d62e4c022ca52dc9427a10ee"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/cb317029197236c571c1b9305b8dd12850d8d85c",
|
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/cbe085f9fdead5b6d62e4c022ca52dc9427a10ee",
|
||||||
"reference": "cb317029197236c571c1b9305b8dd12850d8d85c",
|
"reference": "cbe085f9fdead5b6d62e4c022ca52dc9427a10ee",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -1036,7 +1037,7 @@
|
|||||||
"type": "library",
|
"type": "library",
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
"dev-master": "1.0-dev"
|
"dev-master": "1.2-dev"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
@ -1051,7 +1052,7 @@
|
|||||||
"description": "PHPStan - PHP Static Analysis Tool",
|
"description": "PHPStan - PHP Static Analysis Tool",
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/phpstan/phpstan/issues",
|
"issues": "https://github.com/phpstan/phpstan/issues",
|
||||||
"source": "https://github.com/phpstan/phpstan/tree/1.1.1"
|
"source": "https://github.com/phpstan/phpstan/tree/1.2.0"
|
||||||
},
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
@ -1071,7 +1072,7 @@
|
|||||||
"type": "tidelift"
|
"type": "tidelift"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"time": "2021-11-06T22:46:47+00:00"
|
"time": "2021-11-18T14:09:01+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpstan/phpstan-phpunit",
|
"name": "phpstan/phpstan-phpunit",
|
||||||
@ -1130,21 +1131,21 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpstan/phpstan-strict-rules",
|
"name": "phpstan/phpstan-strict-rules",
|
||||||
"version": "1.0.0",
|
"version": "1.1.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/phpstan/phpstan-strict-rules.git",
|
"url": "https://github.com/phpstan/phpstan-strict-rules.git",
|
||||||
"reference": "7f50eb112f37fda2ef956813d3f1e9b1e69d7940"
|
"reference": "e12d55f74a8cca18c6e684c6450767e055ba7717"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/phpstan/phpstan-strict-rules/zipball/7f50eb112f37fda2ef956813d3f1e9b1e69d7940",
|
"url": "https://api.github.com/repos/phpstan/phpstan-strict-rules/zipball/e12d55f74a8cca18c6e684c6450767e055ba7717",
|
||||||
"reference": "7f50eb112f37fda2ef956813d3f1e9b1e69d7940",
|
"reference": "e12d55f74a8cca18c6e684c6450767e055ba7717",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"php": "^7.1 || ^8.0",
|
"php": "^7.1 || ^8.0",
|
||||||
"phpstan/phpstan": "^1.0"
|
"phpstan/phpstan": "^1.2.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"nikic/php-parser": "^4.13.0",
|
"nikic/php-parser": "^4.13.0",
|
||||||
@ -1175,22 +1176,22 @@
|
|||||||
"description": "Extra strict and opinionated rules for PHPStan",
|
"description": "Extra strict and opinionated rules for PHPStan",
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/phpstan/phpstan-strict-rules/issues",
|
"issues": "https://github.com/phpstan/phpstan-strict-rules/issues",
|
||||||
"source": "https://github.com/phpstan/phpstan-strict-rules/tree/1.0.0"
|
"source": "https://github.com/phpstan/phpstan-strict-rules/tree/1.1.0"
|
||||||
},
|
},
|
||||||
"time": "2021-10-11T06:57:58+00:00"
|
"time": "2021-11-18T09:30:29+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpunit/php-code-coverage",
|
"name": "phpunit/php-code-coverage",
|
||||||
"version": "9.2.8",
|
"version": "9.2.9",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
|
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
|
||||||
"reference": "cf04e88a2e3c56fc1a65488afd493325b4c1bc3e"
|
"reference": "f301eb1453c9e7a1bc912ee8b0ea9db22c60223b"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/cf04e88a2e3c56fc1a65488afd493325b4c1bc3e",
|
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f301eb1453c9e7a1bc912ee8b0ea9db22c60223b",
|
||||||
"reference": "cf04e88a2e3c56fc1a65488afd493325b4c1bc3e",
|
"reference": "f301eb1453c9e7a1bc912ee8b0ea9db22c60223b",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -1246,7 +1247,7 @@
|
|||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
|
"issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
|
||||||
"source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.8"
|
"source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.9"
|
||||||
},
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
@ -1254,7 +1255,7 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"time": "2021-10-30T08:01:38+00:00"
|
"time": "2021-11-19T15:21:02+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "phpunit/php-file-iterator",
|
"name": "phpunit/php-file-iterator",
|
||||||
@ -2029,16 +2030,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "sebastian/exporter",
|
"name": "sebastian/exporter",
|
||||||
"version": "4.0.3",
|
"version": "4.0.4",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/sebastianbergmann/exporter.git",
|
"url": "https://github.com/sebastianbergmann/exporter.git",
|
||||||
"reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65"
|
"reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65",
|
"url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/65e8b7db476c5dd267e65eea9cab77584d3cfff9",
|
||||||
"reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65",
|
"reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -2087,14 +2088,14 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"description": "Provides the functionality to export PHP variables for visualization",
|
"description": "Provides the functionality to export PHP variables for visualization",
|
||||||
"homepage": "http://www.github.com/sebastianbergmann/exporter",
|
"homepage": "https://www.github.com/sebastianbergmann/exporter",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"export",
|
"export",
|
||||||
"exporter"
|
"exporter"
|
||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/sebastianbergmann/exporter/issues",
|
"issues": "https://github.com/sebastianbergmann/exporter/issues",
|
||||||
"source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3"
|
"source": "https://github.com/sebastianbergmann/exporter/tree/4.0.4"
|
||||||
},
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
@ -2102,7 +2103,7 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"time": "2020-09-28T05:24:23+00:00"
|
"time": "2021-11-11T14:18:36+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "sebastian/global-state",
|
"name": "sebastian/global-state",
|
||||||
|
@ -4,7 +4,6 @@ includes:
|
|||||||
- tests/phpstan/configs/php-bugs.neon
|
- tests/phpstan/configs/php-bugs.neon
|
||||||
- tests/phpstan/configs/phpstan-bugs.neon
|
- tests/phpstan/configs/phpstan-bugs.neon
|
||||||
- tests/phpstan/configs/phpunit-wiring-tests.neon
|
- tests/phpstan/configs/phpunit-wiring-tests.neon
|
||||||
- tests/phpstan/configs/pthreads-bugs.neon
|
|
||||||
- tests/phpstan/configs/runtime-type-checks.neon
|
- tests/phpstan/configs/runtime-type-checks.neon
|
||||||
- tests/phpstan/configs/spl-fixed-array-sucks.neon
|
- tests/phpstan/configs/spl-fixed-array-sucks.neon
|
||||||
- vendor/phpstan/phpstan-phpunit/extension.neon
|
- vendor/phpstan/phpstan-phpunit/extension.neon
|
||||||
|
@ -353,35 +353,33 @@ class MemoryManager{
|
|||||||
file_put_contents($outputFolder . "/staticProperties.js", json_encode($staticProperties, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
file_put_contents($outputFolder . "/staticProperties.js", json_encode($staticProperties, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
||||||
$logger->info("[Dump] Wrote $staticCount static properties");
|
$logger->info("[Dump] Wrote $staticCount static properties");
|
||||||
|
|
||||||
if(isset($GLOBALS)){ //This might be null if we're on a different thread
|
$globalVariables = [];
|
||||||
$globalVariables = [];
|
$globalCount = 0;
|
||||||
$globalCount = 0;
|
|
||||||
|
|
||||||
$ignoredGlobals = [
|
$ignoredGlobals = [
|
||||||
'GLOBALS' => true,
|
'GLOBALS' => true,
|
||||||
'_SERVER' => true,
|
'_SERVER' => true,
|
||||||
'_REQUEST' => true,
|
'_REQUEST' => true,
|
||||||
'_POST' => true,
|
'_POST' => true,
|
||||||
'_GET' => true,
|
'_GET' => true,
|
||||||
'_FILES' => true,
|
'_FILES' => true,
|
||||||
'_ENV' => true,
|
'_ENV' => true,
|
||||||
'_COOKIE' => true,
|
'_COOKIE' => true,
|
||||||
'_SESSION' => true
|
'_SESSION' => true
|
||||||
];
|
];
|
||||||
|
|
||||||
foreach($GLOBALS as $varName => $value){
|
foreach($GLOBALS as $varName => $value){
|
||||||
if(isset($ignoredGlobals[$varName])){
|
if(isset($ignoredGlobals[$varName])){
|
||||||
continue;
|
continue;
|
||||||
}
|
|
||||||
|
|
||||||
$globalCount++;
|
|
||||||
$globalVariables[$varName] = self::continueDump($value, $objects, $refCounts, 0, $maxNesting, $maxStringSize);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
file_put_contents($outputFolder . "/globalVariables.js", json_encode($globalVariables, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
$globalCount++;
|
||||||
$logger->info("[Dump] Wrote $globalCount global variables");
|
$globalVariables[$varName] = self::continueDump($value, $objects, $refCounts, 0, $maxNesting, $maxStringSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
file_put_contents($outputFolder . "/globalVariables.js", json_encode($globalVariables, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
|
||||||
|
$logger->info("[Dump] Wrote $globalCount global variables");
|
||||||
|
|
||||||
$data = self::continueDump($startingObject, $objects, $refCounts, 0, $maxNesting, $maxStringSize);
|
$data = self::continueDump($startingObject, $objects, $refCounts, 0, $maxNesting, $maxStringSize);
|
||||||
|
|
||||||
do{
|
do{
|
||||||
|
@ -3124,10 +3124,22 @@ class Player extends Human implements CommandSender, ChunkLoader, IPlayer{
|
|||||||
$this->removeWindow($this->windowIndex[$packet->windowId]);
|
$this->removeWindow($this->windowIndex[$packet->windowId]);
|
||||||
$this->closingWindowId = null;
|
$this->closingWindowId = null;
|
||||||
//removeWindow handles sending the appropriate
|
//removeWindow handles sending the appropriate
|
||||||
return true;
|
}else{
|
||||||
|
/*
|
||||||
|
* TODO: HACK!
|
||||||
|
* If we told the client to remove a window on our own (e.g. a plugin called removeWindow()), our
|
||||||
|
* first ContainerClose tricks the client into behaving as if it itself asked for the window to be closed.
|
||||||
|
* This means that it will send us a ContainerClose of its own, which we must respond to the same way as if
|
||||||
|
* the client closed the window by itself.
|
||||||
|
* If we don't, the client will not be able to open any new windows.
|
||||||
|
*/
|
||||||
|
$pk = new ContainerClosePacket();
|
||||||
|
$pk->windowId = $packet->windowId;
|
||||||
|
$pk->server = false;
|
||||||
|
$this->sendDataPacket($pk);
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function handleAdventureSettings(AdventureSettingsPacket $packet) : bool{
|
public function handleAdventureSettings(AdventureSettingsPacket $packet) : bool{
|
||||||
|
@ -212,10 +212,8 @@ JIT_WARNING
|
|||||||
|
|
||||||
set_error_handler([Utils::class, 'errorExceptionHandler']);
|
set_error_handler([Utils::class, 'errorExceptionHandler']);
|
||||||
|
|
||||||
$version = new VersionString(\pocketmine\BASE_VERSION, \pocketmine\IS_DEVELOPMENT_BUILD, \pocketmine\BUILD_NUMBER);
|
|
||||||
define('pocketmine\VERSION', $version->getFullVersion(true));
|
|
||||||
|
|
||||||
$gitHash = str_repeat("00", 20);
|
$gitHash = str_repeat("00", 20);
|
||||||
|
$buildNumber = 0;
|
||||||
|
|
||||||
if(\Phar::running(true) === ""){
|
if(\Phar::running(true) === ""){
|
||||||
$gitHash = Git::getRepositoryStatePretty(\pocketmine\PATH);
|
$gitHash = Git::getRepositoryStatePretty(\pocketmine\PATH);
|
||||||
@ -225,9 +223,16 @@ JIT_WARNING
|
|||||||
if(isset($meta["git"])){
|
if(isset($meta["git"])){
|
||||||
$gitHash = $meta["git"];
|
$gitHash = $meta["git"];
|
||||||
}
|
}
|
||||||
|
if(isset($meta["build"]) && is_int($meta["build"])){
|
||||||
|
$buildNumber = $meta["build"];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
define('pocketmine\GIT_COMMIT', $gitHash);
|
define('pocketmine\GIT_COMMIT', $gitHash);
|
||||||
|
define('pocketmine\BUILD_NUMBER', $buildNumber);
|
||||||
|
|
||||||
|
$version = new VersionString(\pocketmine\BASE_VERSION, \pocketmine\IS_DEVELOPMENT_BUILD, \pocketmine\BUILD_NUMBER);
|
||||||
|
define('pocketmine\VERSION', $version->getFullVersion(true));
|
||||||
|
|
||||||
$composerGitHash = InstalledVersions::getReference('pocketmine/pocketmine-mp');
|
$composerGitHash = InstalledVersions::getReference('pocketmine/pocketmine-mp');
|
||||||
if($composerGitHash !== null){
|
if($composerGitHash !== null){
|
||||||
|
@ -33,7 +33,6 @@ if(defined('pocketmine\_VERSION_INFO_INCLUDED')){
|
|||||||
const _VERSION_INFO_INCLUDED = true;
|
const _VERSION_INFO_INCLUDED = true;
|
||||||
|
|
||||||
const NAME = "PocketMine-MP";
|
const NAME = "PocketMine-MP";
|
||||||
const BASE_VERSION = "3.25.3";
|
const BASE_VERSION = "3.25.5";
|
||||||
const IS_DEVELOPMENT_BUILD = false;
|
const IS_DEVELOPMENT_BUILD = false;
|
||||||
const BUILD_NUMBER = 0;
|
|
||||||
const BUILD_CHANNEL = "stable";
|
const BUILD_CHANNEL = "stable";
|
||||||
|
@ -786,8 +786,10 @@ class NetworkBinaryStream extends BinaryStream{
|
|||||||
$result->lastTouchedByPlayerID = $this->getEntityUniqueId();
|
$result->lastTouchedByPlayerID = $this->getEntityUniqueId();
|
||||||
$result->rotation = $this->getByte();
|
$result->rotation = $this->getByte();
|
||||||
$result->mirror = $this->getByte();
|
$result->mirror = $this->getByte();
|
||||||
$result->integrityValue = $this->getFloat();
|
$result->animationMode = $this->getByte();
|
||||||
$result->integritySeed = $this->getInt();
|
$result->animationSeconds = $this->getLFloat();
|
||||||
|
$result->integrityValue = $this->getLFloat();
|
||||||
|
$result->integritySeed = $this->getLInt();
|
||||||
$result->pivot = $this->getVector3();
|
$result->pivot = $this->getVector3();
|
||||||
|
|
||||||
return $result;
|
return $result;
|
||||||
@ -805,8 +807,10 @@ class NetworkBinaryStream extends BinaryStream{
|
|||||||
$this->putEntityUniqueId($structureSettings->lastTouchedByPlayerID);
|
$this->putEntityUniqueId($structureSettings->lastTouchedByPlayerID);
|
||||||
$this->putByte($structureSettings->rotation);
|
$this->putByte($structureSettings->rotation);
|
||||||
$this->putByte($structureSettings->mirror);
|
$this->putByte($structureSettings->mirror);
|
||||||
$this->putFloat($structureSettings->integrityValue);
|
$this->putByte($structureSettings->animationMode);
|
||||||
$this->putInt($structureSettings->integritySeed);
|
$this->putLFloat($structureSettings->animationSeconds);
|
||||||
|
$this->putLFloat($structureSettings->integrityValue);
|
||||||
|
$this->putLInt($structureSettings->integritySeed);
|
||||||
$this->putVector3($structureSettings->pivot);
|
$this->putVector3($structureSettings->pivot);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -50,6 +50,10 @@ class StructureSettings{
|
|||||||
public $rotation;
|
public $rotation;
|
||||||
/** @var int */
|
/** @var int */
|
||||||
public $mirror;
|
public $mirror;
|
||||||
|
/** @var int */
|
||||||
|
public $animationMode;
|
||||||
|
/** @var float */
|
||||||
|
public $animationSeconds;
|
||||||
/** @var float */
|
/** @var float */
|
||||||
public $integrityValue;
|
public $integrityValue;
|
||||||
/** @var int */
|
/** @var int */
|
||||||
|
@ -23,13 +23,14 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
namespace pocketmine\plugin;
|
namespace pocketmine\plugin;
|
||||||
|
|
||||||
|
use pocketmine\utils\Utils;
|
||||||
|
use function count;
|
||||||
use function file;
|
use function file;
|
||||||
|
use function implode;
|
||||||
use function is_file;
|
use function is_file;
|
||||||
use function preg_match;
|
|
||||||
use function strlen;
|
use function strlen;
|
||||||
use function strpos;
|
use function strpos;
|
||||||
use function substr;
|
use function substr;
|
||||||
use function trim;
|
|
||||||
use const FILE_IGNORE_NEW_LINES;
|
use const FILE_IGNORE_NEW_LINES;
|
||||||
use const FILE_SKIP_EMPTY_LINES;
|
use const FILE_SKIP_EMPTY_LINES;
|
||||||
|
|
||||||
@ -60,30 +61,27 @@ class ScriptPluginLoader implements PluginLoader{
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
$data = [];
|
|
||||||
|
|
||||||
$insideHeader = false;
|
$insideHeader = false;
|
||||||
|
|
||||||
|
$docCommentLines = [];
|
||||||
foreach($content as $line){
|
foreach($content as $line){
|
||||||
if(!$insideHeader and strpos($line, "/**") !== false){
|
if(!$insideHeader){
|
||||||
$insideHeader = true;
|
if(strpos($line, "/**") !== false){
|
||||||
}
|
$insideHeader = true;
|
||||||
|
}else{
|
||||||
if(preg_match("/^[ \t]+\\*[ \t]+@([a-zA-Z]+)([ \t]+(.*))?$/", $line, $matches) > 0){
|
continue;
|
||||||
$key = $matches[1];
|
|
||||||
$content = trim($matches[3] ?? "");
|
|
||||||
|
|
||||||
if($key === "notscript"){
|
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$data[$key] = $content;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if($insideHeader and strpos($line, "*/") !== false){
|
$docCommentLines[] = $line;
|
||||||
|
|
||||||
|
if(strpos($line, "*/") !== false){
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($insideHeader){
|
|
||||||
|
$data = Utils::parseDocComment(implode("\n", $docCommentLines));
|
||||||
|
if(count($data) !== 0){
|
||||||
return new PluginDescription($data);
|
return new PluginDescription($data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -30,6 +30,10 @@ if(!defined('LEVELDB_ZLIB_RAW_COMPRESSION')){
|
|||||||
define('pocketmine\COMPOSER_AUTOLOADER_PATH', dirname(__DIR__, 2) . '/vendor/autoload.php');
|
define('pocketmine\COMPOSER_AUTOLOADER_PATH', dirname(__DIR__, 2) . '/vendor/autoload.php');
|
||||||
define('pocketmine\DATA', '');
|
define('pocketmine\DATA', '');
|
||||||
define('pocketmine\GIT_COMMIT', str_repeat('00', 20));
|
define('pocketmine\GIT_COMMIT', str_repeat('00', 20));
|
||||||
|
define('pocketmine\BUILD_NUMBER', 0);
|
||||||
define('pocketmine\PLUGIN_PATH', '');
|
define('pocketmine\PLUGIN_PATH', '');
|
||||||
define('pocketmine\START_TIME', microtime(true));
|
define('pocketmine\START_TIME', microtime(true));
|
||||||
define('pocketmine\VERSION', '9.9.9');
|
define('pocketmine\VERSION', '9.9.9');
|
||||||
|
|
||||||
|
//opcache breaks PHPStan when dynamic reflection is used - see https://github.com/phpstan/phpstan-src/pull/801#issuecomment-978431013
|
||||||
|
ini_set('opcache.enable', 'off');
|
||||||
|
@ -495,6 +495,11 @@ parameters:
|
|||||||
count: 2
|
count: 2
|
||||||
path: ../../../src/pocketmine/PocketMine.php
|
path: ../../../src/pocketmine/PocketMine.php
|
||||||
|
|
||||||
|
-
|
||||||
|
message: "#^Cannot access offset 'build' on mixed\\.$#"
|
||||||
|
count: 3
|
||||||
|
path: ../../../src/pocketmine/PocketMine.php
|
||||||
|
|
||||||
-
|
-
|
||||||
message: "#^Cannot access offset 'git' on mixed\\.$#"
|
message: "#^Cannot access offset 'git' on mixed\\.$#"
|
||||||
count: 2
|
count: 2
|
||||||
|
@ -80,6 +80,11 @@ parameters:
|
|||||||
count: 1
|
count: 1
|
||||||
path: ../../../src/pocketmine/network/mcpe/protocol/DataPacket.php
|
path: ../../../src/pocketmine/network/mcpe/protocol/DataPacket.php
|
||||||
|
|
||||||
|
-
|
||||||
|
message: "#^Parameter \\#1 \\$yamlString of class pocketmine\\\\plugin\\\\PluginDescription constructor expects array\\|string, array\\<string\\> given\\.$#"
|
||||||
|
count: 1
|
||||||
|
path: ../../../src/pocketmine/plugin/ScriptPluginLoader.php
|
||||||
|
|
||||||
-
|
-
|
||||||
message: "#^Dead catch \\- ReflectionException is never thrown in the try block\\.$#"
|
message: "#^Dead catch \\- ReflectionException is never thrown in the try block\\.$#"
|
||||||
count: 2
|
count: 2
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
parameters:
|
|
||||||
ignoreErrors:
|
|
||||||
-
|
|
||||||
message: "#^Variable \\$GLOBALS in isset\\(\\) always exists and is not nullable\\.$#"
|
|
||||||
count: 1
|
|
||||||
path: ../../../src/pocketmine/MemoryManager.php
|
|
||||||
|
|
Reference in New Issue
Block a user