Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7126 in orxonox.OLD for trunk/src/world_entities


Ignore:
Timestamp:
Feb 13, 2006, 1:14:53 PM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: the delete Mechanism of PNode seems to work again.
This is done by always deleting the first node, and not walking through a list, that is eleminated during deletion time

Location:
trunk/src/world_entities
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/environments/water.cc

    r7125 r7126  
    6363Water::~Water()
    6464{
    65   delete this->grid;
    6665}
    6766
  • trunk/src/world_entities/space_ships/turbine_hover.cc

    r7125 r7126  
    8080  Weapon* wpLeft = new TestGun(1);
    8181  wpLeft->setName("testGun Left");
    82   Weapon* cannon = dynamic_cast<Weapon*>(Factory::fabricate(CL_HYPERBLASTER));
    83 
    84   cannon->setName("BFG");
     82  //Weapon* cannon = dynamic_cast<Weapon*>(Factory::fabricate(CL_HYPERBLASTER));
     83
     84  //  cannon->setName("BFG");
    8585
    8686  this->addWeapon(wpLeft, 1, 0);
    8787  this->addWeapon(wpRight,1 ,1);
    88   this->addWeapon(cannon, 0, 2);
     88  //this->addWeapon(cannon, 0, 2);
    8989
    9090  this->getWeaponManager()->changeWeaponConfig(1);
  • trunk/src/world_entities/weapons/weapon.cc

    r7102 r7126  
    2929#include "state.h"
    3030#include "animation3d.h"
    31 #include "vector.h"
    3231
    3332#include "sound_source.h"
     
    8685  this->soundSource = new SoundSource(this);       //< Every Weapon has exacty one SoundSource.
    8786  this->emissionPoint.setParent(this);             //< One EmissionPoint, that is a PNode connected to the weapon. You can set this to the exitting point of the Projectiles
     87  this->emissionPoint.setName("EmissionPoint");
     88  this->emissionPoint.addNodeFlags(PNODE_PROHIBIT_DELETE_WITH_PARENT);
    8889
    8990  this->defaultTarget = NULL;                      //< Nothing is Targeted by default.
Note: See TracChangeset for help on using the changeset viewer.