[SOLVED] small compile error
#3

this is my whole OnPlayerDeath:

Код:
public OnPlayerDeath(playerid, killerid, reason)
{
	new dname[MAX_PLAYER_NAME];
  new killer[MAX_PLAYER_NAME];
  new name[MAX_PLAYER_NAME];
  new deathreason[20];
  new string[128];
	SendDeathMessage(killerid, playerid, reason);
  SetPlayerScore(playerid,(GetPlayerScore(playerid))+1);
  GetWeaponName(reason, deathreason, 20);

  if(reason == 38)
	{
		new kstring[128];
		new kickname[MAX_PLAYER_NAME];
		GetPlayerName(killerid, kickname, sizeof(kickname));
		format(kstring, sizeof(kstring), "AdminSweep: Killer [%d]%s Has Been Banned, No Miniguns Pl0x",killer,kickname);
		printf("%s", kstring);
		SendClientMessageToAll(0xFF0000FF, kstring);
		Ban(killerid);
	}
  if (killerid == INVALID_PLAYER_ID)
  	{
	    switch (reason)
		  {
		  	case WEAPON_DROWN:
		  	{
				format(string, sizeof(string), ".: %s drowned :.", name);
		  	}
		  	
		  	case WEAPON_COLLUSION:
		  	{
		  	format(string, sizeof(string), ".: %s cratered :.", name);
		  	}
		  	
		  	default:
			  {
			  if (strlen(deathreason) > 0)
				{
					format(string, sizeof(string), ".: %s died :.", name);
				}
	  	}
		}
  }
  else
	{
		GetPlayerName(killerid, killer, sizeof(killer));
		if (strlen(deathreason) > 0)
		{
			format(string, sizeof(string), "> %s raped %s (%s)", name, dname, deathreason);
		}
		else
		{
			format(string, sizeof(string), "> %s raped %s", name, dname);
		}
	}
	SendClientMessageToAll(0x8000000FF, string);
  return 1;
}
Reply


Messages In This Thread
[SOLVED] small compile error - by Guns_N_Roses - 23.03.2009, 11:18
Re: small compile error - by Dujma - 23.03.2009, 11:19
Re: small compile error - by Guns_N_Roses - 23.03.2009, 11:21
Re: small compile error - by yezizhu - 23.03.2009, 14:39
Re: small compile error - by Guns_N_Roses - 23.03.2009, 23:38
Re: [New Problem] small compile error - by Guns_N_Roses - 24.03.2009, 00:16
Re: [New Problem, related] small compile error - by yezizhu - 24.03.2009, 04:45
Re: [New Problem, related] small compile error - by Guns_N_Roses - 24.03.2009, 05:26
Re: [New Problem, related] small compile error - by yezizhu - 24.03.2009, 09:00
Re: [New Problem, related] small compile error - by Guns_N_Roses - 24.03.2009, 11:37

Forum Jump:


Users browsing this thread: 1 Guest(s)