better error reporting if XML file contains a wrong object shape, don't silently continue...
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@5466 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
f9f4346df9
commit
e7fbf9f73d
@ -54,6 +54,7 @@ PhysicalObject::PhysicalObject(const XMLNode &xml_node)
|
|||||||
if (shape=="cone" ) m_body_type = MP_CONE;
|
if (shape=="cone" ) m_body_type = MP_CONE;
|
||||||
else if(shape=="box" ) m_body_type = MP_BOX;
|
else if(shape=="box" ) m_body_type = MP_BOX;
|
||||||
else if(shape=="sphere" ) m_body_type = MP_SPHERE;
|
else if(shape=="sphere" ) m_body_type = MP_SPHERE;
|
||||||
|
else fprintf(stderr, "Unknown shape type : %s\n", shape.c_str());
|
||||||
|
|
||||||
m_init_pos.setIdentity();
|
m_init_pos.setIdentity();
|
||||||
m_init_pos.setOrigin(m_init_xyz);
|
m_init_pos.setOrigin(m_init_xyz);
|
||||||
|
Loading…
Reference in New Issue
Block a user