mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
tweaked drop
This commit is contained in:
parent
46ec8a5068
commit
ef4b991374
6 changed files with 23 additions and 21 deletions
|
|
@ -9,14 +9,14 @@ class CobwebBlock extends FlowableBlock{
|
|||
}
|
||||
public function getDrops(Item $item, Player $player){
|
||||
if ($item->isSword()){
|
||||
return array(
|
||||
array(287, 0, 1),
|
||||
);
|
||||
return [
|
||||
[STRING, 0, 1],
|
||||
];
|
||||
}
|
||||
elseif ($item->isShears()){
|
||||
return array(
|
||||
array(COBWEB, 0, 1),
|
||||
);
|
||||
return [
|
||||
array(COBWEB, 0, 1),
|
||||
];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -34,5 +34,7 @@ class SnowLayerBlock extends FlowableBlock{
|
|||
array(SNOWBALL, 0, 1),
|
||||
);
|
||||
}
|
||||
|
||||
return array();
|
||||
}
|
||||
}
|
||||
|
|
@ -28,9 +28,11 @@ class DeadBushBlock extends FlowableBlock{
|
|||
|
||||
public function getDrops(Item $item, Player $player){
|
||||
if($item->isShears()){
|
||||
return array(
|
||||
array(DEAD_BUSH, 0, 1),
|
||||
);
|
||||
return [
|
||||
[DEAD_BUSH, 0, 1],
|
||||
];
|
||||
}
|
||||
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
|
@ -7,14 +7,9 @@ class GravelBlock extends FallableBlock{
|
|||
}
|
||||
|
||||
public function getDrops(Item $item, Player $player){
|
||||
if(mt_rand(1,10) === 1){
|
||||
return array(
|
||||
array(FLINT, 0, 1),
|
||||
);
|
||||
}
|
||||
return array(
|
||||
array(GRAVEL, 0, 1),
|
||||
);
|
||||
return [
|
||||
[mt_rand(1,10) ? FLINT : GRAVEL, 0, 1],
|
||||
];
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -30,7 +30,9 @@ class LitPumpkinBlock extends SolidBlock implements LightingBlock{
|
|||
}
|
||||
|
||||
public function getDrops(Item $item, Player $player){
|
||||
return [[JACK_O_LANTERN, 0]];
|
||||
return [
|
||||
[JACK_O_LANTERN, 0]
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -8,10 +8,11 @@ class SnowBlock extends SolidBlock{
|
|||
|
||||
public function getDrops(Item $item, Player $player){
|
||||
if($item->isShovel() !== false){
|
||||
return array(
|
||||
array(SNOWBALL, 0, 4),
|
||||
);
|
||||
return [
|
||||
[SNOWBALL, 0, 4],
|
||||
];
|
||||
}
|
||||
return [];
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue