From: PilzAdam Date: Mon, 20 May 2013 18:31:38 +0000 (+0200) Subject: Dont animate changing wielditem from hand to hand X-Git-Tag: 0.4.7~14^2~14 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e57dc4ef1899fd172b94dc67c3a70be49803145e;p=oweals%2Fminetest.git Dont animate changing wielditem from hand to hand --- diff --git a/src/camera.cpp b/src/camera.cpp index f227bd98a..acefff7e7 100644 --- a/src/camera.cpp +++ b/src/camera.cpp @@ -588,7 +588,8 @@ void Camera::wield(const ItemStack &item, u16 playeritem) IItemDefManager *idef = m_gamedef->idef(); std::string itemname = item.getDefinition(idef).name; m_wield_mesh_next = idef->getWieldMesh(itemname, m_gamedef); - if(playeritem != m_previous_playeritem) { + if(playeritem != m_previous_playeritem && + !(m_previous_itemname == "" && itemname == "")) { m_previous_playeritem = playeritem; m_previous_itemname = itemname; if(m_wield_change_timer >= 0.125)