/
mud++0.33/etc/
mud++0.33/etc/guilds/
mud++0.33/help/propert/
mud++0.33/mudC/
mud++0.33/player/
mud++0.33/src/
mud++0.33/src/bcppbuilder/
mud++0.33/src/unix/
mud++0.33/src/vm/
/*
....[@@@..[@@@..............[@.................. 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-list@mailhost.net
------------------------------------------------------------------------------
objtypes.h
*/

// instead of this file include object.h

#ifndef _OBJTYPES_H
#define _OBJTYPES_H

/*
class ObjTemplate : public Object
{
	protected:
		int values;

	public:

		ObjTemplate()
		: values(0)
		{}

		ObjTemplate( const ObjTemplate & x)
		: Object(x), values(x.values)
		{}

		virtual ~ObjTemplate() {}
		virtual Object * clone() const { return new ObjTemplate(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_TEMPLATE; }

		virtual int readFromTypeSpecific( StaticInput & in );
		virtual int writeToTypeSpecific( Output & out ) const;
		virtual void reportVals( String & str ) const;
		virtual char * setVals( const String & str );

		virtual bool isTemplate() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_TEMPLATE); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_TEMPLATE ) ? true : Object::isType(type); }

		int getValues() { return values; }
		void setValues(int x) { values = x; }
};
*/

class ObjWeapon : public Object
{
	protected:
		int dam_type;
		int min_dam;
		int max_dam;

	public:

		ObjWeapon() 
		:	dam_type(0), min_dam(0), max_dam(0)
		{ }

		ObjWeapon( const ObjWeapon & x )
		:	Object( x ), dam_type(x.dam_type), min_dam(x.min_dam),
			max_dam(x.max_dam)
		{ }
	
		virtual ~ObjWeapon() {}
		virtual Object * clone() const { return new ObjWeapon(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_WEAPON; }
		virtual void reportVals( String & str ) const;
		virtual char * setVals( const String & str );

		virtual int readFromTypeSpecific( StaticInput & in );
		virtual int writeToTypeSpecific( Output & out ) const;

		virtual bool isWeapon() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_WEAPON); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_WEAPON ) ? true : Object::isType(type); }


		int getDamType() const { return dam_type; }
		void setDamType( int x ) { dam_type = x; }
		int getMinDam() const { return min_dam; }
		int getMaxDam() const { return max_dam; }

};

class ObjFood : public Object
{
	protected:
		int food_worth;

	public:

		ObjFood()
		: food_worth(0)
		{}

		ObjFood( const ObjFood & x)
		: Object(x), food_worth(x.food_worth)
		{}

		virtual ~ObjFood() {}
		virtual Object * clone() const { return new ObjFood(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_FOOD; }

		virtual int readFromTypeSpecific( StaticInput & in );
		virtual int writeToTypeSpecific( Output & out ) const;
		virtual void reportVals( String & str ) const;
		virtual char * setVals( const String & str );


		virtual bool isFood() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_FOOD); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_FOOD ) ? true : Object::isType(type); }


		int getFoodWorth() { return food_worth; }
		void setFoodWorth(int x) { food_worth = x; }

};


class ObjLiquidContainer : public Object
{
	protected:
		int amount;

	public:

		ObjLiquidContainer()
		: amount(0)
		{}

		ObjLiquidContainer( const ObjLiquidContainer & x)
		: Object(x), amount(x.amount)
		{}

		virtual ~ObjLiquidContainer() {}
		virtual Object * clone() const { return new ObjLiquidContainer(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_LIQUID_CONTAINER; }

		virtual int readFromTypeSpecific( StaticInput & in );
		virtual int writeToTypeSpecific( Output & out ) const;
		virtual void reportVals( String & str ) const;
		virtual char * setVals( const String & str );


		virtual bool isLiquidContainer() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_LIQUID_CONTAINER); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_LIQUID_CONTAINER ) ? true : Object::isType(type); }


		int getAmount() { return amount; }
		void setAmount(int x) { amount = x; }
		
};

class ObjCorpse : public Object
{
	protected:
		int values;

	public:

		ObjCorpse()
		: values(0)
		{}

		ObjCorpse( const ObjCorpse & x)
		: Object(x), values(x.values)
		{}

		virtual ~ObjCorpse() {}
		virtual Object * clone() const { return new ObjCorpse(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_CORPSE; }

		virtual int readFromTypeSpecific( StaticInput & ) {return 0;}
		virtual int writeToTypeSpecific( Output & ) const {return 0;}

		virtual bool isCorpse() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_CORPSE); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_CORPSE ) ? true : Object::isType(type); }


		int getValues() { return values; }
		void setValues(int x) { values = x; }

};

class ObjGold : public Object
{
	protected:
		int values;

	public:

		ObjGold()
		: values(0)
		{}

		ObjGold( const ObjGold & x)
		: Object(x), values(x.values)
		{}

		virtual ~ObjGold() {}
		virtual Object * clone() const { return new ObjGold(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_GOLD; }

		virtual int readFromTypeSpecific( StaticInput & ) {return 0;}
		virtual int writeToTypeSpecific( Output & ) const {return 0;}

		virtual bool isGold() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_GOLD); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_GOLD ) ? true : Object::isType(type); }


		int getValues() { return values; }
		void setValues(int x) { values = x; }

};



class ObjArmor : public Object
{
	protected:
		int values;

	public:

		ObjArmor()
		: values(0)
		{}

		ObjArmor( const ObjArmor & x)
		: Object(x), values(x.values)
		{}

		virtual ~ObjArmor() {}
		virtual Object * clone() const { return new ObjArmor(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_ARMOR; }

		virtual int readFromTypeSpecific( StaticInput & ) {return 0;}
		virtual int writeToTypeSpecific( Output & ) const {return 0;}

		virtual bool isArmor() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_ARMOR); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_ARMOR ) ? true : Object::isType(type); }

		int getValues() { return values; }
		void setValues(int x) { values = x; }
};



class ObjContainer : public Object
{
	protected:
		int values;

	public:

		ObjContainer()
		: values(0)
		{}

		ObjContainer( const ObjContainer & x)
		: Object(x), values(x.values)
		{}

		virtual ~ObjContainer() {}
		virtual Object * clone() const { return new ObjContainer(*this); }
		virtual vmtype getVMType() { return VMT_OBJ_CONTAINER; }

		virtual int readFromTypeSpecific( StaticInput & ) {return 0;}
		virtual int writeToTypeSpecific( Output & ) const {return 0;}

		virtual bool isContainer() const { return true; }
		virtual const char *typeName() const 
			{ return lookupObjTypeName(VMT_OBJ_CONTAINER); }
		virtual bool isType( int type )
			{ return (type == VMT_OBJ_CONTAINER ) ? true : Object::isType(type); }

		int getValues() { return values; }
		void setValues(int x) { values = x; }
};




#endif // _OBJTYPES_H