#ifndef _3DOBJECT_H_
#define _3DOBJECT_H_

#include "../App/EngineH.h"

class C_3DOBJECT_0
{
private:
	TAshlar			_pos;
	TRGBf			_fColor;
	unsigned int	_texture_id;
	uint			_begin_tag;
	bool			_3d;
	bool			_alpha;
	bool			_blend;
	bool			_mapCoord;
	int				_natazeni;
public:
	C_3DOBJECT_0();
	C_3DOBJECT_0(TAshlar ashlar);
	C_3DOBJECT_0(uint texture_id, TAshlar ashlar);
	C_3DOBJECT_0(const float x, const float y, const float z, const float width, const float height, const float size_z);
	C_3DOBJECT_0(uint texture_id, const float x, const float y, const float z, const float width, const float height, const float size_z);

public:
	void Set3d( bool b ) { _3d = b; }
	TAshlar GetPos() const { return _pos; }
	CVector3 GetPosV()
	{
		CVector3 ret(_pos.x, _pos.y, _pos.z);
		return ret;
	}
	void SetPos(TAshlar pos) {_pos = pos;}
	void SetPos(CVector3 pos)
	{
		_pos.x = pos.x;
		_pos.y = pos.y;
		_pos.z = pos.z;
	}
	void SetPos(const float x, const float y, const float z)
	{
		_pos.x = x;
		_pos.y = y;
		_pos.z = z;
	}
	void SetPos(const float x, const float y, const float z, const float width, const float height, const float size_z)
	{
		_pos.x = x;
		_pos.y = y;
		_pos.z = z;
		_pos.width = width;
		_pos.height = height;
		_pos.size_z = size_z;
	}
	void SetColor(TRGBf c) {_fColor = c;}
	void SetColorf(float r,float g,float b) {_fColor.r = r;_fColor.g = g;_fColor.b = b;}
	TRGBf GetColor() const {return _fColor;}

	void SetTextureId(unsigned int id) {_texture_id = id;}
	unsigned int GetTextureId() const {return _texture_id;}
	void SetBeginTag(uint tag) {_begin_tag = tag;}
	
	void SetBlend(bool b){_blend = b;}
	void SetAlpha(bool b){_alpha = b;}
	void SetNatazeni( int i ) {_natazeni = i;}
	virtual void Render();
};

#endif //_3DOBJECT_H_