#include <TankScore.h>
Definition at line 31 of file TankScore.h.
| TankScore::TankScore | ( | ScorchedContext & | context | ) |
| TankScore::~TankScore | ( | ) | [virtual] |
Definition at line 42 of file TankScore.cpp.
| void TankScore::setTank | ( | Tank * | tank | ) | [inline] |
| void TankScore::newMatch | ( | ) |
Definition at line 54 of file TankScore.cpp.
References assists_, context_, ScorchedContext::getOptionsGame(), kills_, missedMoves_, money_, newGame(), resetTotalEarnedStats(), score_, setMoney(), turnKills_, and wins_.
Referenced by Tank::newMatch(), and TankScore().
| void TankScore::newGame | ( | ) |
Definition at line 68 of file TankScore.cpp.
References hurtBy_, and wonGame_.
Referenced by clientNewGame(), Tank::newGame(), and newMatch().
| void TankScore::clientNewGame | ( | ) |
Definition at line 74 of file TankScore.cpp.
References newGame().
Referenced by Tank::clientNewGame().
| int TankScore::getKills | ( | ) | [inline] |
Definition at line 43 of file TankScore.h.
References kills_.
Referenced by ScoreDialog::addLine(), TankDamage::calculateDamage(), and getScoreString().
| void TankScore::setKills | ( | int | kills | ) | [inline] |
Definition at line 44 of file TankScore.h.
References kills_.
Referenced by TankDamage::calculateDamage().
| int TankScore::getAssists | ( | ) | [inline] |
Definition at line 46 of file TankScore.h.
References assists_.
Referenced by ScoreDialog::addLine(), TankDamage::calculateDamage(), getScoreString(), and TankResign::simulate().
| void TankScore::setAssists | ( | int | assists | ) | [inline] |
Definition at line 47 of file TankScore.h.
References assists_.
Referenced by TankDamage::calculateDamage(), and TankResign::simulate().
| int TankScore::getMoney | ( | ) | [inline] |
Definition at line 49 of file TankScore.h.
References money_.
Referenced by BuyAccessoryDialog::addAccessory(), ScoreDialog::addLine(), InventoryDialog::addPlayerName(), BuyAccessoryDialog::addPlayerName(), BuyAccessoryDialog::buttonDown(), TankAIWeaponSets::WeaponSet::buyWeapons(), TankDamage::calculateDamage(), ScoreDialog::calculateScores(), GiftMoneyDialog::display(), AutoDefenseDialog::displayCurrent(), ScoreDialog::draw(), getScoreString(), ServerGiftMoneyHandler::processMessage(), ServerBuyAccessoryHandler::processMessage(), ClientGiftMoneyHandler::processMessage(), ServerShotFinishedState::scoreWinners(), TankResign::simulate(), WeaponGiveMoney::weaponCallback(), WeaponGiveAccessory::weaponCallback(), and TankAIWeaponSets::WeaponSetEntry::weaponValid().
| void TankScore::setMoney | ( | int | money | ) |
Definition at line 79 of file TankScore.cpp.
References maxMoney, money_, and totalMoneyEarned_.
Referenced by BuyAccessoryDialog::buttonDown(), TankAIWeaponSets::WeaponSet::buyWeapons(), TankDamage::calculateDamage(), newMatch(), ServerAdminCommon::poorPlayer(), ServerGiftMoneyHandler::processMessage(), ServerBuyAccessoryHandler::processMessage(), ClientGiftMoneyHandler::processMessage(), ServerShotFinishedState::scoreWinners(), TankResign::simulate(), WeaponGiveMoney::weaponCallback(), and WeaponGiveAccessory::weaponCallback().
| int TankScore::getWins | ( | ) | [inline] |
Definition at line 52 of file TankScore.h.
References wins_.
Referenced by ScoreDialog::addLine(), getScoreString(), and ServerShotFinishedState::scoreWinners().
| void TankScore::setWins | ( | int | wins | ) | [inline] |
Definition at line 53 of file TankScore.h.
References wins_.
Referenced by ServerShotFinishedState::scoreWinners().
| int TankScore::getScore | ( | ) | [inline] |
Definition at line 55 of file TankScore.h.
References score_.
Referenced by ScoreDialog::addLine(), TankDamage::calculateDamage(), ScoreDialog::calculateScores(), TankSort::compare(), ScoreDialog::draw(), generateTargetTip(), getScoreString(), ServerShotFinishedState::scoreOverallWinner(), ServerShotFinishedState::scoreWinners(), TankResign::simulate(), and WeaponGiveScore::weaponCallback().
| void TankScore::setScore | ( | int | score | ) |
Definition at line 89 of file TankScore.cpp.
References score_, and totalScoreEarned_.
Referenced by TankDamage::calculateDamage(), ServerShotFinishedState::scoreWinners(), TankResign::simulate(), and WeaponGiveScore::weaponCallback().
| int TankScore::getTurnKills | ( | ) | [inline] |
Definition at line 58 of file TankScore.h.
References turnKills_.
Referenced by TankDamage::calculateDamage(), and TankDamage::logDeath().
| void TankScore::setTurnKills | ( | int | kills | ) | [inline] |
Definition at line 59 of file TankScore.h.
References turnKills_.
Referenced by TankDamage::calculateDamage(), and ShotState::setup().
| int TankScore::getMissedMoves | ( | ) | [inline] |
Definition at line 61 of file TankScore.h.
References missedMoves_.
Referenced by ServerPlayingState::acceptStateChange().
| void TankScore::setMissedMoves | ( | int | miss | ) | [inline] |
Definition at line 62 of file TankScore.h.
References missedMoves_.
Referenced by ServerPlayingState::acceptStateChange(), and PlayShots::playShots().
| bool TankScore::getWonGame | ( | ) | [inline] |
Definition at line 64 of file TankScore.h.
References wonGame_.
Referenced by ServerNextShotState::getRoundFinished(), and ServerShotFinishedState::scoreWinners().
| void TankScore::setWonGame | ( | ) | [inline] |
Definition at line 65 of file TankScore.h.
References wonGame_.
Referenced by WeaponGiveWin::weaponCallback().
| int TankScore::getRank | ( | ) | [inline] |
Definition at line 67 of file TankScore.h.
References rank_.
Referenced by ScoreDialog::addLine(), GLWScorchedInfo::draw(), getScoreString(), TankTip::populate(), and ServerBrowserInfo::processPlayerMessage().
| void TankScore::setRank | ( | int | rank | ) | [inline] |
Definition at line 68 of file TankScore.h.
References rank_.
Referenced by ServerShotFinishedState::scoreWinners(), and StatsLoggerDatabase::tankConnected().
| int TankScore::getSkill | ( | ) | [inline] |
Definition at line 70 of file TankScore.h.
References skill_.
Referenced by TankDamage::logDeath(), TankTip::populate(), StatsLoggerDatabase::tankKilled(), StatsLoggerDatabase::tankOverallWinner(), StatsLoggerDatabase::tankSelfKilled(), StatsLoggerDatabase::tankTeamKilled(), and StatsLoggerDatabase::tankWon().
| void TankScore::setSkill | ( | int | skill | ) |
Definition at line 47 of file TankScore.cpp.
References skill_, and startSkill_.
Referenced by TankDamage::logDeath(), and StatsLoggerDatabase::tankConnected().
| int TankScore::getStartSkill | ( | ) | [inline] |
Definition at line 73 of file TankScore.h.
References startSkill_.
Referenced by TankTip::populate().
| std::set<unsigned int>& TankScore::getHurtBy | ( | ) | [inline] |
Definition at line 75 of file TankScore.h.
References hurtBy_.
Referenced by TankDamage::calculateDamage(), and TankResign::simulate().
| time_t TankScore::getTimePlayed | ( | ) | [inline] |
| time_t TankScore::getStartTime | ( | ) | [inline] |
Definition at line 78 of file TankScore.h.
References startTime_.
Referenced by ServerNewGameState::checkBots().
| time_t TankScore::getTimePlayedStat | ( | ) |
Definition at line 212 of file TankScore.cpp.
References lastStatTime_.
Referenced by StatsLoggerDatabase::updateStats().
| int TankScore::getTotalMoneyEarnedStat | ( | ) | [inline] |
Definition at line 82 of file TankScore.h.
References totalMoneyEarned_.
Referenced by ServerShotFinishedState::scoreWinners(), and StatsLoggerDatabase::updateStats().
| int TankScore::getTotalScoreEarnedStat | ( | ) | [inline] |
Definition at line 83 of file TankScore.h.
References totalScoreEarned_.
Referenced by StatsLoggerDatabase::updateStats().
| void TankScore::resetTotalEarnedStats | ( | ) |
Definition at line 220 of file TankScore.cpp.
References totalMoneyEarned_, and totalScoreEarned_.
Referenced by TankDeadContainer::getTank(), newMatch(), and ServerShotFinishedState::scoreWinners().
| const char * TankScore::getTimePlayedString | ( | ) |
Definition at line 98 of file TankScore.cpp.
References snprintf, and startTime_.
Referenced by ServerBrowserInfo::processPlayerMessage(), and ServerWebHandler::PlayerHandler::processRequest().
| const char * TankScore::getScoreString | ( | ) |
Definition at line 113 of file TankScore.cpp.
References getAssists(), getKills(), TankState::getLives(), getMoney(), getRank(), getScore(), Tank::getState(), getWins(), snprintf, and tank_.
Referenced by ServerShotFinishedState::enterState(), ClientScoreHandler::processMessage(), ServerBrowserInfo::processPlayerMessage(), ServerWebHandler::PlayerHandler::processRequest(), and ComsSyncCheckMessage::readMessage().
| bool TankScore::writeMessage | ( | NetBuffer & | buffer | ) |
Definition at line 123 of file TankScore.cpp.
References NetBuffer::addToBuffer(), assists_, hurtBy_, kills_, money_, rank_, score_, skill_, startSkill_, turnKills_, and wins_.
Referenced by TankDeadContainer::addTank(), and Tank::writeMessage().
| bool TankScore::readMessage | ( | NetBufferReader & | reader | ) |
Definition at line 145 of file TankScore.cpp.
References assists_, NetBufferReader::getFromBuffer(), hurtBy_, kills_, Logger::log(), money_, rank_, score_, skill_, startSkill_, turnKills_, and wins_.
Referenced by TankDeadContainer::getTank(), and Tank::readMessage().
Tank* TankScore::tank_ [protected] |
std::set<unsigned int> TankScore::hurtBy_ [protected] |
Definition at line 96 of file TankScore.h.
Referenced by getHurtBy(), newGame(), readMessage(), and writeMessage().
ScorchedContext& TankScore::context_ [protected] |
int TankScore::rank_ [protected] |
Definition at line 98 of file TankScore.h.
Referenced by getRank(), readMessage(), setRank(), and writeMessage().
int TankScore::skill_ [protected] |
Definition at line 98 of file TankScore.h.
Referenced by getSkill(), readMessage(), setSkill(), and writeMessage().
int TankScore::startSkill_ [protected] |
Definition at line 98 of file TankScore.h.
Referenced by getStartSkill(), readMessage(), setSkill(), and writeMessage().
int TankScore::kills_ [protected] |
Definition at line 99 of file TankScore.h.
Referenced by getKills(), newMatch(), readMessage(), setKills(), and writeMessage().
int TankScore::turnKills_ [protected] |
Definition at line 99 of file TankScore.h.
Referenced by getTurnKills(), newMatch(), readMessage(), setTurnKills(), and writeMessage().
int TankScore::assists_ [protected] |
Definition at line 100 of file TankScore.h.
Referenced by getAssists(), newMatch(), readMessage(), setAssists(), and writeMessage().
int TankScore::money_ [protected] |
Definition at line 101 of file TankScore.h.
Referenced by getMoney(), newMatch(), readMessage(), setMoney(), and writeMessage().
int TankScore::totalMoneyEarned_ [protected] |
Definition at line 102 of file TankScore.h.
Referenced by getTotalMoneyEarnedStat(), resetTotalEarnedStats(), and setMoney().
int TankScore::totalScoreEarned_ [protected] |
Definition at line 102 of file TankScore.h.
Referenced by getTotalScoreEarnedStat(), resetTotalEarnedStats(), and setScore().
int TankScore::wins_ [protected] |
Definition at line 103 of file TankScore.h.
Referenced by getWins(), newMatch(), readMessage(), setWins(), and writeMessage().
int TankScore::score_ [protected] |
Definition at line 104 of file TankScore.h.
Referenced by getScore(), newMatch(), readMessage(), setScore(), and writeMessage().
int TankScore::missedMoves_ [protected] |
Definition at line 105 of file TankScore.h.
Referenced by getMissedMoves(), newMatch(), and setMissedMoves().
bool TankScore::wonGame_ [protected] |
Definition at line 106 of file TankScore.h.
Referenced by getWonGame(), newGame(), and setWonGame().
time_t TankScore::startTime_ [protected] |
Definition at line 107 of file TankScore.h.
Referenced by getStartTime(), getTimePlayed(), getTimePlayedString(), and TankScore().
time_t TankScore::lastStatTime_ [protected] |
1.5.3