Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9650 in orxonox.OLD for branches/proxy/src/world_entities


Ignore:
Timestamp:
Jul 31, 2006, 3:03:15 PM (18 years ago)
Author:
patrick
Message:

the network mode shoudl support kills again

Location:
branches/proxy/src/world_entities
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/proxy/src/world_entities/playable.cc

    r9625 r9650  
    6969
    7070  this->teamChangeHandler = registerVarId( new SynchronizeableInt( &this->teamId, &this->teamId, "team-id", PERMISSION_MASTER_SERVER ) );
     71
    7172  registerVar( new SynchronizeableInt( &score, &score, "score", PERMISSION_MASTER_SERVER ) );
    7273  registerVar( new SynchronizeableBool( &bFire, &bFire, "bFire", PERMISSION_OWNER));
     
    140141bool Playable::addWeapon(Weapon* weapon, int configID, int slotID)
    141142{
     143  weapon->setOwner(this->getOwner());
     144
     145
    142146  if(this->weaponMan.addWeapon(weapon, configID, slotID))
    143147  {
  • branches/proxy/src/world_entities/space_ships/turbine_hover.cc

    r9647 r9650  
    277277  printf("::::::::::::::::: TEAM ::: %d\n", teamID);
    278278  if (teamID == 0)
     279  {
    279280    this->setBoostColor(Color::blue);
     281  }
    280282  else if (teamID == 1)
     283  {
    281284    this->setBoostColor(Color::red);
    282 
     285  }
     286
     287  ///HACK this is very much hard coded.set the owner of the weapons
     288  this->getWeaponManager().getWeapon(0)->setOwner(/*SharedNetworkData::getInstance()->getHostID()*/ this->getOwner());
     289  this->getWeaponManager().getWeapon(1)->setOwner(/*SharedNetworkData::getInstance()->getHostID()*/this->getOwner());
    283290
    284291  //choose collision list
     
    290297      toList( OM_GROUP_01);
    291298  }
     299
    292300
    293301  // set the local team id, very important
  • branches/proxy/src/world_entities/weapons/laser_cannon.cc

    r9235 r9650  
    121121    return;
    122122
     123  // make this to let the onKill(...) fuction get the stuff
     124  pj->setOwner(this->getOwner());
     125
    123126  pj->setParent(PNode::getNullParent());
    124127
  • branches/proxy/src/world_entities/weapons/test_gun.cc

    r9002 r9650  
    177177  if (pj == NULL)
    178178    return;
     179
     180  // set the owner
     181  pj->setOwner(this->getOwner());
    179182
    180183  pj->setParent(PNode::getNullParent());
Note: See TracChangeset for help on using the changeset viewer.