Beispiel #1
0
 void modelChanged(const char* value)
 {
   m_modelKey = value;
   updateIsModel();
   if(isModel())
   {
     m_model.modelChanged(value);
   }
   else
   {
     m_model.modelChanged("");
   }
 }
Beispiel #2
0
void Doom3Group::modelChanged(const std::string& value) {
	m_modelKey = value;
	updateIsModel();
	if (isModel()) {
		m_model.modelChanged(value);
		m_nameOrigin = Vector3(0,0,0);
	}
	else {
		m_model.modelChanged("");
		m_nameOrigin = m_origin;
	}
	m_renderOrigin.updatePivot();
}
Beispiel #3
0
void Doom3Group::construct()
{
	_angleObserver.setCallback(std::bind(&RotationKey::angleChanged, &m_rotationKey, std::placeholders::_1));
	_rotationObserver.setCallback(std::bind(&RotationKey::rotationChanged, &m_rotationKey, std::placeholders::_1));
	_nameObserver.setCallback(std::bind(&Doom3Group::nameChanged, this, std::placeholders::_1));

	m_rotation.setIdentity();

	_owner.addKeyObserver("origin", m_originKey);
	_owner.addKeyObserver("angle", _angleObserver);
	_owner.addKeyObserver("rotation", _rotationObserver);
	_owner.addKeyObserver("name", _nameObserver);
	_owner.addKeyObserver(curve_Nurbs, m_curveNURBS);
	_owner.addKeyObserver(curve_CatmullRomSpline, m_curveCatmullRom);

	updateIsModel();
}
Beispiel #4
0
void Doom3Group::construct()
{
	_angleObserver.setCallback(boost::bind(&RotationKey::angleChanged, &m_rotationKey, _1));
	_rotationObserver.setCallback(boost::bind(&RotationKey::rotationChanged, &m_rotationKey, _1));
	_modelObserver.setCallback(boost::bind(&Doom3Group::modelChanged, this, _1));
	_nameObserver.setCallback(boost::bind(&Doom3Group::nameChanged, this, _1));

	m_rotation.setIdentity();

	m_isModel = false;

	_owner.addKeyObserver("model", _modelObserver);
	_owner.addKeyObserver("origin", m_originKey);
	_owner.addKeyObserver("angle", _angleObserver);
	_owner.addKeyObserver("rotation", _rotationObserver);
	_owner.addKeyObserver("name", _nameObserver);
	_owner.addKeyObserver(curve_Nurbs, m_curveNURBS);
	_owner.addKeyObserver(curve_CatmullRomSpline, m_curveCatmullRom);

	updateIsModel();
}
Beispiel #5
0
 void nameChanged(const char* value)
 {
   m_name = value;
   updateIsModel();
 }
Beispiel #6
0
void Doom3Group::nameChanged(const std::string& value) {
	m_name = value;
	updateIsModel();
	m_renderOrigin.updatePivot();
}