Auto login
#10

Quote:
Originally Posted by Battleman
Посмотреть сообщение
Ok, now if got 2 errors.

By this line:
GetPlayerIp(playerid, AccountInfo[playerid][aIP], sizeof(AccountInfo[playerid][aIP])); // at on player connect
the follow errors:
Код:
Z:\Mijn documenten\PC\Game\Maxlife\Script\2011\januari 2011\MLRPG 2011 2 januari\MLRPG 2011 2 januari\gamemodes\mlrpg.pwn(29) : error 001: expected token: "]", but found "-identifier-"
Z:\Mijn documenten\PC\Game\Maxlife\Script\2011\januari 2011\MLRPG 2011 2 januari\MLRPG 2011 2 januari\gamemodes\mlrpg.pwn(29) : warning 215: expression has no effect
Z:\Mijn documenten\PC\Game\Maxlife\Script\2011\januari 2011\MLRPG 2011 2 januari\MLRPG 2011 2 januari\gamemodes\mlrpg.pwn(29) : error 001: expected token: ";", but found "]"
Z:\Mijn documenten\PC\Game\Maxlife\Script\2011\januari 2011\MLRPG 2011 2 januari\MLRPG 2011 2 januari\gamemodes\mlrpg.pwn(29) : error 029: invalid expression, assumed zero
Z:\Mijn documenten\PC\Game\Maxlife\Script\2011\januari 2011\MLRPG 2011 2 januari\MLRPG 2011 2 januari\gamemodes\mlrpg.pwn(29) : fatal error 107: too many error messages on one line
and by this line:
AccountInfo[playerid][aIP] = dini_Get(File, "IP");

this error:
Код:
error 047: array sizes do not match, or destination array is too small
Why are you adding:

pawn Код:
AccountInfo[playerid][aIP] = dini_Get(File, "IP");
You don't need to do that with the example I've shown. Also just use this instead to fix the other errors.

pawn Код:
public OnPlayerConnect(playerid)
{
    GetPlayerIp(playerid, AccountInfo[playerid][aIP], 16); // Assuming 16 is the size of your array, since that's the maximum length of an IP address.

    return 1;
}
Reply


Messages In This Thread
Auto login - by Battleman - 01.01.2011, 22:52
Re: Auto login - by Marty_Alex - 01.01.2011, 22:57
Re: Auto login - by Battleman - 01.01.2011, 23:59
Re: Auto login - by Ironboy - 02.01.2011, 05:37
Re: Auto login - by Yagoda - 02.01.2011, 06:15
Re: Auto login - by Battleman - 02.01.2011, 12:50
Re: Auto login - by BlackBank - 02.01.2011, 14:04
Re: Auto login - by JaTochNietDan - 02.01.2011, 14:09
Re: Auto login - by Battleman - 02.01.2011, 22:48
Re: Auto login - by JaTochNietDan - 02.01.2011, 22:53

Forum Jump:


Users browsing this thread: 1 Guest(s)