saját ip cím lekérdezés
new ip[16];GetPlayerIP(playerid,ip,16);
játékosok online lekérdezés pl: players 0/10[/quote]Ezt csak úgy lehet, ha egy sort bemásolsz a mod elejére: new online; majd OnPlayerConnect alatt: online++; OnPlayerDisconect alatt: online--; majd kiírod: new msg[128];format(msg,128,\"%d/%d\",online,GetMaxPlayers());SendClientMessage(playerid,-1,msg); Spoiler for Ping lekérdezés: GetPlayerPing(playerid); az fpst nemtudom.. amúgy:CSAK KERESNI KÉNE!!!
new online;
online++;
online--;
new msg[128];format(msg,128,\"%d/%d\",online,GetMaxPlayers());SendClientMessage(playerid,-1,msg);
GetPlayerPing(playerid);
#include <a_samp>new Text:FPS[MAX_PLAYERS];new DLlast[MAX_PLAYERS] = 0;new FPS2[MAX_PLAYERS] = 0; public OnFilterScriptInit(){for(new i = 0; i < MAX_PLAYERS; i++){ FPS = TextDrawCreate(8.000000, 428.000000, \"FPS: 30\");TextDrawBackgroundColor(FPS, 255);TextDrawFont(FPS, 3);TextDrawLetterSize(FPS, 0.480000, 2.000000);TextDrawColor(FPS, -65281);TextDrawSetOutline(FPS, 1);TextDrawSetProportional(FPS, 1);}SetTimer(\"FPSUP\",1203,true);return 1;}new string[24];public OnPlayerUpdate(playerid){new drunk2 = GetPlayerDrunkLevel(playerid);if(drunk2 < 100){ SetPlayerDrunkLevel(playerid,2000);}else{ if(DLlast[playerid] != drunk2) { new fps = DLlast[playerid] - drunk2; if((fps > 0) && (fps < 200)) FPS2[playerid] = fps; DLlast[playerid] = drunk2;}}}public OnPlayerSpawn(playerid){TextDrawShowForPlayer(playerid,FPS[playerid]);return 1;}public OnPlayerDisconnect(playerid){TextDrawDestroy(FPS[playerid]);return 1;}forward FPSUP();public FPSUP(){for(new i = 0; i < MAX_PLAYERS; i++){ if(IsPlayerConnected(i)) { format(string,sizeof(string),\"FPS: %d\",FPS2-1); TextDrawSetString(FPS,string);}continue;}}
Spoiler for online játékosok: játékosok online lekérdezés pl: players 0/10
játékosok online lekérdezés pl: players 0/10
#include < a_samp >#include < foreach >new g_szFormat[ 10 ];forward Players( );public Players( ){ new iConnected; foreach(Player, i) { iConnected++; } return iConnected;}public OnPlayerConnect( playerid ){ format( g_szFormat, sizeof( g_szFormat ), \"%d/%d\", Players(), GetMaxPlayers() ); SendClientMessageToAll( 0xFF0000AA, g_szFormat ); return 1;}