Revision: 8059
          http://playerstage.svn.sourceforge.net/playerstage/?rev=8059&view=rev
Author:   hsujohnhsu
Date:     2009-07-21 01:21:08 +0000 (Tue, 21 Jul 2009)

Log Message:
-----------
allow joint attaching body to world.

Modified Paths:
--------------
    code/gazebo/trunk/server/physics/Joint.cc

Modified: code/gazebo/trunk/server/physics/Joint.cc
===================================================================
--- code/gazebo/trunk/server/physics/Joint.cc   2009-07-20 23:47:33 UTC (rev 
8058)
+++ code/gazebo/trunk/server/physics/Joint.cc   2009-07-21 01:21:08 UTC (rev 
8059)
@@ -109,10 +109,10 @@
   Body *body2 = this->model->GetBody(**(this->body2NameP));
   Body *anchorBody = this->model->GetBody(**(this->anchorBodyNameP));
 
-  if (!body1)
+  if (!body1 && this->body1NameP->GetValue() != std::string("world"))
     gzthrow("Couldn't Find Body[" + node->GetString("body1","",1));
 
-  if (!body2)
+  if (!body2 && this->body2NameP->GetValue() != std::string("world"))
     gzthrow("Couldn't Find Body[" + node->GetString("body2","",1));
 
   // setting anchor relative to gazebo body frame origin


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Playerstage-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/playerstage-commit

Reply via email to