- เครดิต
- 168
- ความรู้
-
- เงิน $
-
- ความดี
-
|
if (strcmp(cmd, "/shotgun", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pLevel] >= 1)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREY, "USAGE: /shotgun [äÍ´Õ] [¨Ó¹Ç¹à§Ô¹]");
return 1;
}
if(PlayerDeagleStart[playerid] == 1)
{
SendClientMessage(playerid, COLOR_GREY, " ¤Ø³¡ÓÅѧ´ÇÅ »×¹ÅÙ¡«Í§ ÍÂÙè");
return 1;
}
if(WantedLevel[playerid] >= 1 || WantedPoints[playerid] >= 1)
{
SendClientMessage(playerid, COLOR_GREY, " ¤Ø³ÁÕ¤èÒ¤ÇÒÁµéͧ¡ÒõÑÇÍÂÙè");
return 1;
}
/* if(DeagleOnline[playerid] > 0)
{
SendClientMessage(playerid, COLOR_GREY, " ¤Ø³»Ô´¡Ò÷éÒ´ÇÅÍÂÙè !");
return 1;
} */
new money;
giveplayerid = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
money = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREY, "USAGE: /shotgun [äÍ´Õ] [¨Ó¹Ç¹à§Ô¹]");
return 1;
}
if(money < 2000) { SendClientMessage(playerid, COLOR_WHITE, "à§Ô¹¾¹Ñ¹ËéÒÁ¹éÍ¡ÇèÒ $2,000 !"); return 1; }
if(ScriptMoney[playerid] < money)
{
SendClientMessage(playerid, COLOR_GREY, " ¤Ø³ÁÕà§Ô¹äÁè¾Í !");
return 1;
}
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
if(PlayerDeagleStart[giveplayerid] == 1)
{
SendClientMessage(playerid, COLOR_GREY, " ¼ÙéàÅè¹¹Ñ鹡ÓÅѧ´ÇÅ »×¹ÅÙ¡«Í§ ÍÂÙè");
return 1;
}
if(WantedLevel[giveplayerid] >= 1 || WantedPoints[playerid] >= 1)
{
SendClientMessage(playerid, COLOR_GREY, " ¼ÙéàÅè¹¹Ñé¹ÁÕ¤èÒ¤ÇÒÁµéͧ¡ÒõÑÇÍÂÙè");
return 1;
}
if(ScriptMoney[giveplayerid] < money)
{
SendClientMessage(playerid, COLOR_GREY, " ¼ÙéàÅè¹¹Ñé¹ÁÕà§Ô¹äÁè¾Í¤èÒ´ÇÅ !");
return 1;
}
/* if(DeagleOnline[giveplayerid] > 0)
{
SendClientMessage(playerid, COLOR_GREY, " ¼ÙéàÅè¹·èÒ¹¹Õè»Ô´¡Ò÷éÒ´ÇÅ !");
return 1;
} */
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
PlayerDeagle[giveplayerid] = playerid;
PlayerDeagleMoney[giveplayerid] = money;
format(string, sizeof(string), " {F60000} ¤Ø³ ä´é·éÒ %s ´ÇÅ »×¹ÅÙ¡«Í§ ¤èÒ´ÇÅ %d", giveplayer,money);
SendClientMessage(playerid, COLOR_GREY, string);
format(string, sizeof(string), " {F60000} %s ä´é·éҤس´ÇÅ »×¹ÅÙ¡«Í§ ¤èÒ´ÇÅ %d (¾ÔÁ¾ì [ /accept ÅÙ¡«Í§ ] à¾×è͵ͺÃѺ)", sendername,money);
SendClientMessage(giveplayerid, COLOR_GREY, string);
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " No Such Player");
return 1;
}
}
else
{
return 1;
}
}
return 1;
} |
|