This repository has been archived on 2024-07-18. You can view files and clone it, but cannot push or open issues or pull requests.
lwb5/scripts/game/beta5/player/library/isOnline.inc

22 lines
408 B
PHP

<?php
class beta5_player_isOnline {
function beta5_player_isOnline($lib) {
$this->lib = $lib;
$this->db = $this->lib->game->db;
$this->main = $this->lib->game->getLib('main/account');
}
// Checks whether a player is currently online
function run($pid) {
$p = $this->lib->call('get', $pid);
if (is_null($p)) {
return false;
}
return $this->main->call('isOnline', $p['uid']);
}
}
?>