Ip Issue
#1

Hey! I Have A Small Problem Each Time I Get A Players IP , I Only Get one Number like 50 or 57


Код:
    new ipi[MAX_PLAYERS],name[MAX_PLAYER_NAME];
    GetPlayerIp(playerid,ipi[playerid],255);
    GetPlayerName(playerid,name,sizeof(name));
    new str[256];
    format(str,sizeof(str),"%s Has Joined The Server! [IP:%s]",name,ipi);
    SendMessageToAdmins(RED,string,1)
Reply
#2

pawn Код:
new ipi[MAX_PLAYERS];
GetPlayerIp(playerid,ipi[playerid],255);
new str[256];
format(str,sizeof(str),"%s Has Joined The Server! [IP:%d]",n,ipi);
SendMessageToAdmins(RED,string,1)
Reply
#3

doesnt work , now it only shows a 0
Reply
#4

pawn Код:
new ipi[16];
    GetPlayerIp(playerid, ipi, sizeof(ipi));
    new str[256];
    format(str,sizeof(str),"%s Has Joined The Server! [IP:%d]",n,ipi);
    SendMessageToAdmins(RED,string,1)
Reply
#5

pawn Код:
new ipi[MAX_PLAYERS],name[MAX_PLAYER_NAME];
    GetPlayerIp(playerid,ipi[playerid],16);
    GetPlayerName(playerid,name,sizeof(name));
    new str[256];
    format(str,sizeof(str),"%s Has Joined The Server! [IP:%s]",name,ipi);
    SendMessageToAdmins(RED,string,1);
Reply
#6

so ummm.... %d or %s? :S
Reply
#7

pawn Код:
new ipi[MAX_PLAYERS][24];
GetPlayerIp(playerid,ipi[playerid],24);
new str[256];
format(str,sizeof(str),"%s Has Joined The Server! [IP:%s]",n,ipi);
SendMessageToAdmins(RED,string,1)
Reply
#8

Quote:
Originally Posted by Code_Red
Посмотреть сообщение
so ummm.... %d or %s? :S
%s..

pawn Код:
new ipi[16];
    GetPlayerIp(playerid, ipi, sizeof(ipi));
    new str[256];
    format(str,sizeof(str),"%s Has Joined The Server! [IP:%d]",n,ipi);
    SendMessageToAdmins(RED,string,1)
The message you have entered is too short. Please lengthen your message to at least 8 characters.
This forum requires that you wait 120 seconds between posts. Please try again in 4 seconds.
Reply
#9

Use
Код:
%s
Reply
#10

i did use %s then some one told to use %d -.-

P.S: Still not working , its only showing me one number :S
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)