if( ( equip != NULL ) && ( equip->layer() == tile.layer ) ) itemToBackpack( wearer, equip );
if( equip && ( equip->layer() == tile.layer ) ) equip->toBackpack( wearer );
void equipItem( P_CHAR wearer, P_ITEM item ){	tile_st tile;	Map->SeekTile( item->id(), &tile );	// User cannot wear the item	if( tile.layer == 0 )	{		if( online( wearer ) )			sysmessage( calcSocketFromChar( wearer ), "You cannot wear that item." );		itemToBackpack( wearer, item );		return;	}	vector< SERIAL > equipment = contsp.getData( wearer->serial );		// If n item on the same layer is already equipped, unequip it	for( UI08 i = 0; i < equipment.size(); i++ )	{		P_ITEM equip = FindItemBySerial( equipment[ i ] ); 				// Unequip the item and free the layer that way		if( ( equip != NULL ) && ( equip->layer() == tile.layer ) )			itemToBackpack( wearer, equip );		wearer->removeItemBonus( equip );	}	// *finally* equip the item	item->setContSerial( wearer->serial );	// Add the item bonuses	wearer->st = (wearer->st + item->st2);	wearer->chgDex( item->dx2 );	wearer->in = (wearer->in + item->in2);	// Play the appropiate sound	//soundeffect3( item, 0x57 );}