Ejemplo n.º 1
0
	void parseGroupList(GroupList &list, const editor::ParserGroup &group)
	{
		try
		{
			list.lightningEnabled = boost::lexical_cast<bool> (group.getValue("lightning_enabled"));
			list.lightningVariation = boost::lexical_cast<int> (group.getValue("lightning_variation"));
			list.lightningMin = boost::lexical_cast<int> (group.getValue("lightning_min"));
		}
		catch(...)
		{
			list.lightningEnabled = false;
		}

		parseGroup(list.group[0], group.getSubGroup("VeryLow"));
		parseGroup(list.group[1], group.getSubGroup("Low"));
		parseGroup(list.group[2], group.getSubGroup("Medium"));
		parseGroup(list.group[3], group.getSubGroup("High"));
		parseGroup(list.group[4], group.getSubGroup("VeryHigh"));
	}
Ejemplo n.º 2
0
void DragParticleForce::parseFrom(const editor::ParserGroup& pg) {
	m_factor = convertFromString<float>(pg.getValue("factor", ""), 0.0f);
}
Ejemplo n.º 3
0
void WindParticleForce::parseFrom(const editor::ParserGroup& pg) {
	m_wind_effect_factor = convertFromString<float>(pg.getValue("wind_effect_factor", ""), 0.0f);
	m_spiral_amount = convertFromString<float>(pg.getValue("spiral_amount", ""), 0.0f);
	m_spiral_speed = convertFromString<float>(pg.getValue("spiral_speed", ""), 0.0f);
}
Ejemplo n.º 4
0
void GravityPointParticleForce::parseFrom(const editor::ParserGroup& pg) {
	m_gravity = convertFromString<float>(pg.getValue("gravity", ""), 0.0f);
	m_point = convertVectorFromString(pg.getValue("point", "0,0,0"));
}
Ejemplo n.º 5
0
void SideGravityParticleForce::parseFrom(const editor::ParserGroup& pg) {
	m_sideGravity = convertFromString<float>(pg.getValue("sidegravity", ""), 0.0f);
}