Changeset 9629 for code/branches/core6/src/modules/pickup
- Timestamp:
- Aug 9, 2013, 9:26:46 PM (11 years ago)
- Location:
- code/branches/core6/src/modules/pickup
- Files:
-
- 24 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core6/src/modules/pickup/Pickup.cc
r9348 r9629 56 56 The objects creator. 57 57 */ 58 Pickup::Pickup( BaseObject* creator) : BaseObject(creator)58 Pickup::Pickup(Context* context) : BaseObject(context) 59 59 { 60 60 RegisterObject(Pickup); … … 187 187 bool Pickup::createSpawner(void) 188 188 { 189 PickupSpawner::createDroppedPickup(this , this, this->getCarrier());189 PickupSpawner::createDroppedPickup(this->getContext(), this, this->getCarrier()); 190 190 return true; 191 191 } -
code/branches/core6/src/modules/pickup/Pickup.h
r9348 r9629 100 100 101 101 public: 102 Pickup( BaseObject* creator); //!< Constructor.102 Pickup(Context* context); //!< Constructor. 103 103 virtual ~Pickup(); //!< Destructor. 104 104 -
code/branches/core6/src/modules/pickup/PickupCollection.cc
r9348 r9629 53 53 The creator of the object. 54 54 */ 55 PickupCollection::PickupCollection( BaseObject* creator) : BaseObject(creator)55 PickupCollection::PickupCollection(Context* context) : BaseObject(context) 56 56 { 57 57 RegisterObject(PickupCollection); … … 328 328 bool PickupCollection::createSpawner(void) 329 329 { 330 PickupSpawner::createDroppedPickup(this , this, this->getCarrier());330 PickupSpawner::createDroppedPickup(this->getContext(), this, this->getCarrier()); 331 331 return true; 332 332 } -
code/branches/core6/src/modules/pickup/PickupCollection.h
r9348 r9629 70 70 71 71 public: 72 PickupCollection( BaseObject* creator); //!< Default Constructor.72 PickupCollection(Context* context); //!< Default Constructor. 73 73 virtual ~PickupCollection(); //!< Destructor. 74 74 -
code/branches/core6/src/modules/pickup/PickupRepresentation.cc
r9348 r9629 64 64 Default Constructor. Registers the object and initializes its member variables. 65 65 */ 66 PickupRepresentation::PickupRepresentation( BaseObject* creator) : BaseObject(creator), Synchronisable(creator), spawnerRepresentation_(NULL)66 PickupRepresentation::PickupRepresentation(Context* context) : BaseObject(context), Synchronisable(context), spawnerRepresentation_(NULL) 67 67 { 68 68 RegisterObject(PickupRepresentation); … … 180 180 StaticEntity* PickupRepresentation::getDefaultSpawnerRepresentation(PickupSpawner* spawner) 181 181 { 182 StaticEntity* representation = new StaticEntity(spawner );183 Billboard* sphere = new Billboard(spawner );182 StaticEntity* representation = new StaticEntity(spawner->getContext()); 183 Billboard* sphere = new Billboard(spawner->getContext()); 184 184 sphere->setColour(ColourValue(0.95f, 0.85f, 0.27f)); 185 185 sphere->setMaterial("Sphere2"); 186 186 sphere->setScale(0.1f); 187 Billboard* icon = new Billboard(spawner );187 Billboard* icon = new Billboard(spawner->getContext()); 188 188 icon->setColour(ColourValue(0.89f, 0.79f, 0.08f)); 189 189 icon->setMaterial("asterisk"); -
code/branches/core6/src/modules/pickup/PickupRepresentation.h
r9348 r9629 95 95 public: 96 96 PickupRepresentation(); //!< Constructor 97 PickupRepresentation( BaseObject* creator); //!< Default constructor.97 PickupRepresentation(Context* context); //!< Default constructor. 98 98 virtual ~PickupRepresentation(); //!< Destructor. 99 99 -
code/branches/core6/src/modules/pickup/PickupSpawner.cc
r9348 r9629 55 55 Pointer to the object which created this item. 56 56 */ 57 PickupSpawner::PickupSpawner( BaseObject* creator) : StaticEntity(creator), pickup_(NULL), representation_(NULL), pickupTemplate_(NULL)57 PickupSpawner::PickupSpawner(Context* context) : StaticEntity(context), pickup_(NULL), representation_(NULL), pickupTemplate_(NULL) 58 58 { 59 59 RegisterObject(PickupSpawner); … … 99 99 The distance at which the PickupSpawner will trigger. 100 100 */ 101 /*static*/ PickupSpawner* PickupSpawner::createDroppedPickup( BaseObject* creator, Pickupable* pickup, PickupCarrier* carrier, float triggerDistance)102 { 103 PickupSpawner* spawner = new PickupSpawner(c reator);101 /*static*/ PickupSpawner* PickupSpawner::createDroppedPickup(Context* context, Pickupable* pickup, PickupCarrier* carrier, float triggerDistance) 102 { 103 PickupSpawner* spawner = new PickupSpawner(context); 104 104 105 105 spawner->setPickupable(pickup); … … 289 289 if (identifier != NULL) 290 290 { 291 Pickupable* pickup = orxonox_cast<Pickupable*>(identifier->fabricate(this ));291 Pickupable* pickup = orxonox_cast<Pickupable*>(identifier->fabricate(this->getContext())); 292 292 orxonox_cast<BaseObject*>(pickup)->addTemplate(this->pickupTemplate_); 293 293 return pickup; -
code/branches/core6/src/modules/pickup/PickupSpawner.h
r9348 r9629 77 77 { 78 78 public: 79 PickupSpawner( BaseObject* creator); //!< Default Constructor.79 PickupSpawner(Context* context); //!< Default Constructor. 80 80 virtual ~PickupSpawner(); //!< Destructor. 81 81 82 static PickupSpawner* createDroppedPickup( BaseObject* creator, Pickupable* pickup, PickupCarrier* carrier, float triggerDistance = 10.0);82 static PickupSpawner* createDroppedPickup(Context* context, Pickupable* pickup, PickupCarrier* carrier, float triggerDistance = 10.0); 83 83 84 84 virtual void XMLPort(Element& xmlelement, XMLPort::Mode mode); //!< Method for creating a PickupSpawner through XML. -
code/branches/core6/src/modules/pickup/items/DamageBoostPickup.cc
r9348 r9629 48 48 Constructor. Registers the object and initializes the member variables. 49 49 */ 50 DamageBoostPickup::DamageBoostPickup( BaseObject* creator) : Pickup(creator)50 DamageBoostPickup::DamageBoostPickup(Context* context) : Pickup(context) 51 51 { 52 52 RegisterObject(DamageBoostPickup); -
code/branches/core6/src/modules/pickup/items/DamageBoostPickup.h
r9348 r9629 49 49 public: 50 50 51 DamageBoostPickup( BaseObject* creator); //!< Constructor.51 DamageBoostPickup(Context* context); //!< Constructor. 52 52 virtual ~DamageBoostPickup(); //!< Destructor. 53 53 -
code/branches/core6/src/modules/pickup/items/DronePickup.cc
r9348 r9629 51 51 Constructor. Registers the object and initializes the member variables. 52 52 */ 53 DronePickup::DronePickup( BaseObject* creator) : Pickup(creator)53 DronePickup::DronePickup(Context* context) : Pickup(context) 54 54 { 55 55 RegisterObject(DronePickup); … … 126 126 127 127 //Attach to pawn 128 Drone* drone = new Drone(pawn->getC reator()); // this is neccessary because the projectiles fired need a valid creator for the particlespawner (when colliding against something)128 Drone* drone = new Drone(pawn->getContext()); // this is neccessary because the projectiles fired need a valid creator for the particlespawner (when colliding against something) 129 129 drone->addTemplate(this->getDroneTemplate()); 130 130 -
code/branches/core6/src/modules/pickup/items/DronePickup.h
r9348 r9629 64 64 public: 65 65 66 DronePickup( BaseObject* creator); //!< Constructor.66 DronePickup(Context* context); //!< Constructor. 67 67 virtual ~DronePickup(); //!< Destructor. 68 68 -
code/branches/core6/src/modules/pickup/items/HealthPickup.cc
r9348 r9629 53 53 Constructor. Registers the object and initializes the member variables. 54 54 */ 55 HealthPickup::HealthPickup( BaseObject* creator) : Pickup(creator)55 HealthPickup::HealthPickup(Context* context) : Pickup(context) 56 56 { 57 57 RegisterObject(HealthPickup); -
code/branches/core6/src/modules/pickup/items/HealthPickup.h
r9348 r9629 90 90 public: 91 91 92 HealthPickup( BaseObject* creator); //!< Constructor.92 HealthPickup(Context* context); //!< Constructor. 93 93 virtual ~HealthPickup(); //!< Destructor. 94 94 -
code/branches/core6/src/modules/pickup/items/InvisiblePickup.cc
r9348 r9629 51 51 Constructor. Registers the object and initializes the member variables. 52 52 */ 53 InvisiblePickup::InvisiblePickup( BaseObject* creator) : Pickup(creator)53 InvisiblePickup::InvisiblePickup(Context* context) : Pickup(context) 54 54 { 55 55 RegisterObject(InvisiblePickup); -
code/branches/core6/src/modules/pickup/items/InvisiblePickup.h
r9348 r9629 70 70 public: 71 71 72 InvisiblePickup( BaseObject* creator); //!< Constructor.72 InvisiblePickup(Context* context); //!< Constructor. 73 73 virtual ~InvisiblePickup(); //!< Destructor. 74 74 -
code/branches/core6/src/modules/pickup/items/MetaPickup.cc
r9348 r9629 55 55 Constructor. Registers and initializes the object. 56 56 */ 57 MetaPickup::MetaPickup( BaseObject* creator) : Pickup(creator)57 MetaPickup::MetaPickup(Context* context) : Pickup(context) 58 58 { 59 59 RegisterObject(MetaPickup); -
code/branches/core6/src/modules/pickup/items/MetaPickup.h
r9348 r9629 89 89 90 90 public: 91 MetaPickup( BaseObject* creator); //!< Constructor. Registers and initializes the object.91 MetaPickup(Context* context); //!< Constructor. Registers and initializes the object. 92 92 virtual ~MetaPickup(); //!< Destructor. 93 93 -
code/branches/core6/src/modules/pickup/items/ShieldPickup.cc
r9348 r9629 48 48 Constructor. Registers the object and initializes the member variables. 49 49 */ 50 ShieldPickup::ShieldPickup( BaseObject* creator) : Pickup(creator)50 ShieldPickup::ShieldPickup(Context* context) : Pickup(context) 51 51 { 52 52 RegisterObject(ShieldPickup); -
code/branches/core6/src/modules/pickup/items/ShieldPickup.h
r9348 r9629 76 76 public: 77 77 78 ShieldPickup( BaseObject* creator); //!< Constructor.78 ShieldPickup(Context* context); //!< Constructor. 79 79 virtual ~ShieldPickup(); //!< Destructor. 80 80 -
code/branches/core6/src/modules/pickup/items/ShrinkPickup.cc
r9348 r9629 52 52 Constructor: Initializes the Pickup. 53 53 */ 54 ShrinkPickup::ShrinkPickup( BaseObject* creator) : Pickup(creator)54 ShrinkPickup::ShrinkPickup(Context* context) : Pickup(context) 55 55 { 56 56 RegisterObject(ShrinkPickup); -
code/branches/core6/src/modules/pickup/items/ShrinkPickup.h
r9348 r9629 72 72 { 73 73 public: 74 ShrinkPickup( BaseObject* creator); // Constructor.74 ShrinkPickup(Context* context); // Constructor. 75 75 virtual ~ShrinkPickup(); // Destructor. 76 76 -
code/branches/core6/src/modules/pickup/items/SpeedPickup.cc
r9348 r9629 48 48 Constructor. Registers the object and initializes the member variables. 49 49 */ 50 SpeedPickup::SpeedPickup( BaseObject* creator) : Pickup(creator)50 SpeedPickup::SpeedPickup(Context* context) : Pickup(context) 51 51 { 52 52 RegisterObject(SpeedPickup); -
code/branches/core6/src/modules/pickup/items/SpeedPickup.h
r9348 r9629 75 75 public: 76 76 77 SpeedPickup( BaseObject* creator); //!< Constructor.77 SpeedPickup(Context* context); //!< Constructor. 78 78 virtual ~SpeedPickup(); //!< Destructor. 79 79
Note: See TracChangeset
for help on using the changeset viewer.