Changeset 7504 for code/trunk/src/orxonox/interfaces/Pickupable.cc
- Timestamp:
- Oct 6, 2010, 8:00:40 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/orxonox/interfaces/Pickupable.cc
r7494 r7504 34 34 #include "Pickupable.h" 35 35 36 #include "core/LuaState.h"37 #include "core/GUIManager.h"38 36 #include "core/Identifier.h" 39 37 #include "core/CoreIncludes.h" … … 45 43 46 44 #include "PickupCarrier.h" 45 #include "PickupListener.h" 47 46 48 47 namespace orxonox … … 130 129 131 130 this->used_ = used; 131 132 // Notify all the PickupListeners of the change. 133 PickupListener::broadcastPickupChangedUsed(this, used); 134 132 135 this->changedUsed(); 133 136 134 //TODO: Synchronize & make safe for dedicated server. 135 GUIManager::getInstance().getLuaState()->doString("PickupInventory.update()"); 137 136 138 return true; 137 139 } … … 222 224 return false; 223 225 } 224 226 225 227 this->setPickedUp(true); 226 228 COUT(4) << "Pickupable (&" << this << ") got picked up by a PickupCarrier (&" << carrier << ")." << std::endl; … … 277 279 278 280 this->pickedUp_ = pickedUp; 281 282 // Notify all the PickupListeners of the change. 283 PickupListener::broadcastPickupChangedPickedUp(this, pickedUp); 284 279 285 if(!pickedUp) // if the Pickupable has been dropped it unregisters itself with its PickupCarrier. 280 286 this->getCarrier()->removePickup(this); 281 287 this->changedPickedUp(); 282 288 283 //TODO: Synchronize & make safe for dedicated server.284 GUIManager::getInstance().getLuaState()->doString("PickupInventory.update()");285 289 return true; 286 290 }
Note: See TracChangeset
for help on using the changeset viewer.