Author Topic: GUPS 1.15 - Auto-Kick doesnt work.  (Read 3074 times)

0 Members and 1 Guest are viewing this topic.

Offline Sh0cK

  • Street Thug
  • *
  • Posts: 13
    • View Profile
GUPS 1.15 - Auto-Kick doesnt work.
« on: April 18, 2010, 06:15:32 pm »
The title says it all, the message appears, but the player is not kicked.

Offline Boss

  • VC:MP Beta Tester (inactive)
  • Made Man
  • *
  • Posts: 229
  • Boss
    • View Profile
    • TDH Clan Site
Re: GUPS 1.15 - Auto-Kick doesnt work.
« Reply #1 on: April 18, 2010, 06:20:46 pm »
It is a good tone to paste the problematic code so that anyone who might potentially want to help you doesn't need to look for it himself.

Code: [Select]
public OnPlayerSpawn(playerid,classid,teamid)
{
format(file, sizeof(file), USERS_FILE, gPlayers[playerid]);
if(dini_Exists(file)) {
if(PlayerInfo[playerid][Logged] != 1) {
new string[256];
format(string,256,"Auto_Kick:[ %s ] Reason:[ Failed to login ]",gPlayers[playerid]);
SendClientMessageToAll(COLOR_GREEN,string);
}
else { // player spawned and logged in so we need to set the money
new cash = dini_Int(file, "Cash");
SetPlayerMoney(playerid,cash);
}
}
else SetPlayerMoney(playerid,0);
return 1;
}

There is no Kick(playerid); here as you can see, so you just have to add it and re-compile. Could've figured yourself.