money probs
#1

Hi,

sometimes the players told me that they pay the double price but only sometimes... You know any money bug or does anybody know how i can find this problem?
Reply
#2

if they buy what ? and just check your script maybey you have a double paying line.
and give more info for us to work with

Gr Artix
Reply
#3

Give us some code so we can see.
Reply
#4

Yes but the problem is that it is only sometimes but not every time... Thats my Problem...
Reply
#5

Quote:
Originally Posted by Master_FM
Yes but the problem is that it is only sometimes but not every time... Thats my Problem...
and our problem is that we cant see nothing to work with
give us some code to check or something.

Gr Artix
Reply
#6

I added for a few time Junkbuster... Maybe is that the problem? Because i looked in the script but everything is okay... One Time they pay 200$ its okay the next time they want to pay 200$ than they pay the double price...

Is Junkbuster maybe the problem?
Reply
#7

Quote:
Originally Posted by [RiFA
Artix ]
and give more info for us to work with
Quote:
Originally Posted by [RiFA
Artix ]
Quote:
Originally Posted by Master_FM
Yes but the problem is that it is only sometimes but not every time... Thats my Problem...
give us some code to check or something.
Quote:
Originally Posted by Zeromanster
Give us some code so we can see.
Master FM, maybe better do just do what they ask it helps almost every time
Reply
#8

Yes but i dont know which code? They say sometimes at /pay

Sometimes at /bank

Hier is Code of /pay
if(strcmp(cmd, "/pay", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "Benutze: /pay [playerid/PartOfName] [Betrag]");
return 1;
}
//giveplayerid = strval(tmp);
giveplayerid = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "Benutze: /pay [playerid/PartOfName] [Betrag]");
return 1;
}
moneys = strval(tmp);
if(moneys > 1000 && PlayerInfo[playerid][pLevel] < 3)
{
SendClientMessage(playerid, COLOR_GRAD1, "Du musst Level 3 sein um mehr als 1000 zahlen zu kцnnen");
return 1;
}
if(moneys < 1 || moneys > 10000)
{
SendClientMessage(playerid, COLOR_GRAD1, "Nicht unter 1, oder ьber 10000.");
return 1;
}
if (IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
if(PlayerInfo[giveplayerid][pLocal] == 106)
{
SendClientMessage(playerid, COLOR_GRAD1, "Dieser Befehl ist hier nicht erlaubt");
return 1;
}
if (ProxDetectorS(5.0, playerid, giveplayerid))
{
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
playermoney = GetPlayerMoney(playerid);
if (moneys > 0 && playermoney >= moneys)
{
ConsumingMoney[giveplayerid] = 1;
GivePlayerMoney(playerid, (0 - moneys));
GivePlayerMoney(giveplayerid, moneys);
format(string, sizeof(string), " Du gibst %s(player: %d), $%d.", giveplayer,giveplayerid, moneys);
PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
SendClientMessage(playerid, COLOR_GRAD1, string);
format(string, sizeof(string), " Du erhдlst $%d von %s(player: %d).", moneys, sendername, playerid);
SendClientMessage(giveplayerid, COLOR_GRAD1, string);
format(string, sizeof(string), "%s bezahlt $%d an %s", sendername, moneys, giveplayer);
PayLog(string);
if(moneys >= 1000000)
{
ABroadCast(COLOR_YELLOW,string,1);
}
PlayerPlaySound(giveplayerid, 1052, 0.0, 0.0, 0.0);
format(string, sizeof(string), "* %s nimmt etwas Geld und gibt es %s.", sendername ,giveplayer);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPL E,COLOR_PURPLE);
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Ungьltige Transaktion Betrag.");
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Spieler nicht in der Nдhe.");
}
}//invalid id
}
else
{
format(string, sizeof(string), " %d ist kein aktiver Spieler.", giveplayerid);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
return 1;
}

Code of /bank

if(strcmp(cmd, "/bank", true) == 0 || strcmp(cmd, "/deposit", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pLocal] != 103)
{
SendClientMessage(playerid, COLOR_GREY, " Du bist in keiner Bank !");
return 1;
}
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /bank [Betrag]");
format(string, sizeof(string), " Du besitzt $%d auf dem Konto.", PlayerInfo[playerid][pAccount]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
new cashdeposit = strval(tmp);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: /bank [Betrag]");
format(string, sizeof(string), " Du besitzt $%d auf dem Konto.", PlayerInfo[playerid][pAccount]);
SendClientMessage(playerid, COLOR_GRAD3, string);
return 1;
}
if (cashdeposit > GetPlayerMoney(playerid) || cashdeposit < 1)
{
SendClientMessage(playerid, COLOR_GRAD2, " Du besitzt nicht soviel Geld");
return 1;
}
GivePlayerMoney(playerid,-cashdeposit);
new curfunds = PlayerInfo[playerid][pAccount];
PlayerInfo[playerid][pAccount]=cashdeposit+PlayerInfo[playerid][pAccount];
SendClientMessage(playerid, COLOR_WHITE, "|___ Kontoauszug ___|");
format(string, sizeof(string), " Alter Kontostand: $%d", curfunds);
SendClientMessage(playerid, COLOR_GRAD2, string);
format(string, sizeof(string), " Dazu gezahltes Geld: $%d",cashdeposit);
SendClientMessage(playerid, COLOR_GRAD4, string);
SendClientMessage(playerid, COLOR_GRAD6, "|-----------------------------------------|");
format(string, sizeof(string), " Neuer Kontostand: $%d", PlayerInfo[playerid][pAccount]);
SendClientMessage(playerid, COLOR_WHITE, string);
return 1;
}
return 1;
}

You see everything is okay... I dont know why...
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)