00001 /*************************************************************************** 00002 * Copyright (C) 2004 by Raphael Langerhorst * 00003 * raphael-langerhorst@gmx.at * 00004 * * 00005 * Permission is hereby granted, free of charge, to any person obtaining * 00006 * a copy of this software and associated documentation files (the * 00007 * "Software"), to deal in the Software without restriction, including * 00008 * without limitation the rights to use, copy, modify, merge, publish, * 00009 * distribute, sublicense, and/or sell copies of the Software, and to * 00010 * permit persons to whom the Software is furnished to do so, subject to * 00011 * the following conditions: * 00012 * * 00013 * The above copyright notice and this permission notice shall be * 00014 * included in all copies or substantial portions of the Software. * 00015 * * 00016 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * 00017 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * 00018 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.* 00019 * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR * 00020 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * 00021 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * 00022 * OTHER DEALINGS IN THE SOFTWARE. * 00023 ***************************************************************************/ 00024 00025 #ifndef GBEGREPARENTAGENTH 00026 #define GBEGREPARENTAGENTH 00027 00028 #include <GAgent.h> 00029 #include <GElementID.h> 00030 #include <GVector3.h> 00031 00032 #include <qobject.h> 00033 #include <qmap.h> 00034 00035 namespace GBE { 00036 00076 class GReparentAgent : public GCS::GAgent 00077 { 00078 Q_OBJECT 00079 00080 protected: 00081 00085 void performReparenting(const GCS::GElementID& new_parent, const GCS::GVector3& pos_add, const GCS::GVector3& rotate); 00086 00087 public: 00088 00092 GReparentAgent(QObject* parent = 0, const char* name = 0); 00093 00097 virtual ~GReparentAgent(); 00098 00099 public slots: 00100 00106 virtual void receiveInfluence(GCS::GElementInfluence& influence); 00107 00108 }; 00109 00110 }; 00111 00112 #endif
1.3.6