diff options
author | Alexander Harkness <me@bearbin.net> | 2020-04-02 14:42:15 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-02 14:42:15 +0200 |
commit | cdc452916e3ec7e61f4a1ad822666192593b4b08 (patch) | |
tree | fcf35adfb6f907b7c2cd4388facc551cfe6c684a /src/Mobs/Cow.cpp | |
parent | Tweak attack ranges (diff) | |
download | cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar.gz cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar.bz2 cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar.lz cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar.xz cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.tar.zst cuberite-cdc452916e3ec7e61f4a1ad822666192593b4b08.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Mobs/Cow.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Mobs/Cow.cpp b/src/Mobs/Cow.cpp index a7fb0d476..559b6caea 100644 --- a/src/Mobs/Cow.cpp +++ b/src/Mobs/Cow.cpp @@ -44,10 +44,10 @@ void cCow::OnRightClicked(cPlayer & a_Player) short HeldItem = a_Player.GetEquippedItem().m_ItemType; if (HeldItem == E_ITEM_BUCKET) { + // Milk the cow. if (!a_Player.IsGameModeCreative()) { - a_Player.GetInventory().RemoveOneEquippedItem(); - a_Player.GetInventory().AddItem(cItem(E_ITEM_MILK)); + a_Player.ReplaceOneEquippedItemTossRest(cItem(E_ITEM_MILK)); } } } |