Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 2, 2015, 11:32:08 PM (9 years ago)
Author:
landauf
Message:

made mapEntry const& wherever possible

Location:
code/branches/cpp11_v2/src
Files:
33 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/libraries/core/Language.cc

    r10916 r10917  
    107107    Language::~Language()
    108108    {
    109         for (auto& mapEntry : this->languageEntries_)
     109        for (const auto& mapEntry : this->languageEntries_)
    110110            delete (mapEntry.second);
    111111    }
  • code/branches/cpp11_v2/src/libraries/core/Loader.cc

    r10916 r10917  
    261261        {
    262262            bool expectedValue = true;
    263             for (auto& mapEntry : luaTags)
     263            for (const auto& mapEntry : luaTags)
    264264            {
    265265                if (mapEntry.second == expectedValue)
  • code/branches/cpp11_v2/src/libraries/core/NamespaceNode.cc

    r10916 r10917  
    103103                bool bFoundMatchingNamespace = false;
    104104
    105                 for (auto& mapEntry : this->subnodes_)
     105                for (const auto& mapEntry : this->subnodes_)
    106106                {
    107107                    if (mapEntry.first.find(firstPart) == (mapEntry.first.size() - firstPart.size()))
  • code/branches/cpp11_v2/src/libraries/core/class/Identifier.cc

    r10916 r10917  
    9292            const_cast<Identifier*>(directChild)->directParents_.remove(this);
    9393
    94         for (auto& mapEntry : this->configValues_)
     94        for (const auto& mapEntry : this->configValues_)
    9595            delete (mapEntry.second);
    96         for (auto& mapEntry : this->xmlportParamContainers_)
     96        for (const auto& mapEntry : this->xmlportParamContainers_)
    9797            delete (mapEntry.second);
    98         for (auto& mapEntry : this->xmlportObjectContainers_)
     98        for (const auto& mapEntry : this->xmlportObjectContainers_)
    9999            delete (mapEntry.second);
    100100    }
  • code/branches/cpp11_v2/src/libraries/core/input/InputManager.cc

    r10916 r10917  
    373373        // check whether a state has changed its EMPTY situation
    374374        bool bUpdateRequired = false;
    375         for (auto& mapEntry : activeStates_)
     375        for (const auto& mapEntry : activeStates_)
    376376        {
    377377            if (mapEntry.second->hasExpired())
  • code/branches/cpp11_v2/src/libraries/core/module/DynLibManager.cc

    r10916 r10917  
    7575    {
    7676        // Unload & delete resources in turn
    77         for (auto& mapEntry : mLibList)
     77        for (const auto& mapEntry : mLibList)
    7878        {
    7979            mapEntry.second->unload();
  • code/branches/cpp11_v2/src/libraries/core/module/ModuleInstance.cc

    r10916 r10917  
    7575        std::map<StaticInitialization::Type, std::set<StaticallyInitializedInstance*>> copy(this->staticallyInitializedInstancesByType_);
    7676        this->staticallyInitializedInstancesByType_.clear();
    77         for (auto& mapEntry : copy)
     77        for (const auto& mapEntry : copy)
    7878            for (std::set<StaticallyInitializedInstance*>::iterator it2 = mapEntry.second.begin(); it2 != mapEntry.second.end(); ++it2)
    7979                delete (*it2);
  • code/branches/cpp11_v2/src/libraries/core/module/PluginManager.cc

    r10916 r10917  
    5959        ModifyConsoleCommand("PluginManager", __CC_PluginManager_unload_name).setObject(nullptr);
    6060
    61         for (auto& mapEntry : this->references_)
     61        for (const auto& mapEntry : this->references_)
    6262            delete mapEntry.second;
    63         for (auto& mapEntry : this->plugins_)
     63        for (const auto& mapEntry : this->plugins_)
    6464            delete mapEntry.second;
    6565    }
  • code/branches/cpp11_v2/src/modules/gametypes/SpaceRaceController.cc

    r10916 r10917  
    161161
    162162        std::vector<RaceCheckPoint*> returnVec;
    163         for (auto& mapEntry : zaehler)
     163        for (const auto& mapEntry : zaehler)
    164164        {
    165165            if (mapEntry.second == maxWays)
  • code/branches/cpp11_v2/src/modules/gametypes/SpaceRaceManager.cc

    r10916 r10917  
    7777        }
    7878
    79         for (auto& mapEntry : players_)
     79        for (const auto& mapEntry : players_)
    8080        {
    8181
  • code/branches/cpp11_v2/src/modules/mini4dgame/Mini4Dgame.cc

    r10916 r10917  
    155155    {
    156156        // first spawn human players to assign always the left bat to the player in singleplayer
    157         for (auto& mapEntry : this->players_)
     157        for (const auto& mapEntry : this->players_)
    158158            if (mapEntry.first->isHumanPlayer() && (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_))
    159159                this->spawnPlayer(mapEntry.first);
    160160        // now spawn bots
    161         for (auto& mapEntry : this->players_)
     161        for (const auto& mapEntry : this->players_)
    162162            if (!mapEntry.first->isHumanPlayer() && (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_))
    163163                this->spawnPlayer(mapEntry.first);
  • code/branches/cpp11_v2/src/modules/notifications/NotificationManager.cc

    r10916 r10917  
    6969    {
    7070        // Destroys all Notifications.
    71         for(auto& mapEntry : this->allNotificationsList_)
     71        for(const auto& mapEntry : this->allNotificationsList_)
    7272            mapEntry.second->destroy();
    7373        this->allNotificationsList_.clear();
     
    152152        bool executed = false;
    153153        // Clear all NotificationQueues that have the input sender as target.
    154         for(auto& mapEntry : this->queues_) // Iterate through all NotificationQueues.
     154        for(const auto& mapEntry : this->queues_) // Iterate through all NotificationQueues.
    155155        {
    156156            const std::set<std::string>& set = mapEntry.second->getTargetsSet();
     
    187187
    188188        // Insert the Notification in all NotificationQueues that have its sender as target.
    189         for(auto& mapEntry : this->queues_) // Iterate through all NotificationQueues.
     189        for(const auto& mapEntry : this->queues_) // Iterate through all NotificationQueues.
    190190        {
    191191            const std::set<std::string>& set = mapEntry.second->getTargetsSet();
     
    345345
    346346        // Iterate through all Notifications to determine whether any of them should belong to the newly registered NotificationQueue.
    347         for(auto& mapEntry : this->allNotificationsList_)
     347        for(const auto& mapEntry : this->allNotificationsList_)
    348348        {
    349349            if(!bAll && set.find(mapEntry.second->getSender()) != set.end()) // Checks whether the listener has the sender of the current Notification as target.
  • code/branches/cpp11_v2/src/modules/notifications/NotificationQueue.cc

    r10916 r10917  
    206206        {
    207207            // Add all Notifications that have been created after this NotificationQueue was created.
    208             for(auto& mapEntry : *notifications)
     208            for(const auto& mapEntry : *notifications)
    209209            {
    210210                if(mapEntry.first >= this->creationTime_)
  • code/branches/cpp11_v2/src/modules/overlays/hud/HUDNavigation.cc

    r10916 r10917  
    131131        }
    132132        this->fontName_ = font;
    133         for (auto& mapEntry : this->activeObjectList_)
     133        for (const auto& mapEntry : this->activeObjectList_)
    134134        {
    135135            if (mapEntry.second.text_ != nullptr)
     
    151151        }
    152152        this->textSize_ = size;
    153         for (auto& mapEntry : this->activeObjectList_)
     153        for (const auto& mapEntry : this->activeObjectList_)
    154154        {
    155155            if (mapEntry.second.text_)
     
    531531        float yScale = this->getActualSize().y;
    532532
    533         for (auto& mapEntry : this->activeObjectList_)
     533        for (const auto& mapEntry : this->activeObjectList_)
    534534        {
    535535            if (mapEntry.second.health_ != nullptr)
  • code/branches/cpp11_v2/src/modules/overlays/hud/HUDRadar.cc

    r10916 r10917  
    9292            Ogre::OverlayManager::getSingleton().destroyOverlayElement(this->map3DBack_);
    9393
    94             for (auto& mapEntry : this->radarObjects_)
     94            for (const auto& mapEntry : this->radarObjects_)
    9595            {
    9696                Ogre::OverlayManager::getSingleton().destroyOverlayElement(mapEntry.second);
  • code/branches/cpp11_v2/src/modules/pickup/PickupManager.cc

    r10916 r10917  
    9191
    9292        // Destroying all the PickupInventoryContainers that are still there.
    93         for(auto& mapEntry : this->pickupInventoryContainers_)
     93        for(const auto& mapEntry : this->pickupInventoryContainers_)
    9494            delete mapEntry.second;
    9595        this->pickupInventoryContainers_.clear();
  • code/branches/cpp11_v2/src/modules/pong/Pong.cc

    r10916 r10917  
    211211    {
    212212        // first spawn human players to assign always the left bat to the player in singleplayer
    213         for (auto& mapEntry : this->players_)
     213        for (const auto& mapEntry : this->players_)
    214214            if (mapEntry.first->isHumanPlayer() && (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_))
    215215                this->spawnPlayer(mapEntry.first);
    216216        // now spawn bots
    217         for (auto& mapEntry : this->players_)
     217        for (const auto& mapEntry : this->players_)
    218218            if (!mapEntry.first->isHumanPlayer() && (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_))
    219219                this->spawnPlayer(mapEntry.first);
  • code/branches/cpp11_v2/src/modules/questsystem/QuestManager.cc

    r10916 r10917  
    235235    {
    236236        int numQuests = 0;
    237         for(auto& mapEntry : this->questMap_)
     237        for(const auto& mapEntry : this->questMap_)
    238238        {
    239239            if(mapEntry.second->getParentQuest() == nullptr && !mapEntry.second->isInactive(player))
     
    255255    Quest* QuestManager::getRootQuest(PlayerInfo* player, int index)
    256256    {
    257         for(auto& mapEntry : this->questMap_)
     257        for(const auto& mapEntry : this->questMap_)
    258258        {
    259259            if(mapEntry.second->getParentQuest() == nullptr && !mapEntry.second->isInactive(player) && index-- == 0)
  • code/branches/cpp11_v2/src/modules/tetris/Tetris.cc

    r10916 r10917  
    341341    {
    342342        // Spawn a human player.
    343         for (auto& mapEntry : this->players_)
     343        for (const auto& mapEntry : this->players_)
    344344            if (mapEntry.first->isHumanPlayer() && (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_))
    345345                this->spawnPlayer(mapEntry.first);
  • code/branches/cpp11_v2/src/orxonox/collisionshapes/CompoundCollisionShape.cc

    r10916 r10917  
    6565        {
    6666            // Delete all children
    67             for (auto& mapEntry : this->attachedShapes_)
     67            for (const auto& mapEntry : this->attachedShapes_)
    6868            {
    6969                // make sure that the child doesn't want to detach itself --> speedup because of the missing update
     
    266266        std::vector<CollisionShape*> shapes;
    267267        // Iterate through all attached CollisionShapes and add them to the list of shapes.
    268         for(auto& mapEntry : this->attachedShapes_)
     268        for(const auto& mapEntry : this->attachedShapes_)
    269269            shapes.push_back(mapEntry.first);
    270270
  • code/branches/cpp11_v2/src/orxonox/controllers/ArtificialController.cc

    r10916 r10917  
    231231    int ArtificialController::getFiremode(std::string name)
    232232    {
    233         for (auto& mapEntry : this->weaponModes_)
     233        for (const auto& mapEntry : this->weaponModes_)
    234234        {
    235235            if (mapEntry.first == name)
  • code/branches/cpp11_v2/src/orxonox/gametypes/Dynamicmatch.cc

    r10916 r10917  
    405405    void Dynamicmatch::rewardPig()
    406406    {
    407         for (auto& mapEntry : this->playerParty_) //durch alle Spieler iterieren und alle piggys finden
     407        for (const auto& mapEntry : this->playerParty_) //durch alle Spieler iterieren und alle piggys finden
    408408        {
    409409            if (mapEntry.second==piggy)//Spieler mit der Pig-party frags++
     
    441441            if (tutorial) // Announce selectionphase
    442442            {
    443              for (auto& mapEntry : this->playerParty_)
     443             for (const auto& mapEntry : this->playerParty_)
    444444                {
    445445                    if (!mapEntry.first)//in order to catch nullpointer
     
    456456             if(tutorial&&(!notEnoughKillers)&&(!notEnoughChasers)) //Selection phase over
    457457             {
    458                   for (auto& mapEntry : this->playerParty_)
     458                  for (const auto& mapEntry : this->playerParty_)
    459459                  {
    460460                       if (!mapEntry.first)//in order to catch nullpointer
     
    490490            if (tutorial) // Announce selectionphase
    491491            {
    492              for (auto& mapEntry : this->playerParty_)
     492             for (const auto& mapEntry : this->playerParty_)
    493493                {
    494494                    if (!mapEntry.first)//in order to catch nullpointer
     
    505505            if(tutorial&&(!notEnoughPigs)&&(!notEnoughChasers)) //Selection phase over
    506506             {
    507                   for (auto& mapEntry : this->playerParty_)
     507                  for (const auto& mapEntry : this->playerParty_)
    508508                  {
    509509                       if (!mapEntry.first)
     
    540540            if (tutorial) // Announce selectionphase
    541541            {
    542              for (auto& mapEntry : this->playerParty_)
     542             for (const auto& mapEntry : this->playerParty_)
    543543                {
    544544                    if (!mapEntry.first)//in order to catch nullpointer
     
    555555             if(tutorial&&(!notEnoughPigs)&&(!notEnoughKillers)) //Selection phase over
    556556             {
    557                   for (auto& mapEntry : this->playerParty_)
     557                  for (const auto& mapEntry : this->playerParty_)
    558558                  {
    559559                       if (!mapEntry.first)
     
    620620        else if(tutorial) // Announce selectionphase
    621621        {
    622             for (auto& mapEntry : this->playerParty_)
     622            for (const auto& mapEntry : this->playerParty_)
    623623            {
    624624                if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
  • code/branches/cpp11_v2/src/orxonox/gametypes/Gametype.cc

    r10916 r10917  
    139139        if (!this->gtinfo_->hasStarted())
    140140        {
    141             for (auto& mapEntry : this->players_)
     141            for (const auto& mapEntry : this->players_)
    142142            {
    143143                // Inform the GametypeInfo that the player is ready to spawn.
     
    169169        }
    170170
    171         for (auto& mapEntry : this->players_)
     171        for (const auto& mapEntry : this->players_)
    172172        {
    173173            if (mapEntry.first->getControllableEntity())
     
    404404                    bool allplayersready = true;
    405405                    bool hashumanplayers = false;
    406                     for (auto& mapEntry : this->players_)
     406                    for (const auto& mapEntry : this->players_)
    407407                    {
    408408                        if (!mapEntry.first->isReadyToSpawn())
     
    430430    void Gametype::spawnPlayersIfRequested()
    431431    {
    432         for (auto& mapEntry : this->players_)
     432        for (const auto& mapEntry : this->players_)
    433433        {
    434434            if (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_)
     
    439439    void Gametype::spawnDeadPlayersIfRequested()
    440440    {
    441         for (auto& mapEntry : this->players_)
     441        for (const auto& mapEntry : this->players_)
    442442            if (mapEntry.second.state_ == PlayerState::Dead)
    443443                if (mapEntry.first->isReadyToSpawn() || this->bForceSpawn_)
     
    538538    GSLevelMementoState* Gametype::exportMementoState()
    539539    {
    540         for (auto& mapEntry : this->players_)
     540        for (const auto& mapEntry : this->players_)
    541541        {
    542542            if (mapEntry.first->isHumanPlayer() && mapEntry.first->getControllableEntity() && mapEntry.first->getControllableEntity()->getCamera())
     
    587587
    588588        // find correct player and assign default entity with original position & orientation
    589         for (auto& mapEntry : this->players_)
     589        for (const auto& mapEntry : this->players_)
    590590        {
    591591            if (mapEntry.first->isHumanPlayer())
  • code/branches/cpp11_v2/src/orxonox/gametypes/LastManStanding.cc

    r10916 r10917  
    5656    void LastManStanding::spawnDeadPlayersIfRequested()
    5757    {
    58         for (auto& mapEntry : this->players_)
     58        for (const auto& mapEntry : this->players_)
    5959            if (mapEntry.second.state_ == PlayerState::Dead)
    6060            {
     
    114114    {
    115115        int min=lives;
    116         for (auto& mapEntry : this->playerLives_)
     116        for (const auto& mapEntry : this->playerLives_)
    117117        {
    118118            if (mapEntry.second<=0)
     
    128128        Gametype::end();
    129129
    130         for (auto& mapEntry : this->playerLives_)
     130        for (const auto& mapEntry : this->playerLives_)
    131131        {
    132132            if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
  • code/branches/cpp11_v2/src/orxonox/gametypes/LastTeamStanding.cc

    r10916 r10917  
    145145    void LastTeamStanding::spawnDeadPlayersIfRequested()
    146146    {
    147         for (auto& mapEntry : this->players_)
     147        for (const auto& mapEntry : this->players_)
    148148            if (mapEntry.second.state_ == PlayerState::Dead)
    149149            {
     
    229229        int party = -1;
    230230        //find a player who survived
    231         for (auto& mapEntry : this->playerLives_)
     231        for (const auto& mapEntry : this->playerLives_)
    232232        {
    233233          if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
     
    255255    {
    256256        int min = lives;
    257         for (auto& mapEntry : this->playerLives_)
     257        for (const auto& mapEntry : this->playerLives_)
    258258        {
    259259            if (mapEntry.second <= 0)
  • code/branches/cpp11_v2/src/orxonox/gametypes/TeamBaseMatch.cc

    r10916 r10917  
    187187            }
    188188
    189             for (auto& mapEntry : this->teamnumbers_)
     189            for (const auto& mapEntry : this->teamnumbers_)
    190190            {
    191191                if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
  • code/branches/cpp11_v2/src/orxonox/gametypes/TeamDeathmatch.cc

    r10916 r10917  
    6969        int winnerTeam = 0;
    7070        int highestScore = 0;
    71         for (auto& mapEntry : this->players_)
     71        for (const auto& mapEntry : this->players_)
    7272        {
    7373            if ( this->getTeamScore(mapEntry.first) > highestScore )
  • code/branches/cpp11_v2/src/orxonox/gametypes/TeamGametype.cc

    r10916 r10917  
    9999        std::vector<unsigned int> playersperteam(this->teams_, 0);
    100100
    101         for (auto& mapEntry : this->teamnumbers_)
     101        for (const auto& mapEntry : this->teamnumbers_)
    102102            if (mapEntry.second < static_cast<int>(this->teams_) && mapEntry.second >= 0)
    103103                playersperteam[mapEntry.second]++;
     
    141141    void TeamGametype::spawnDeadPlayersIfRequested()
    142142    {
    143         for (auto& mapEntry : this->players_)\
     143        for (const auto& mapEntry : this->players_)\
    144144        {
    145145            if(allowedInGame_[mapEntry.first] == false)//check if dead player is allowed to enter
     
    178178        if(!player || this->getTeam(player) == -1)
    179179            return 0;
    180         for (auto& mapEntry : this->players_)
     180        for (const auto& mapEntry : this->players_)
    181181        {
    182182            if ( this->getTeam(mapEntry.first) ==  this->getTeam(player) )
     
    191191    {
    192192        int teamSize = 0;
    193         for (auto& mapEntry : this->teamnumbers_)
     193        for (const auto& mapEntry : this->teamnumbers_)
    194194        {
    195195            if (mapEntry.second == team)
     
    202202    {
    203203        int teamSize = 0;
    204         for (auto& mapEntry : this->teamnumbers_)
     204        for (const auto& mapEntry : this->teamnumbers_)
    205205        {
    206206            if (mapEntry.second == team  && mapEntry.first->isHumanPlayer())
     
    376376    void TeamGametype::announceTeamWin(int winnerTeam)
    377377    {
    378         for (auto& mapEntry : this->teamnumbers_)
     378        for (const auto& mapEntry : this->teamnumbers_)
    379379        {
    380380            if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
  • code/branches/cpp11_v2/src/orxonox/gametypes/UnderAttack.cc

    r10916 r10917  
    7474        this->gameEnded_ = true;
    7575
    76         for (auto& mapEntry : this->teamnumbers_)
     76        for (const auto& mapEntry : this->teamnumbers_)
    7777        {
    7878            if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
     
    155155                ChatManager::message(message);
    156156
    157                 for (auto& mapEntry : this->teamnumbers_)
     157                for (const auto& mapEntry : this->teamnumbers_)
    158158                {
    159159                    if (mapEntry.first->getClientID() == NETWORK_PEER_ID_UNKNOWN)
  • code/branches/cpp11_v2/src/orxonox/weaponsystem/Munition.cc

    r10916 r10917  
    5555    Munition::~Munition()
    5656    {
    57         for (auto& mapEntry : this->currentMagazines_)
     57        for (const auto& mapEntry : this->currentMagazines_)
    5858            delete mapEntry.second;
    5959    }
     
    316316            {
    317317                bool change = false;
    318                 for (auto& mapEntry : this->currentMagazines_)
     318                for (const auto& mapEntry : this->currentMagazines_)
    319319                {
    320320                    // Add munition if the magazine isn't full (but only to loaded magazines)
  • code/branches/cpp11_v2/src/orxonox/weaponsystem/Weapon.cc

    r10916 r10917  
    6161                this->weaponPack_->removeWeapon(this);
    6262
    63             for (auto& mapEntry : this->weaponmodes_)
     63            for (const auto& mapEntry : this->weaponmodes_)
    6464                mapEntry.second->destroy();
    6565        }
     
    136136    void Weapon::reload()
    137137    {
    138         for (auto& mapEntry : this->weaponmodes_)
     138        for (const auto& mapEntry : this->weaponmodes_)
    139139            mapEntry.second->reload();
    140140    }
     
    148148    void Weapon::notifyWeaponModes()
    149149    {
    150         for (auto& mapEntry : this->weaponmodes_)
     150        for (const auto& mapEntry : this->weaponmodes_)
    151151            mapEntry.second->setWeapon(this);
    152152    }
  • code/branches/cpp11_v2/src/orxonox/weaponsystem/WeaponSet.cc

    r10916 r10917  
    6363    {
    6464        // Fire all WeaponPacks with their defined weaponmode
    65         for (auto& mapEntry : this->weaponpacks_)
     65        for (const auto& mapEntry : this->weaponpacks_)
    6666            if (mapEntry.second != WeaponSystem::WEAPON_MODE_UNASSIGNED)
    6767                mapEntry.first->fire(mapEntry.second);
     
    7171    {
    7272        // Reload all WeaponPacks with their defined weaponmode
    73         for (auto& mapEntry : this->weaponpacks_)
     73        for (const auto& mapEntry : this->weaponpacks_)
    7474            mapEntry.first->reload();
    7575    }
  • code/branches/cpp11_v2/src/orxonox/weaponsystem/WeaponSystem.cc

    r10916 r10917  
    196196
    197197        // Assign the desired weaponmode to the firemodes
    198         for (auto& mapEntry : this->weaponSets_)
     198        for (const auto& mapEntry : this->weaponSets_)
    199199        {
    200200            unsigned int weaponmode = wPack->getDesiredWeaponmode(mapEntry.first);
     
    219219
    220220        // Remove all added links from the WeaponSets
    221         for (auto& mapEntry : this->weaponSets_)
     221        for (const auto& mapEntry : this->weaponSets_)
    222222            mapEntry.second->removeWeaponmodeLink(wPack);
    223223
     
    268268        // Check if the WeaponSet belongs to this WeaponSystem
    269269        bool foundWeaponSet = false;
    270         for (auto& mapEntry : this->weaponSets_)
     270        for (const auto& mapEntry : this->weaponSets_)
    271271        {
    272272            if (mapEntry.second == wSet)
     
    296296    void WeaponSystem::reload()
    297297    {
    298         for (auto& mapEntry : this->weaponSets_)
     298        for (const auto& mapEntry : this->weaponSets_)
    299299            mapEntry.second->reload();
    300300    }
Note: See TracChangeset for help on using the changeset viewer.