//------------------------------------------------------------------------ void CItem::ResetDualWield() { if (m_dualWieldSlaveId) { IItem *pSlave = GetDualWieldSlave(); if (pSlave) pSlave->ResetDualWield(); } SetActionSuffix(""); EnableSelect(true); m_dualWieldSlaveId = 0; m_dualWieldMasterId = 0; }
//------------------------------------------------------------------------ void CItem::SetDualWieldSlave(EntityId slaveId) { m_dualWieldSlaveId = slaveId; CItem *pSlave = static_cast<CItem *>(GetDualWieldSlave()); if (!pSlave) return; SetActionSuffix(m_sharedparams->params.dual_wield_suffix.c_str()); pSlave->EnableSelect(false); if (m_stats.hand == eIH_Left) pSlave->SetHand(eIH_Right); else pSlave->SetHand(eIH_Left); }
//------------------------------------------------------------------------ void CFists::Select(bool select) { CWeapon::Select(select); SetActionSuffix(""); if(select) { EnableUpdate(true, eIUS_General); RequestAnimState(eFAS_FIGHT); } else { EnableUpdate(false, eIUS_General); RequestAnimState(eFAS_NOSTATE); } }
//------------------------------------------------------------------------ void CItem::SetDualWieldMaster(EntityId masterId) { m_dualWieldMasterId = masterId; SetActionSuffix(m_sharedparams->params.dual_wield_suffix.c_str()); }