17.05.2014, 00:01
Right now the system is set to where people can spawn without registering there account, however if the account is taken it wont let them spawn without logging in.
I want it to where when they connect, if they dont have an account, they have to /register before spawning. Heres my onrequest spawn:
Heres my onplayerconnect:
I want it to where when they connect, if they dont have an account, they have to /register before spawning. Heres my onrequest spawn:
Код:
public OnPlayerRequestSpawn( playerid )
{
if( INI_Exist ( pName( playerid ) ) )
{
if( GetPVarInt( playerid, "pLog" ) == 0 )
{
SendClientMessage( playerid, green, "This name is already registered. Please /login password to login to this account. ");
return ( 0 );
}
}
return ( 1 );
}
Код:
public OnPlayerConnect( playerid )
{
if( GetPVarInt( playerid, "pLog" ) == 0 )
{
if( INI_Exist ( pName( playerid ) ) )
{
SystemMsg( playerid, "This name is already registered. Please /login [password] to login." );
}
else SystemMsg( playerid, "This name is not registered. /register password for free $150,000!" );
}
return ( 1 );
}


