mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-06 01:51:51 +00:00
GiveCommand: limit max amount in line with vanilla
This commit is contained in:
parent
709a869045
commit
d144832928
@ -77,7 +77,7 @@ class GiveCommand extends VanillaCommand{
|
|||||||
$item->setCount($item->getMaxStackSize());
|
$item->setCount($item->getMaxStackSize());
|
||||||
}else{
|
}else{
|
||||||
//TODO: PHP_INT_MAX is probably a bit too much, but I don't know what the vanilla limit is
|
//TODO: PHP_INT_MAX is probably a bit too much, but I don't know what the vanilla limit is
|
||||||
$count = $this->getBoundedInt($sender, $args[2], 1, PHP_INT_MAX);
|
$count = $this->getBoundedInt($sender, $args[2], 1, 32767);
|
||||||
if($count === null){
|
if($count === null){
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user