- Timestamp:
- Dec 30, 2015, 1:59:38 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/cpp11_v2/src/modules/objects/triggers/DistanceTrigger.cc
r10916 r10998 158 158 ClassTreeMask targetMask = this->targetMask_; 159 159 // If we are in identify-mode another target mask has to be applies to find the DistanceTriggerBeacons. 160 if(this->beaconMode_ == distanceTriggerBeaconMode::identify)160 if(this->beaconMode_ == DistanceTriggerBeaconMode::identify) 161 161 targetMask = this->beaconMask_; 162 162 … … 167 167 168 168 // If the DistanceTrigger is in identify-mode and the DistanceTriggerBeacon attached to the object has the wrong name we ignore it. 169 if(this->beaconMode_ == distanceTriggerBeaconMode::identify)169 if(this->beaconMode_ == DistanceTriggerBeaconMode::identify) 170 170 { 171 171 if(entity->getName() != this->targetName_) … … 177 177 178 178 // If the DistanceTrigger is in exclude mode and the DistanceTriggerBeacon attached to the object has the right name, we ignore it. 179 if(this->beaconMode_ == distanceTriggerBeaconMode::exclude)179 if(this->beaconMode_ == DistanceTriggerBeaconMode::exclude) 180 180 { 181 181 … … 202 202 { 203 203 // Change the entity to the parent of the DistanceTriggerBeacon (if in identify-mode), which is the entity to which the beacon is attached. 204 if(this->beaconMode_ == distanceTriggerBeaconMode::identify)204 if(this->beaconMode_ == DistanceTriggerBeaconMode::identify) 205 205 entity = entity->getParent(); 206 206 … … 228 228 The mode as an enum. 229 229 */ 230 void DistanceTrigger::setBeaconModeDirect( distanceTriggerBeaconMode::Value mode)230 void DistanceTrigger::setBeaconModeDirect(DistanceTriggerBeaconMode mode) 231 231 { 232 232 this->beaconMode_ = mode; … … 243 243 switch(this->getBeaconModeDirect()) 244 244 { 245 case distanceTriggerBeaconMode::off :245 case DistanceTriggerBeaconMode::off : 246 246 return DistanceTrigger::beaconModeOff_s; 247 case distanceTriggerBeaconMode::identify:247 case DistanceTriggerBeaconMode::identify: 248 248 return DistanceTrigger::beaconModeIdentify_s; 249 case distanceTriggerBeaconMode::exclude:249 case DistanceTriggerBeaconMode::exclude: 250 250 return DistanceTrigger::beaconModeExlcude_s; 251 251 default : … … 264 264 { 265 265 if(mode == DistanceTrigger::beaconModeOff_s) 266 this->setBeaconModeDirect( distanceTriggerBeaconMode::off);266 this->setBeaconModeDirect(DistanceTriggerBeaconMode::off); 267 267 else if(mode == DistanceTrigger::beaconModeIdentify_s) 268 this->setBeaconModeDirect( distanceTriggerBeaconMode::identify);268 this->setBeaconModeDirect(DistanceTriggerBeaconMode::identify); 269 269 else if(mode == DistanceTrigger::beaconModeExlcude_s) 270 this->setBeaconModeDirect( distanceTriggerBeaconMode::exclude);270 this->setBeaconModeDirect(DistanceTriggerBeaconMode::exclude); 271 271 else 272 272 orxout(internal_error, context::triggers) << "Invalid beacon mode in DistanceTrigger." << endl; … … 282 282 Returns true if it is triggered ,false if not. 283 283 */ 284 bool DistanceTrigger::isTriggered(TriggerMode ::Valuemode)284 bool DistanceTrigger::isTriggered(TriggerMode mode) 285 285 { 286 286 if (Trigger::isTriggered(mode))
Note: See TracChangeset
for help on using the changeset viewer.