Jump to content
  • 0

Problema casino


Madu99

Question

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

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.