Samp API Query Mechanism
#1

Hi.
Link: mp.com/wiki/Query_Mechanism#SA-MP_Packets_in_the_real_world
Link 2:https://sampforum.blast.hk/showthread.php?tid=104299

How to get players with more than 100 online?

Code class "PHP"
PHP код:
    public function getBasicPlayers() {
        @
fwrite($this->sock$this->assemblePacket("c"));
        
fread($this->sock11);
        
$playerCount ord(fread($this->sock2));
        
$players = array();
        if(
$playerCount 0) {
            for(
$i 0$i $playerCount; ++$i) {
                
$strLen ord(fread($this->sock1));
                
$players[$i] = array
                (
                    
"name" => (string) fread($this->sock$strLen),
                    
"score" => (integer) $this->toInt(fread($this->sock4)),
                );
            }
        }
        return 
$players;
    } 
Receives only 100 players....
Reply


Messages In This Thread
Samp API Query Mechanism - by Clivlend - 18.11.2014, 06:27
Re: Samp API Query Mechanism - by Clivlend - 18.11.2014, 10:49
Re: Samp API Query Mechanism - by GWMPT - 18.11.2014, 11:06
Re: Samp API Query Mechanism - by Clivlend - 18.11.2014, 11:26
Re: Samp API Query Mechanism - by GWMPT - 18.11.2014, 11:39
Re: Samp API Query Mechanism - by Clivlend - 18.11.2014, 13:23
Re: Samp API Query Mechanism - by nickdodd25 - 18.11.2014, 16:19
Re: Samp API Query Mechanism - by Clivlend - 19.11.2014, 08:48
Re : Samp API Query Mechanism - by Nicow - 19.11.2014, 09:58

Forum Jump:


Users browsing this thread: 1 Guest(s)