Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

inputcontrol_c.cpp

Go to the documentation of this file.
00001 /* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*-
00002    this file is part of rcssserver3D
00003    Fri May 9 2003
00004    Copyright (C) 2003 Koblenz University
00005    $Id: inputcontrol_c.cpp,v 1.2 2004/12/22 16:02:13 rollmark Exp $
00006 
00007    This program is free software; you can redistribute it and/or modify
00008    it under the terms of the GNU General Public License as published by
00009    the Free Software Foundation; version 2 of the License.
00010 
00011    This program is distributed in the hope that it will be useful,
00012    but WITHOUT ANY WARRANTY; without even the implied warranty of
00013    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014    GNU General Public License for more details.
00015 
00016    You should have received a copy of the GNU General Public License
00017    along with this program; if not, write to the Free Software
00018    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00019 */
00020 #include "inputcontrol.h"
00021 
00022 using namespace kerosin;
00023 using namespace std;
00024 
00025 FUNCTION(InputControl, setAdvanceTime)
00026 {
00027     bool inAdvance;
00028 
00029     if (
00030         (in.GetSize() != 1) ||
00031         (! in.GetValue(in[0], inAdvance))
00032         )
00033         {
00034             return false;
00035         }
00036 
00037     obj->SetAdvanceTime(inAdvance);
00038     return true;
00039 }
00040 
00041 FUNCTION(InputControl, getAdvanceTime)
00042 {
00043     return obj->GetAdvanceTime();
00044 }
00045 
00046 
00047 FUNCTION(InputControl,setFPSController)
00048 {
00049     string inPath;
00050 
00051     if (
00052         (in.GetSize() != 1) ||
00053         (! in.GetValue(in[0], inPath))
00054         )
00055         {
00056             return false;
00057         }
00058 
00059     obj->SetFPSController(inPath);
00060 
00061     return true;
00062 }
00063 
00064 void CLASS(InputControl)::DefineClass()
00065 {
00066     DEFINE_BASECLASS(oxygen/SimControlNode);
00067     DEFINE_FUNCTION(setAdvanceTime);
00068     DEFINE_FUNCTION(getAdvanceTime);
00069     DEFINE_FUNCTION(setFPSController);
00070 }

Generated on Thu Apr 6 15:25:38 2006 for rcssserver3d by  doxygen 1.4.4