| 255 | //} |
| 256 | |
| 257 | void NetObject::setScopeAlways() |
| 258 | { |
| 259 | if(mNetFlags.test(Ghostable) && !mNetFlags.test(IsGhost)) |
| 260 | { |
| 261 | mNetFlags.set(ScopeAlways); |
| 262 | |
| 263 | // if it's a ghost always object, add it to the ghost always set |
| 264 | // for ClientReps created later. |
| 265 | |
| 266 | Sim::getGhostAlwaysSet()->addObject(this); |
| 267 | |
| 268 | // add it to all Connections that already exist. |
| 269 | |
| 270 | SimGroup *clientGroup = Sim::getClientGroup(); |
| 271 | SimGroup::iterator i; |
| 272 | for(i = clientGroup->begin(); i != clientGroup->end(); i++) |
| 273 | { |
| 274 | NetConnection *con = (NetConnection *) (*i); |
| 275 | if(con->isGhosting()) |
| 276 | con->objectInScope(this); |
| 277 | } |
| 278 | } |
| 279 | } |
| 280 | |
| 281 | void NetObject::clearScopeAlways() |
| 282 | { |
no test coverage detected