Changeset 3034
- Timestamp:
- May 23, 2009, 10:05:58 PM (16 years ago)
- Location:
- code/trunk/src/orxonox
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/orxonox/gui/GUIManager.cc
r3008 r3034 91 91 { 92 92 // destroy our own tolua interfaces 93 94 95 96 93 lua_pushnil(luaState_); 94 lua_setglobal(luaState_, "Orxonox"); 95 lua_pushnil(luaState_); 96 lua_setglobal(luaState_, "Core"); 97 97 delete scriptModule_; 98 98 } -
code/trunk/src/orxonox/objects/worldentities/pawns/Spectator.cc
r2896 r3034 112 112 void Spectator::changedFlareVisibility() 113 113 { 114 if ( this->greetingFlare_)114 if (this->greetingFlare_) 115 115 this->greetingFlare_->setVisible(this->bGreetingFlareVisible_); 116 116 } -
code/trunk/src/orxonox/objects/worldentities/triggers/DistanceTrigger.cc
r3033 r3034 86 86 { 87 87 Identifier* targetId = ClassByString(targets); 88 88 89 89 //! Checks whether the target is (or is derived from) a ControllableEntity. 90 90 Identifier* controllableEntityId = Class(ControllableEntity); … … 93 93 this->setForPlayer(true); 94 94 } 95 95 96 96 if (!targetId) 97 97 { … … 131 131 if (distanceVec.length() < this->distance_) 132 132 { 133 134 // !If the target is a player (resp. is a, or is derived from a, ControllableEntity) the triggeringPlayer is set to the target entity.133 134 // If the target is a player (resp. is a, or is derived from a, ControllableEntity) the triggeringPlayer is set to the target entity. 135 135 if(this->isForPlayer()) 136 136 { 137 137 Pawn* player = dynamic_cast<Pawn*>(entity); 138 139 140 138 this->setTriggeringPlayer(player); 139 } 140 141 141 return true; 142 142 } -
code/trunk/src/orxonox/overlays/OverlayGroup.cc
r2911 r3034 113 113 } 114 114 115 115 /** 116 116 @brief 117 117 Removes an element from the map. -
code/trunk/src/orxonox/overlays/notifications/Notification.h
r2911 r3034 56 56 Notification(const std::string & message); 57 57 virtual ~Notification(); 58 58 59 59 bool send(void); //!< Sends the Notification to the Notificationmanager, with sender NotificationManager::NONE; 60 60 bool send(const std::string & sender); //!< Sends the Notification to the Notificationmanager. 61 61 62 62 /** 63 63 @brief Checks whether the Notification was sent. … … 72 72 inline const std::string & getMessage(void) const 73 73 { return this->message_; } 74 74 75 75 inline const std::string & getSender(void) const 76 76 { return this->sender_; } 77 77 78 78 bool setMessage(const std::string & message); //!< Sets the message of the notification. 79 79 80 80 private: 81 81 std::string message_; //!< The Notification message. 82 82 std::string sender_; //!< The sender of the notification. 83 83 bool sent_; //!< Whether Notification has been sent, if so it cannot be changed. 84 84 85 85 void initialize(void); 86 86 87 87 }; 88 88 -
code/trunk/src/orxonox/overlays/notifications/NotificationManager.h
r2911 r3034 60 60 NotificationManager(); 61 61 virtual ~NotificationManager(); 62 62 63 63 static const std::string ALL; 64 64 static const std::string NONE; 65 65 66 66 static NotificationManager & getInstance(); //! Returns a reference to the single instance of the NotificationManager. 67 67 68 68 bool registerNotification(Notification* notification); //!< Registers a Notification within the NotificationManager. 69 69 bool registerQueue(NotificationQueue* queue); //!< Registers a NotificationQueue within the NotificationManager. 70 70 71 71 bool getNotifications(NotificationQueue* queue, std::multimap<std::time_t,Notification*>* map, const std::time_t & timeFrameStart, const std::time_t & timeFrameEnd); //!< Returns the Notifications for a specific NotificationQueue in a specified timeframe. 72 72 73 73 /** 74 74 @brief Fetches the Notifications for a specific NotificationQueue starting at a specified time. … … 89 89 bool getNotifications(NotificationQueue* queue, std::multimap<std::time_t,Notification*>* map, int timeDelay) 90 90 { return this->getNotifications(queue, map, std::time(0)-timeDelay, std::time(0)); } 91 91 92 92 private: 93 93 static NotificationManager* singletonRef_s; 94 94 95 95 int highestIndex_; //!< This variable holds the highest index (resp. key) in notificationLists_s, to secure that no key appears twice. 96 96 97 97 std::multimap<std::time_t,Notification*> allNotificationsList_; //!< Container where all notifications are stored (together with their respecive timestamps). 98 98 std::map<NotificationQueue*,int> queueList_; //!< Container where all NotificationQueues are stored with a number as identifier. 99 99 std::map<int,std::multimap<std::time_t,Notification*>*> notificationLists_; //!< Container where all Notifications, for each identifier (associated with a NotificationQueue), are stored. 100 100 101 101 102 102 };
Note: See TracChangeset
for help on using the changeset viewer.