Example #1
0
static void playerRegisterAfterLoading( P_PLAYER pc )
{
	if ( pc->account() == 0 )
	{
		// We need to remove the equipment here.
		cBaseChar::ItemContainer container( pc->content() );
		cBaseChar::ItemContainer::const_iterator it( container.begin() );
		cBaseChar::ItemContainer::const_iterator end( container.end() );
		for ( ; it != end; ++it )
		{
			P_ITEM pItem = *it;
			if ( !pItem )
				continue;

			pItem->remove();
		}
		pc->del();
		return;
	}
	/*	else
		{
			pc->setBody(0x0190);
			Console::instance()->send("player: %s with bugged body-value detected, restored to male shape\n",pc->name().latin1());
		}*/
}