Changed: Simplified code

--HG--
branch : develop
hg/feature/material-editor
kervala 9 years ago
parent f04ebac483
commit c0a3345c83

@ -634,12 +634,10 @@ void CPlayerCL::equip(SLOTTYPE::EVisualSlot slot, uint index, uint color)
{ {
if(SheetMngr.getItem(slot, (uint)idx)) if(SheetMngr.getItem(slot, (uint)idx))
{ {
// If the gender is a female get the right shape. const CItemSheet *itemSheet = SheetMngr.getItem(slot, (uint)idx);
if(_Gender == GSGENDER::female)
equip(slot, SheetMngr.getItem(slot, (uint)idx)->getShapeFemale()); // If the gender is a female get the right shape else get the default shape.
// Else get the default shape. equip(slot, _Gender == GSGENDER::female ? itemSheet->getShapeFemale():itemSheet->getShape());
else
equip(slot, SheetMngr.getItem(slot, (uint)idx)->getShape());
} }
} }
} }

Loading…
Cancel
Save