Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 1, 2011, 4:37:38 PM (13 years ago)
Author:
landauf
Message:

Replaced COUT() with orxout() in tools and orxonox library. Requires quite some fine-tuning.

Location:
code/branches/output/src/orxonox/gametypes
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • code/branches/output/src/orxonox/gametypes/Asteroids.cc

    r7655 r8809  
    7474
    7575        std::string message("The match has started! Reach the first chekpoint within 15 seconds! But be aware, there may be pirates around...");
    76         COUT(0) << message << std::endl;
     76        orxout(level::message) << message << endl;
    7777        Host::Broadcast(message);
    7878
     
    8484
    8585        std::string message("The match has ended.");
    86         COUT(0) << message << std::endl;
     86        orxout(level::message) << message << endl;
    8787        Host::Broadcast(message);
    8888    }
  • code/branches/output/src/orxonox/gametypes/Deathmatch.cc

    r6417 r8809  
    4848
    4949        std::string message("The match has started!");
    50         COUT(0) << message << std::endl;
     50        orxout(level::message) << message << endl;
    5151        Host::Broadcast(message);
    5252    }
     
    5757
    5858        std::string message("The match has ended.");
    59         COUT(0) << message << std::endl;
     59        orxout(level::message) << message << endl;
    6060        Host::Broadcast(message);
    6161    }
     
    6666
    6767        const std::string& message = player->getName() + " entered the game";
    68         COUT(0) << message << std::endl;
     68        orxout(level::message) << message << endl;
    6969        Host::Broadcast(message);
    7070    }
     
    7777        {
    7878            const std::string& message = player->getName() + " left the game";
    79             COUT(0) << message << std::endl;
     79            orxout(level::message) << message << endl;
    8080            Host::Broadcast(message);
    8181        }
     
    9191        {
    9292            const std::string& message = player->getOldName() + " changed name to " + player->getName();
    93             COUT(0) << message << std::endl;
     93            orxout(level::message) << message << endl;
    9494            Host::Broadcast(message);
    9595        }
     
    113113                message = victim->getPlayer()->getName() + " died";
    114114
    115             COUT(0) << message << std::endl;
     115            orxout(level::message) << message << endl;
    116116            Host::Broadcast(message);
    117117        }
     
    127127        {
    128128            const std::string& message = player->getName() + " scores!";
    129             COUT(0) << message << std::endl;
     129            orxout(level::message) << message << endl;
    130130            Host::Broadcast(message);
    131131        }
  • code/branches/output/src/orxonox/gametypes/Dynamicmatch.cc

    r8729 r8809  
    342342        numberOf[chaser]++;
    343343        Gametype::playerEntered(player);
    344         const std::string& message6 = player->getName() + " entered the game";
    345         COUT(0) << message6 << std::endl;
    346         Host::Broadcast(message6);
     344        const std::string& message = player->getName() + " entered the game";
     345        orxout(level::message) << message << endl;
     346        Host::Broadcast(message);
    347347    }
    348348
     
    359359            }
    360360            const std::string& message = player->getName() + " left the game";
    361             COUT(0) << message << std::endl;
     361            orxout(level::message) << message << endl;
    362362            Host::Broadcast(message);
    363363            //remove player from map
     
    617617        {
    618618            const std::string& message = player->getOldName() + " changed name to " + player->getName();
    619             COUT(0) << message << std::endl;
     619            orxout(level::message) << message << endl;
    620620            Host::Broadcast(message);
    621621        }
     
    630630        {
    631631            std::string message("Dynamicmatch started!");
    632             COUT(0) << message << std::endl;
     632            orxout(level::message) << message << endl;
    633633            Host::Broadcast(message);
    634634        }
     
    647647    {
    648648        std::string message("Earn points:\n\n\n\tIf you're red: Chase the blue player!\n\n\tIf you're blue shoot at a red player or hide.\n\n\tIf you're green: You've got the licence to kill red players!");
    649         COUT(0) << message << std::endl;
     649        orxout(level::message) << message << endl;
    650650        Host::Broadcast(message);
    651651        callInstructions_.setTimer(10, false, createExecutor(createFunctor(&Dynamicmatch::furtherInstructions, this)));
     
    655655    {
    656656        std::string message("After 3 Minutes the game is over.");
    657         COUT(0) << message << std::endl;
     657        orxout(level::message) << message << endl;
    658658        Host::Broadcast(message);
    659659    }*/
     
    663663
    664664        std::string message("Time out. Press F2 to see the points you scored.");
    665         COUT(0) << message << std::endl;
     665        orxout(level::message) << message << endl;
    666666        Host::Broadcast(message);
    667667    }
  • code/branches/output/src/orxonox/gametypes/Gametype.cc

    r8706 r8809  
    297297            }
    298298            else
    299                 COUT(2) << "Warning: Killed Pawn was not in the playerlist" << std::endl;
     299                orxout(internal_warning) << "Killed Pawn was not in the playerlist" << endl;
    300300        }
    301301    }
     
    344344            }
    345345
    346             COUT(2) << "Warning: Fallback SpawnPoint was used, because there were no active SpawnPoints." << endl;
     346            orxout(internal_warning) << "Fallback SpawnPoint was used because there were no active SpawnPoints." << endl;
    347347            return fallbackSpawnPoint;
    348348        }
     
    444444        else
    445445        {
    446             COUT(1) << "Error: No SpawnPoints in current Gametype" << std::endl;
     446            orxout(user_error) << "No SpawnPoints in current Gametype" << endl;
    447447            abort();
    448448        }
     
    461461        else
    462462        {
    463             COUT(1) << "Error: No SpawnPoints in current Gametype" << std::endl;
     463            orxout(user_error) << "No SpawnPoints in current Gametype" << endl;
    464464            abort();
    465465        }
  • code/branches/output/src/orxonox/gametypes/LastManStanding.cc

    r8327 r8809  
    105105            this->playersAlive--;
    106106            const std::string& message = victim->getPlayer()->getName() + " has lost all lives";
    107             COUT(0) << message << std::endl;
     107            orxout(level::message) << message << endl;
    108108            Host::Broadcast(message);
    109109        }
  • code/branches/output/src/orxonox/gametypes/LastTeamStanding.cc

    r8706 r8809  
    119119                this->teamsAlive--;
    120120            const std::string& message = victim->getPlayer()->getName() + " has lost all lives";
    121             COUT(0) << message << std::endl;
     121            orxout(level::message) << message << endl;
    122122            Host::Broadcast(message);
    123123        }
  • code/branches/output/src/orxonox/gametypes/TeamBaseMatch.cc

    r8327 r8809  
    141141            return;
    142142
    143         COUT(0) << "Points standing:" << std::endl << "Team 1: "<< pointsTeam1_ << std::endl << "Team 2: " << pointsTeam2_ << std::endl;
    144         if(pointsTeam1_ >=1700 && pointsTeam1_ < 2000) COUT(0) << "Team 1 is near victory!" << std::endl;
    145         if(pointsTeam2_ >=1700 && pointsTeam2_ < 2000) COUT(0) << "Team 2 is near victory!" << std::endl;
     143        orxout(message) << "Points standing:" << '\n' << "Team 1: "<< pointsTeam1_ << '\n' << "Team 2: " << pointsTeam2_ << endl;
     144        if(pointsTeam1_ >=1700 && pointsTeam1_ < 2000) orxout(message) << "Team 1 is near victory!" << endl;
     145        if(pointsTeam2_ >=1700 && pointsTeam2_ < 2000) orxout(message) << "Team 2 is near victory!" << endl;
    146146    }
    147147
     
    179179            if (this->pointsTeam1_ > this->pointsTeam2_)
    180180            {
    181                 COUT(0) << "Team 1 has won the match" << std::endl;
     181                orxout(message) << "Team 1 has won the match" << endl;
    182182                winningteam = 0;
    183183            }
    184184            else
    185185            {
    186                 COUT(0) << "Team 2 has won the match" << std::endl;
     186                orxout(message) << "Team 2 has won the match" << endl;
    187187                winningteam = 1;
    188188            }
  • code/branches/output/src/orxonox/gametypes/UnderAttack.cc

    r8327 r8809  
    7070        this->end(); //end gametype
    7171        std::string message("Ship destroyed! Team 0 has won!");
    72         COUT(0) << message << std::endl;
     72        orxout(level::message) << message << endl;
    7373        Host::Broadcast(message);
    7474        this->gameEnded_ = true;
     
    153153                this->end();
    154154                std::string message("Time is up! Team 1 has won!");
    155                 COUT(0) << message << std::endl;
     155                orxout(level::message) << message << endl;
    156156                Host::Broadcast(message);
    157157
     
    173173                const std::string& message = multi_cast<std::string>(timesequence_) + " seconds left!";
    174174/*
    175                 COUT(0) << message << std::endl;
     175                orxout(level::message) << message << endl;
    176176                Host::Broadcast(message);
    177177*/
Note: See TracChangeset for help on using the changeset viewer.