Unsupported PHP app for analysing and displaying stats for Team Fortress 2
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

joined.php 863B

12345678910111213141516171819202122232425
  1. <?PHP
  2. class JoinedHandler {
  3. /*-------------------------------------------------------------------------*\
  4. * Handles team joining events. *
  5. * *
  6. * Line sample: team "Red" *
  7. \*-------------------------------------------------------------------------*/
  8. public function parseLine($date, $player, $playerdetails, $line) {
  9. $line = substr($line, 5); // team
  10. $team = Parser::parseString($line);
  11. if ($player->getOpenSession() == null) {
  12. echo "Player " . $player->getSteamID() . " has no open session but joined a team\n";
  13. $player->openSession($date, $playerdetails['uid'], $playerdetails['alias']);
  14. }
  15. $player->getOpenSession()->changeTeam($date, $team);
  16. }
  17. }
  18. ?>