Index: code/branches/presentation3/src/modules/pickup/PickupManager.cc
===================================================================
--- code/branches/presentation3/src/modules/pickup/PickupManager.cc	(revision 6965)
+++ code/branches/presentation3/src/modules/pickup/PickupManager.cc	(revision 6996)
@@ -39,4 +39,5 @@
 #include "core/ScopedSingletonManager.h"
 #include "core/Identifier.h"
+#include "util/Convert.h"
 #include "interfaces/PickupCarrier.h"
 #include "infos/PlayerInfo.h"
@@ -64,5 +65,4 @@
         
         this->defaultRepresentation_ = new PickupRepresentation();
-        this->pickupsIndex_ = 0;
         
         COUT(3) << "PickupManager created." << std::endl;
@@ -154,5 +154,4 @@
     {
         this->pickupsList_.clear();
-        this->pickupsIndex_ = 0;
         
         PlayerInfo* player = GUIManager::getInstance().getPlayer(PickupManager::guiName_s);
@@ -169,5 +168,5 @@
             for(std::set<Pickupable*>::iterator pickup = pickups.begin(); pickup != pickups.end(); pickup++)
             {
-                this->pickupsList_.insert(*pickup);
+                this->pickupsList_.insert(std::pair<Pickupable*, WeakPtr<Pickupable> >(*pickup, WeakPtr<Pickupable>(*pickup)));
             }
         }
@@ -199,14 +198,24 @@
     void PickupManager::dropPickup(orxonox::Pickupable* pickup)
     {
+        std::map<Pickupable*, WeakPtr<Pickupable> >::iterator it = this->pickupsList_.find(pickup);
+        if(pickup == NULL || it == this->pickupsList_.end() || it->second.get() == NULL)
+            return;
+
         if(!pickup->isPickedUp())
             return;
-        
+
         PickupCarrier* carrier = pickup->getCarrier();
         if(pickup != NULL && carrier != NULL)
+        {
             carrier->drop(pickup);
+        }
     }
 
     void PickupManager::usePickup(orxonox::Pickupable* pickup, bool use)
     {
+        std::map<Pickupable*, WeakPtr<Pickupable> >::iterator it = this->pickupsList_.find(pickup);
+        if(pickup == NULL || it == this->pickupsList_.end() || it->second.get() == NULL)
+            return;
+        
         if(!pickup->isPickedUp())
             return;
Index: code/branches/presentation3/src/modules/pickup/PickupManager.h
===================================================================
--- code/branches/presentation3/src/modules/pickup/PickupManager.h	(revision 6965)
+++ code/branches/presentation3/src/modules/pickup/PickupManager.h	(revision 6996)
@@ -39,4 +39,5 @@
 #include <map>
 #include "util/Singleton.h"
+#include "core/WeakPtr.h"
 #include "pickup/PickupIdentifier.h"
 #include "PickupRepresentation.h"
@@ -72,10 +73,10 @@
             // tolua_begin
             int getNumPickups(void);
-            orxonox::Pickupable* popPickup(void) { this->pickupsIndex_++; return *(this->pickupsIterator_++); }
-            int getPickupIndex(void) { return this->pickupsIndex_-1; }
+            orxonox::Pickupable* popPickup(void) { return (this->pickupsIterator_++)->first; }
             orxonox::PickupRepresentation* getPickupRepresentation(orxonox::Pickupable* pickup) { if(pickup != NULL) return this->getRepresentation(pickup->getPickupIdentifier()); return NULL; }
 
             void dropPickup(orxonox::Pickupable* pickup);
             void usePickup(orxonox::Pickupable* pickup, bool use);
+            bool isValidPickup(orxonox::Pickupable* pickup) { std::map<Pickupable*, WeakPtr<Pickupable> >::iterator it = this->pickupsList_.find(pickup); if(it == this->pickupsList_.end()) return false; return it->second.get() != NULL; }
             // tolua_end
             
@@ -87,7 +88,6 @@
             std::map<const PickupIdentifier*, PickupRepresentation*, PickupIdentifierCompare> representations_; //!< Map linking PickupIdentifiers (representing types if Pickupables) and PickupRepresentations.
 
-            std::set<Pickupable*> pickupsList_;
-            std::set<Pickupable*>::iterator pickupsIterator_;
-            int pickupsIndex_;
+            std::map<Pickupable*, WeakPtr<Pickupable> > pickupsList_;
+            std::map<Pickupable*, WeakPtr<Pickupable> >::iterator pickupsIterator_;
 
             std::vector<PickupCarrier*>* getAllCarriers(PickupCarrier* carrier);
