- 0
Problema casino
-
Similar Content
-
- 2 answers
- 643 views
-
Problema turf
By Soryn.,
- 3 answers
- 410 views
-
- 0 replies
- 159 views
-
- 2 replies
- 331 views
-
- 1 reply
- 204 views
-
-
Recently Browsing 0 members
- No registered users viewing this page.
Question
Madu99
Deci cum spune si titlu`l am o problema la casino`uri cand intru intr`un anumit casino imi zice ca este inchissi imi da respawn in GM am gasit urmatoare comanda :
[pawn] if(strcmp(cmd,"/selltkcasino",true)==0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] == 1338)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREY, "{D580FE}Foloseste:{FFFFFF} /selltkcasino [playerid/PartOfName] [money]");
return 1;
}
new playa;
new money;
playa = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GREY, "{D580FE}Foloseste:{FFFFFF} /selltkcasino [playerid/PartOfName] [money]");
return 1;
}
if(IsPlayerConnected(playa))
{
if(playa != INVALID_PLAYER_ID)
{
if (ProxDetectorS(8.0, playerid, playa))
{
money = strval(tmp);
if(money != 30000000) { SendClientMessage(playerid, COLOR_GREY, " Price must be $30,000,000!"); return 1; }
new cash = GetPlayerMoney(playa);
if(cash < 30000000) { SendClientMessage(playerid, COLOR_GREY, " That player don't have so much money !"); return 1; }
GivePlayerMoney(playa, -30000000);
TicketCasino[playa] = 1;
GetPlayerName(playa, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* You gave a Casino ticket of %s for $%d.", giveplayer,money);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
format(string, sizeof(string), "* Admin %s gave you a Casino ticket for $%d.", sendername, money);
SendClientMessage(playa, COLOR_LIGHTBLUE, string);
}
else
{
SendClientMessage(playerid, COLOR_GREY, " That player is not near you !");
}
}
}
else
{
SendClientMessage(playerid, COLOR_GREY, " Nu esti admin ! ");
return 1;
}
}
}
return 1;
}[/pawn]
Dar cand dau /selltkcasino nu imi da "SERVER:Uncnown Comand" dar nici nu imi arata comanda...
Link to comment
Share on other sites
3 answers to this question
Recommended Posts