mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
Fixed items being consumed on CREATIVE mode
This commit is contained in:
parent
6fa0ef652e
commit
9d1369bfe9
7 changed files with 30 additions and 11 deletions
|
|
@ -33,7 +33,9 @@ class DirtBlock extends SolidBlock{
|
|||
|
||||
public function onActivate(Item $item, Player $player){
|
||||
if($item->isHoe()){
|
||||
$item->useOn($this);
|
||||
if(($this->gamemode & 0x01) === 0){
|
||||
$item->useOn($this);
|
||||
}
|
||||
$this->level->setBlock($this, BlockAPI::get(FARMLAND, 0));
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue