Changeset 7801 for code/trunk/src/modules/objects
- Timestamp:
- Dec 22, 2010, 7:24:24 PM (14 years ago)
- Location:
- code/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
-
code/trunk/src/modules/objects/ForceField.cc
r7677 r7801 60 60 this->setLength(2000); 61 61 this->mode_ = forceFieldMode::tube; 62 63 this->registerVariables(); 62 64 } 63 65 … … 83 85 XMLPortParam(ForceField, "mode", setMode, getMode, xmlelement, mode); 84 86 } 87 88 void ForceField::registerVariables() 89 { 90 registerVariable(this->velocity_, VariableDirection::ToClient); 91 registerVariable(this->radius_, VariableDirection::ToClient); 92 registerVariable(this->halfLength_, VariableDirection::ToClient); 93 registerVariable(this->mode_, VariableDirection::ToClient); 94 } 95 85 96 86 97 /** -
code/trunk/src/modules/objects/ForceField.h
r7678 r7801 88 88 89 89 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); //!< Creates a ForceField object through XML. 90 void registerVariables(); //!< Registers the variables that should get synchronised over the network 90 91 virtual void tick(float dt); //!< A method that is called every tick. 92 91 93 92 94 /** … … 141 143 float radius_; //!< The radius of the ForceField. 142 144 float halfLength_; //!< Half of the length of the ForceField. 143 forceFieldMode::Valuemode_; //!< The mode of the ForceField.145 int mode_; //!< The mode of the ForceField. 144 146 }; 145 147 }
Note: See TracChangeset
for help on using the changeset viewer.