irr_core_vector3df* scale,
int alsoAddIfMeshPointerZero)
{
- const irr::core::vector3df& iPosition = irr::core::vector3df(position->x,
- position->y,
- position->z);
- const irr::core::vector3df& iRotation = irr::core::vector3df(rotation->x,
- rotation->y,
- rotation->z);
- const irr::core::vector3df& iScale = irr::core::vector3df(scale->x,
- scale->y,
- scale->z);
+ const irr::core::vector3df iPosition =
+ position ?
+ irr::core::vector3df(position->x, position->y, position->z) :
+ irr::core::vector3df(0, 0, 0);
+
+ const irr::core::vector3df iRotation =
+ rotation ?
+ irr::core::vector3df(rotation->x, rotation->y, rotation->z) :
+ irr::core::vector3df(0, 0, 0);
+
+ const irr::core::vector3df& iScale =
+ scale ?
+ irr::core::vector3df(scale->x, scale->y, scale->z) :
+ irr::core::vector3df(1, 1, 1);
+
return (irr_scene_IAnimatedMeshSceneNode*)
((irr::scene::ISceneManager*)smgr)->addAnimatedMeshSceneNode((irr::scene::IAnimatedMesh*)mesh,
(irr::scene::ISceneNode*)parent,
int id,
int makeActive)
{
- const irr::core::vector3df& iPosition = irr::core::vector3df(position->x,
- position->y,
- position->z);
- const irr::core::vector3df& iLookat = irr::core::vector3df(lookat->x,
- lookat->y,
- lookat->z);
+ const irr::core::vector3df& iPosition =
+ position ?
+ irr::core::vector3df(position->x, position->y, position->z) :
+ irr::core::vector3df(0, 0, 0);
+
+ const irr::core::vector3df& iLookat =
+ lookat ?
+ irr::core::vector3df(lookat->x, lookat->y, lookat->z) :
+ irr::core::vector3df(0, 0, 100);
+
return (irr_scene_ICameraSceneNode*)
((irr::scene::ISceneManager*)smgr)->addCameraSceneNode((irr::scene::ISceneNode*)parent,
iPosition,