mud++0.35/etc/
mud++0.35/etc/guilds/
mud++0.35/help/propert/
mud++0.35/mudC/
mud++0.35/player/
mud++0.35/src/interface/
mud++0.35/src/os/cygwin32/
mud++0.35/src/os/win32/
mud++0.35/src/os/win32/bcppbuilder/
mud++0.35/src/osaddon/
mud++0.35/src/util/
/*
....[@@@..[@@@..............[@.................. MUD++ is a written from
....[@..[@..[@..[@..[@..[@@@@@....[@......[@.... scratch multi-user swords and
....[@..[@..[@..[@..[@..[@..[@..[@@@@@..[@@@@@.. sorcery game written in C++.
....[@......[@..[@..[@..[@..[@....[@......[@.... This server is an ongoing
....[@......[@..[@@@@@..[@@@@@.................. development project.  All 
................................................ contributions are welcome. 
....Copyright(C).1995.Melvin.Smith.............. Enjoy. 
------------------------------------------------------------------------------
Melvin Smith (aka Fusion)         msmith@hom.net 
MUD++ development mailing list    mudpp@van.ml.org
------------------------------------------------------------------------------
thing.cc
*/

#include "config.h"
#include "string.h"
#include "thing.h"

const bitType size_list[] =
{
	{0,			 	0				},
	{"tiny",		SIZE_TINY		},	
	{"small",		SIZE_SMALL		},		// available for players
	{"medium",		SIZE_MEDIUM		},		// available for players
	{"large",		SIZE_LARGE		},		// available for players
	{"huge",		SIZE_HUGE		},
	{"gigantic",	SIZE_GIGANTIC	},
	{0,			 	0				}
};


countedThing::countedThing( const String & arg )
{
	int c =0;
	const char * str = arg.chars();
	char buf[BUF];

	if ( !isdigit(str[0]) )     
	{
        count = 1;
        name = arg;
		return;
    }

    while ( isdigit(str[c]) )
        c++;

    if ( str[c] != '.' )
    {
        count = 1;
        name = arg;
        return;
    }

	memcpy( buf, str, c * sizeof(char) );
    count = atoi( buf );
    name = String( &str[c+1] );
}