- 0
Problema vanzare bizzuri
-
Similar Content
-
Recently Browsing 0 members
- No registered users viewing this page.
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.
Question
crazyzee
Salut , am si eu o problema , cred ca tine de comanda /sellbiz , pentru ca atunci cand dau /sellbiz , bizz-u se vinde insa eu daca vreau sa cumpar altul imi zice ca deja am un bizz .
Ce as putea sa fac
[pawn]if(strcmp(cmd, "/sellbiz", true) == 0)
{
if(IsPlayerConnected(playerid))
{
GetPlayerName(playerid, playername, sizeof(playername));
if(PlayerInfo[playerid][pPbiskey] == 255)
{
SendClientMessage(playerid, COLOR_WHITE, "Ne pare rau, dar nu detineti un Business");
return 1;
}
if(PlayerInfo[playerid][pMarried] > 0)
{
SendClientMessage(playerid, COLOR_WHITE, "Ne pare rau, dar sunteti Casatorit asa ca nu puteti vinde acest Business.");
return 1;
}
if(PlayerInfo[playerid][pPbiskey] >= 100 && strcmp(playername, SBizzInfo[PlayerInfo[playerid][pPbiskey]-100][sbOwner], true) == 0)
{
new bouse = PlayerInfo[playerid][pPbiskey]-100;
GivePlayerMoney(playerid,SBizzInfo[bouse][sbBuyPrice]);
SBizzInfo[bouse][sbLocked] = 1;
SBizzInfo[bouse][sbOwned] = 0;
GetPlayerName(playerid, sendername, sizeof(sendername));
strmid(SBizzInfo[bouse][sbOwner], "The State", 0, strlen("The State"), 255);
strmid(SBizzInfo[bouse][sbExtortion], "No-one", 0, strlen("No-one"), 255);
ConsumingMoney[playerid] = 1;
PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
format(string, sizeof(string), "~w~Felicitari~n~ Ati vandut business-ul ~n~~g~%d$", SBizzInfo[bouse][sbTill]);
GameTextForPlayer(playerid, string, 10000, 3);
PlayerInfo[playerid][pPbiskey] = 255;
OnPropUpdate();
OnPlayerUpdate(playerid);
return 1;
}
if(strcmp(playername, BizzInfo[PlayerInfo[playerid][pPbiskey]][bOwner], true) == 0)
{
new bouse = PlayerInfo[playerid][pPbiskey];
BizzInfo[bouse][bLocked] = 1;
BizzInfo[bouse][bOwned] = 0;
GetPlayerName(playerid, sendername, sizeof(sendername));
strmid(BizzInfo[bouse][bOwner], "The State", 0, strlen("The State"), 255);
strmid(BizzInfo[bouse][bExtortion], "No-one", 0, strlen("No-one"), 255);
ConsumingMoney[playerid] = 1;
GivePlayerMoney(playerid,BizzInfo[bouse][bBuyPrice]);
PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
format(string, sizeof(string), "~w~FElicitari~n~ Ati vandut business-ul ~n~~g~%d$", BizzInfo[bouse][bTill]);
GameTextForPlayer(playerid, string, 10000, 3);
PlayerInfo[playerid][pPbiskey] = 255;
OnPropUpdate();
OnPlayerUpdate(playerid);
format(string, sizeof(string), "Business Bot: %s a vandut bizz-ul cu ID-ul %d.", sendername, bouse);
ABroadCast(COLOR_YELLOW,string,1);
return 1;
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "Ne pare rau, dar nu detineti un Business..");
}
}
return 1;
}[/pawn]
RPG.VIBEPLAY.RO
Recomand acest server Romanesc bY woozie aka. weedluver aka. undertaker !!
10 answers to this question
Recommended Posts