//------------------------------------------------------------------------------------
// irr::ITimer wrappers
//------------------------------------------------------------------------------------

extern "C" 
{

	u32 Irr_ITimer_getTime(ITimer* timer)
	{
		if (timer)
			return timer->getTime();
		else return 0;
	}

	u32 Irr_ITimer_getRealTime(ITimer* timer)
	{
		if (timer)
			return timer->getRealTime();
		else return 0;
	}
	
	void Irr_ITimer_setTime(ITimer* timer,u32 time)
	{
		if (timer)
			timer->setTime(time);
	}

	void Irr_ITimer_stop(ITimer* timer)
	{
		if (timer)
			timer->stop();
	}

	void Irr_ITimer_start(ITimer* timer)
	{
		if (timer)
			timer->start();
	}

	void Irr_ITimer_setSpeed(ITimer* timer,f32 speed = 1.0f)
	{
		if (timer)
			timer->setSpeed(speed);
	}

	f32 Irr_ITimer_getSpeed(ITimer* timer)
	{
		if (timer)
			return timer->getSpeed();
		else return 0.0f;
	}

	bool Irr_ITimer_isStopped(ITimer* timer)
	{
		if (timer)
			return timer->isStopped();
		else return false;
	}

	void Irr_ITimer_tick(ITimer* timer)
	{
		if (timer)
			timer->tick();
	}
	
	bool Irr_ITimer_drop(ITimer* unk)
	{
		if (unk)
			return unk->drop();
		else return 0;
	}
	
	const c8* Irr_ITimer_getDebugName(ITimer* unk)
	{
		if (unk)
			return unk->getDebugName();
		else return "";
	}
	
	void Irr_ITimer_grab(ITimer* unk)
	{
		if (unk)
			unk->grab();
	}	
}



