00001 /*************************************************************************** 00002 * This file is part of OpenCAL: Open Computer Animation Library * 00003 * I created OpenCAL as my master's thesis Computer Science (multimedia) * 00004 * at the tUL university in Diepenbeek, Belgium * 00005 * * 00006 * Copyright (C) 2003-2004 by Jeroen Dierckx * 00007 * jeroen.dierckx@student.luc.ac.be * 00008 * * 00009 ***************************************************************************/ 00010 00011 // Includes 00012 #include "Linker.h" 00013 #include <OpenCAL/Object.h> 00014 using namespace OpenCAL; 00015 00016 using namespace std; 00017 00018 00019 /****************************** 00020 * Constructors and destructor * 00021 ******************************/ 00022 00023 Linker::Linker(System *parent, Object *object, const Object *link) 00024 : Agent(parent), m_object(object), m_link(link) 00025 { 00026 } 00027 00028 Linker::~Linker() 00029 { 00030 } 00031 00032 00033 /**************** 00034 * Satisfy agent * 00035 ****************/ 00036 00037 void Linker::satisfy() 00038 { 00039 //if(!m_enabled) return; 00040 Agent::satisfy(); 00041 00042 m_object->setPosition(m_link->getPosition()); 00043 }